| 1 |
{ -*- buffer-read-only: t -*- |
| 2 |
|
| 3 |
Copyright 2015-2024 Michalis Kamburelis. |
| 4 |
|
| 5 |
This file is part of "Castle Game Engine". |
| 6 |
|
| 7 |
"Castle Game Engine" is free software; see the file COPYING.txt, |
| 8 |
included in this distribution, for details about the copyright. |
| 9 |
|
| 10 |
"Castle Game Engine" is distributed in the hope that it will be useful, |
| 11 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 13 |
|
| 14 |
---------------------------------------------------------------------------- |
| 15 |
} |
| 16 |
|
| 17 |
{ Automatically generated node properties. |
| 18 |
|
| 19 |
Do not edit this file manually! |
| 20 |
To add new properties: |
| 21 |
- add them to the text files in tools/internal/x3d-nodes-to-pascal/nodes-specification/ , |
| 22 |
- and regenerate include files by running x3d-nodes-to-pascal } |
| 23 |
|
| 24 |
{$ifdef read_interface} |
| 25 |
|
| 26 |
strict private |
| 27 |
function GetAutoCenterOfRotation: Boolean; |
| 28 |
procedure SetAutoCenterOfRotation(const Value: Boolean); |
| 29 |
function GetCenterOfRotation: TVector3; |
| 30 |
procedure SetCenterOfRotation(const Value: TVector3); |
| 31 |
function GetDescription: String; |
| 32 |
procedure SetDescription(const Value: String); |
| 33 |
function GetJump: Boolean; |
| 34 |
procedure SetJump(const Value: Boolean); |
| 35 |
function GetOrientation: TVector4; |
| 36 |
procedure SetOrientation(const Value: TVector4); |
| 37 |
function GetRetainUserOffsets: Boolean; |
| 38 |
procedure SetRetainUserOffsets(const Value: Boolean); |
| 39 |
function GetCameraMatrixSendAlsoOnOffscreenRendering: Boolean; |
| 40 |
procedure SetCameraMatrixSendAlsoOnOffscreenRendering(const Value: Boolean); |
| 41 |
function GetGravityUp: TVector3; |
| 42 |
procedure SetGravityUp(const Value: TVector3); |
| 43 |
function GetGravityTransform: Boolean; |
| 44 |
procedure SetGravityTransform(const Value: Boolean); |
| 45 |
public |
| 46 |
{ Create node fields and events. } |
| 47 |
procedure CreateNode; override; |
| 48 |
class function ClassX3DType: String; override; |
| 49 |
|
| 50 |
strict private FFdAutoCenterOfRotation: TSFBool; |
| 51 |
{ Internal wrapper for property @code(AutoCenterOfRotation). This wrapper API may change, we advise to access simpler @code(AutoCenterOfRotation) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 52 |
public property FdAutoCenterOfRotation: TSFBool read FFdAutoCenterOfRotation; |
| 53 |
{ When @true, the center of rotation is automatically calculated looking at the middle of scene bounding box. The @link(CenterOfRotation) value is ignored then. |
| 54 |
|
| 55 |
This field is a Castle Game Engine extension of the X3D standard. The default value (@false) makes behavior compatible with X3D standard. Note that, in contrast, @link(TCastleExamineNavigation.AutoCenterOfRotation) default is @true -- because TCastleExamineNavigation doesn't have to match X3D standard, and the default @true makes it work out-of-the-box on more scenes. } |
| 56 |
property AutoCenterOfRotation: Boolean read GetAutoCenterOfRotation write SetAutoCenterOfRotation; |
| 57 |
|
| 58 |
strict private FFdCenterOfRotation: TSFVec3f; |
| 59 |
{ Internal wrapper for property @code(CenterOfRotation). This wrapper API may change, we advise to access simpler @code(CenterOfRotation) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 60 |
public property FdCenterOfRotation: TSFVec3f read FFdCenterOfRotation; |
| 61 |
{ } |
| 62 |
property CenterOfRotation: TVector3 read GetCenterOfRotation write SetCenterOfRotation; |
| 63 |
|
| 64 |
strict private FFdDescription: TSFString; |
| 65 |
{ Internal wrapper for property @code(Description). This wrapper API may change, we advise to access simpler @code(Description) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 66 |
public property FdDescription: TSFString read FFdDescription; |
| 67 |
{ } |
| 68 |
property Description: String read GetDescription write SetDescription; |
| 69 |
|
| 70 |
strict private FFdJump: TSFBool; |
| 71 |
{ Internal wrapper for property @code(Jump). This wrapper API may change, we advise to access simpler @code(Jump) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 72 |
public property FdJump: TSFBool read FFdJump; |
| 73 |
{ } |
| 74 |
property Jump: Boolean read GetJump write SetJump; |
| 75 |
|
| 76 |
strict private FFdOrientation: TSFRotation; |
| 77 |
{ Internal wrapper for property @code(Orientation). This wrapper API may change, we advise to access simpler @code(Orientation) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 78 |
public property FdOrientation: TSFRotation read FFdOrientation; |
| 79 |
{ Orientation of the viewpoint, expressed as rotation to transform default direction and up (DefaultX3DCameraDirection, DefaultX3DCameraUp). } |
| 80 |
property Orientation: TVector4 read GetOrientation write SetOrientation; |
| 81 |
|
| 82 |
strict private FFdRetainUserOffsets: TSFBool; |
| 83 |
{ Internal wrapper for property @code(RetainUserOffsets). This wrapper API may change, we advise to access simpler @code(RetainUserOffsets) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 84 |
public property FdRetainUserOffsets: TSFBool read FFdRetainUserOffsets; |
| 85 |
{ } |
| 86 |
property RetainUserOffsets: Boolean read GetRetainUserOffsets write SetRetainUserOffsets; |
| 87 |
|
| 88 |
strict private FEventCameraMatrix: TSFMatrix4fEvent; |
| 89 |
{ } |
| 90 |
public property EventCameraMatrix: TSFMatrix4fEvent read FEventCameraMatrix; |
| 91 |
|
| 92 |
strict private FEventCameraInverseMatrix: TSFMatrix4fEvent; |
| 93 |
{ } |
| 94 |
public property EventCameraInverseMatrix: TSFMatrix4fEvent read FEventCameraInverseMatrix; |
| 95 |
|
| 96 |
strict private FEventCameraRotationMatrix: TSFMatrix3fEvent; |
| 97 |
{ } |
| 98 |
public property EventCameraRotationMatrix: TSFMatrix3fEvent read FEventCameraRotationMatrix; |
| 99 |
|
| 100 |
strict private FEventCameraRotationInverseMatrix: TSFMatrix3fEvent; |
| 101 |
{ } |
| 102 |
public property EventCameraRotationInverseMatrix: TSFMatrix3fEvent read FEventCameraRotationInverseMatrix; |
| 103 |
|
| 104 |
strict private FFdCameraMatrixSendAlsoOnOffscreenRendering: TSFBool; |
| 105 |
{ Internal wrapper for property @code(CameraMatrixSendAlsoOnOffscreenRendering). This wrapper API may change, we advise to access simpler @code(CameraMatrixSendAlsoOnOffscreenRendering) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 106 |
public property FdCameraMatrixSendAlsoOnOffscreenRendering: TSFBool read FFdCameraMatrixSendAlsoOnOffscreenRendering; |
| 107 |
{ } |
| 108 |
property CameraMatrixSendAlsoOnOffscreenRendering: Boolean read GetCameraMatrixSendAlsoOnOffscreenRendering write SetCameraMatrixSendAlsoOnOffscreenRendering; |
| 109 |
|
| 110 |
strict private FFdDirection: TMFVec3f; |
| 111 |
{ Internal wrapper for property @code(Direction). This wrapper API may change, we advise to access simpler @code(Direction) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 112 |
public property FdDirection: TMFVec3f read FFdDirection; |
| 113 |
|
| 114 |
strict private FFdUp: TMFVec3f; |
| 115 |
{ Internal wrapper for property @code(Up). This wrapper API may change, we advise to access simpler @code(Up) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 116 |
public property FdUp: TMFVec3f read FFdUp; |
| 117 |
|
| 118 |
strict private FFdGravityUp: TSFVec3f; |
| 119 |
{ Internal wrapper for property @code(GravityUp). This wrapper API may change, we advise to access simpler @code(GravityUp) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 120 |
public property FdGravityUp: TSFVec3f read FFdGravityUp; |
| 121 |
{ Specify the gravity vector explicitly. See https://castle-engine.io/x3d_implementation_navigation_extensions.php . @deprecated } |
| 122 |
property GravityUp: TVector3 read GetGravityUp write SetGravityUp; |
| 123 |
|
| 124 |
strict private FFdGravityTransform: TSFBool; |
| 125 |
{ Internal wrapper for property @code(GravityTransform). This wrapper API may change, we advise to access simpler @code(GravityTransform) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 126 |
public property FdGravityTransform: TSFBool read FFdGravityTransform; |
| 127 |
{ Should the gravity vector be affected by the viewpoint transformation, that is by the @link(TTransformNode) instances that contain this TAbstractViewpointNode. } |
| 128 |
property GravityTransform: Boolean read GetGravityTransform write SetGravityTransform; |
| 129 |
|
| 130 |
{$endif read_interface} |
| 131 |
|
| 132 |
{$ifdef read_implementation} |
| 133 |
|
| 134 |
{ TAbstractViewpointNode ----------------------------------------------- } |
| 135 |
|
| 136 |
function TAbstractViewpointNode.GetAutoCenterOfRotation: Boolean; |
| 137 |
begin |
| 138 |
Result := FdAutoCenterOfRotation.Value; |
| 139 |
end; |
| 140 |
|
| 141 |
procedure TAbstractViewpointNode.SetAutoCenterOfRotation(const Value: Boolean); |
| 142 |
begin |
| 143 |
FdAutoCenterOfRotation.Send(Value); |
| 144 |
end; |
| 145 |
|
| 146 |
function TAbstractViewpointNode.GetCenterOfRotation: TVector3; |
| 147 |
begin |
| 148 |
Result := FdCenterOfRotation.Value; |
| 149 |
end; |
| 150 |
|
| 151 |
procedure TAbstractViewpointNode.SetCenterOfRotation(const Value: TVector3); |
| 152 |
begin |
| 153 |
FdCenterOfRotation.Send(Value); |
| 154 |
end; |
| 155 |
|
| 156 |
function TAbstractViewpointNode.GetDescription: String; |
| 157 |
begin |
| 158 |
Result := FdDescription.Value; |
| 159 |
end; |
| 160 |
|
| 161 |
procedure TAbstractViewpointNode.SetDescription(const Value: String); |
| 162 |
begin |
| 163 |
FdDescription.Send(Value); |
| 164 |
end; |
| 165 |
|
| 166 |
function TAbstractViewpointNode.GetJump: Boolean; |
| 167 |
begin |
| 168 |
Result := FdJump.Value; |
| 169 |
end; |
| 170 |
|
| 171 |
procedure TAbstractViewpointNode.SetJump(const Value: Boolean); |
| 172 |
begin |
| 173 |
FdJump.Send(Value); |
| 174 |
end; |
| 175 |
|
| 176 |
function TAbstractViewpointNode.GetOrientation: TVector4; |
| 177 |
begin |
| 178 |
Result := FdOrientation.Value; |
| 179 |
end; |
| 180 |
|
| 181 |
procedure TAbstractViewpointNode.SetOrientation(const Value: TVector4); |
| 182 |
begin |
| 183 |
FdOrientation.Send(Value); |
| 184 |
end; |
| 185 |
|
| 186 |
function TAbstractViewpointNode.GetRetainUserOffsets: Boolean; |
| 187 |
begin |
| 188 |
Result := FdRetainUserOffsets.Value; |
| 189 |
end; |
| 190 |
|
| 191 |
procedure TAbstractViewpointNode.SetRetainUserOffsets(const Value: Boolean); |
| 192 |
begin |
| 193 |
FdRetainUserOffsets.Send(Value); |
| 194 |
end; |
| 195 |
|
| 196 |
function TAbstractViewpointNode.GetCameraMatrixSendAlsoOnOffscreenRendering: Boolean; |
| 197 |
begin |
| 198 |
Result := FdCameraMatrixSendAlsoOnOffscreenRendering.Value; |
| 199 |
end; |
| 200 |
|
| 201 |
procedure TAbstractViewpointNode.SetCameraMatrixSendAlsoOnOffscreenRendering(const Value: Boolean); |
| 202 |
begin |
| 203 |
FdCameraMatrixSendAlsoOnOffscreenRendering.Send(Value); |
| 204 |
end; |
| 205 |
|
| 206 |
function TAbstractViewpointNode.GetGravityUp: TVector3; |
| 207 |
begin |
| 208 |
Result := FdGravityUp.Value; |
| 209 |
end; |
| 210 |
|
| 211 |
procedure TAbstractViewpointNode.SetGravityUp(const Value: TVector3); |
| 212 |
begin |
| 213 |
FdGravityUp.Send(Value); |
| 214 |
end; |
| 215 |
|
| 216 |
function TAbstractViewpointNode.GetGravityTransform: Boolean; |
| 217 |
begin |
| 218 |
Result := FdGravityTransform.Value; |
| 219 |
end; |
| 220 |
|
| 221 |
procedure TAbstractViewpointNode.SetGravityTransform(const Value: Boolean); |
| 222 |
begin |
| 223 |
FdGravityTransform.Send(Value); |
| 224 |
end; |
| 225 |
|
| 226 |
class function TAbstractViewpointNode.ClassX3DType: String; |
| 227 |
begin |
| 228 |
Result := 'X3DViewpointNode'; |
| 229 |
end; |
| 230 |
|
| 231 |
procedure TAbstractViewpointNode.CreateNode; |
| 232 |
begin |
| 233 |
inherited; |
| 234 |
|
| 235 |
FFdAutoCenterOfRotation := TSFBool.Create(Self, True, 'autoCenterOfRotation', false); |
| 236 |
FdAutoCenterOfRotation.ChangeAlways := chVisibleNonGeometry; |
| 237 |
AddField(FFdAutoCenterOfRotation); |
| 238 |
|
| 239 |
FFdCenterOfRotation := TSFVec3f.Create(Self, True, 'centerOfRotation', Vector3(0, 0, 0)); |
| 240 |
FdCenterOfRotation.ChangeAlways := chVisibleNonGeometry; |
| 241 |
AddField(FFdCenterOfRotation); |
| 242 |
|
| 243 |
FFdDescription := TSFString.Create(Self, True, 'description', ''); |
| 244 |
FdDescription.ChangeAlways := chNone; |
| 245 |
AddField(FFdDescription); |
| 246 |
|
| 247 |
FFdJump := TSFBool.Create(Self, True, 'jump', true); |
| 248 |
FdJump.ChangeAlways := chVisibleNonGeometry; |
| 249 |
AddField(FFdJump); |
| 250 |
|
| 251 |
FFdOrientation := TSFRotation.Create(Self, True, 'orientation', Vector3(0, 0, 1), 0); |
| 252 |
FdOrientation.ChangeAlways := chVisibleNonGeometry; |
| 253 |
AddField(FFdOrientation); |
| 254 |
|
| 255 |
FFdRetainUserOffsets := TSFBool.Create(Self, True, 'retainUserOffsets', false); |
| 256 |
FdRetainUserOffsets.ChangeAlways := chVisibleNonGeometry; |
| 257 |
AddField(FFdRetainUserOffsets); |
| 258 |
|
| 259 |
FEventCameraMatrix := TSFMatrix4fEvent.Create(Self, 'cameraMatrix', false); |
| 260 |
AddEvent(FEventCameraMatrix); |
| 261 |
|
| 262 |
FEventCameraInverseMatrix := TSFMatrix4fEvent.Create(Self, 'cameraInverseMatrix', false); |
| 263 |
AddEvent(FEventCameraInverseMatrix); |
| 264 |
|
| 265 |
FEventCameraRotationMatrix := TSFMatrix3fEvent.Create(Self, 'cameraRotationMatrix', false); |
| 266 |
AddEvent(FEventCameraRotationMatrix); |
| 267 |
|
| 268 |
FEventCameraRotationInverseMatrix := TSFMatrix3fEvent.Create(Self, 'cameraRotationInverseMatrix', false); |
| 269 |
AddEvent(FEventCameraRotationInverseMatrix); |
| 270 |
|
| 271 |
FFdCameraMatrixSendAlsoOnOffscreenRendering := TSFBool.Create(Self, True, 'cameraMatrixSendAlsoOnOffscreenRendering', false); |
| 272 |
FdCameraMatrixSendAlsoOnOffscreenRendering.ChangeAlways := chVisibleNonGeometry; |
| 273 |
AddField(FFdCameraMatrixSendAlsoOnOffscreenRendering); |
| 274 |
|
| 275 |
FFdDirection := TMFVec3f.Create(Self, True, 'direction', []); |
| 276 |
FdDirection.ChangeAlways := chVisibleNonGeometry; |
| 277 |
AddField(FFdDirection); |
| 278 |
|
| 279 |
FFdUp := TMFVec3f.Create(Self, True, 'up', []); |
| 280 |
FdUp.ChangeAlways := chVisibleNonGeometry; |
| 281 |
AddField(FFdUp); |
| 282 |
|
| 283 |
FFdGravityUp := TSFVec3f.Create(Self, True, 'gravityUp', Vector3(0, 1, 0)); |
| 284 |
FdGravityUp.ChangeAlways := chVisibleNonGeometry; |
| 285 |
AddField(FFdGravityUp); |
| 286 |
|
| 287 |
FFdGravityTransform := TSFBool.Create(Self, True, 'gravityTransform', true); |
| 288 |
FdGravityTransform.ChangeAlways := chVisibleNonGeometry; |
| 289 |
AddField(FFdGravityTransform); |
| 290 |
end; |
| 291 |
|
| 292 |
{$endif read_implementation} |