| 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 GetSize: TVector3; |
| 28 |
procedure SetSize(const Value: TVector3); |
| 29 |
function GetManifold: Boolean; |
| 30 |
procedure SetManifold(const Value: Boolean); |
| 31 |
function GetTexCoord: TX3DNode; |
| 32 |
procedure SetTexCoord(const Value: TX3DNode); |
| 33 |
public |
| 34 |
{ Create node fields and events. } |
| 35 |
procedure CreateNode; override; |
| 36 |
class function ClassX3DType: String; override; |
| 37 |
|
| 38 |
strict private FFdSize: TSFVec3f; |
| 39 |
{ Internal wrapper for property @code(Size). This wrapper API may change, we advise to access simpler @code(Size) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 40 |
public property FdSize: TSFVec3f read FFdSize; |
| 41 |
{ } |
| 42 |
property Size: TVector3 read GetSize write SetSize; |
| 43 |
|
| 44 |
strict private FFdSolid: TSFBool; |
| 45 |
{ Internal wrapper for property @code(Solid). This wrapper API may change, we advise to access simpler @code(Solid) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 46 |
public property FdSolid: TSFBool read FFdSolid; |
| 47 |
|
| 48 |
strict private FFdManifold: TSFBool; |
| 49 |
{ Internal wrapper for property @code(Manifold). This wrapper API may change, we advise to access simpler @code(Manifold) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 50 |
public property FdManifold: TSFBool read FFdManifold; |
| 51 |
{ } |
| 52 |
property Manifold: Boolean read GetManifold write SetManifold; |
| 53 |
|
| 54 |
strict private FFdTexCoord: TSFNode; |
| 55 |
{ Internal wrapper for property @code(TexCoord). This wrapper API may change, we advise to access simpler @code(TexCoord) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 56 |
public property FdTexCoord: TSFNode read FFdTexCoord; |
| 57 |
{ } |
| 58 |
property TexCoord: TX3DNode read GetTexCoord write SetTexCoord; |
| 59 |
|
| 60 |
{$endif read_interface} |
| 61 |
|
| 62 |
{$ifdef read_implementation} |
| 63 |
|
| 64 |
{ TTeapotNode ----------------------------------------------- } |
| 65 |
|
| 66 |
function TTeapotNode.GetSize: TVector3; |
| 67 |
begin |
| 68 |
Result := FdSize.Value; |
| 69 |
end; |
| 70 |
|
| 71 |
procedure TTeapotNode.SetSize(const Value: TVector3); |
| 72 |
begin |
| 73 |
FdSize.Send(Value); |
| 74 |
end; |
| 75 |
|
| 76 |
function TTeapotNode.GetManifold: Boolean; |
| 77 |
begin |
| 78 |
Result := FdManifold.Value; |
| 79 |
end; |
| 80 |
|
| 81 |
procedure TTeapotNode.SetManifold(const Value: Boolean); |
| 82 |
begin |
| 83 |
FdManifold.Send(Value); |
| 84 |
end; |
| 85 |
|
| 86 |
function TTeapotNode.GetTexCoord: TX3DNode; |
| 87 |
begin |
| 88 |
if FdTexCoord.Value is TX3DNode then |
| 89 |
Result := TX3DNode(FdTexCoord.Value) |
| 90 |
else |
| 91 |
Result := nil; |
| 92 |
end; |
| 93 |
|
| 94 |
procedure TTeapotNode.SetTexCoord(const Value: TX3DNode); |
| 95 |
begin |
| 96 |
FdTexCoord.Send(Value); |
| 97 |
end; |
| 98 |
|
| 99 |
class function TTeapotNode.ClassX3DType: String; |
| 100 |
begin |
| 101 |
Result := 'Teapot'; |
| 102 |
end; |
| 103 |
|
| 104 |
procedure TTeapotNode.CreateNode; |
| 105 |
begin |
| 106 |
inherited; |
| 107 |
|
| 108 |
FFdSize := TSFVec3f.Create(Self, False, 'size', Vector3(3, 3, 3)); |
| 109 |
FdSize.ChangeAlways := chVisibleNonGeometry; |
| 110 |
AddField(FFdSize); |
| 111 |
|
| 112 |
FFdSolid := TSFBool.Create(Self, False, 'solid', true); |
| 113 |
FdSolid.ChangeAlways := chVisibleNonGeometry; |
| 114 |
AddField(FFdSolid); |
| 115 |
|
| 116 |
FFdManifold := TSFBool.Create(Self, False, 'manifold', false); |
| 117 |
FdManifold.ChangeAlways := chVisibleNonGeometry; |
| 118 |
AddField(FFdManifold); |
| 119 |
|
| 120 |
FFdTexCoord := TSFNode.Create(Self, True, 'texCoord', [TTextureCoordinateGeneratorNode, TProjectedTextureCoordinateNode, TMultiGeneratedTextureCoordinateNode]); |
| 121 |
FdTexCoord.ChangeAlways := chVisibleNonGeometry; |
| 122 |
AddField(FFdTexCoord); |
| 123 |
end; |
| 124 |
|
| 125 |
{$endif read_implementation} |