Debian Codegraph @

src/scene/x3d/auto_generated_node_helpers/x3dnodes_x3dsoundsourcenode.inc

raw
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 GetDescription: String;
28 procedure SetDescription(const Value: String);
29 function GetEnabled: Boolean;
30 procedure SetEnabled(const Value: Boolean);
31 function GetGain: Single;
32 procedure SetGain(const Value: Single);
33 function GetPitch: Single;
34 procedure SetPitch(const Value: Single);
35 public
36 { Create node fields and events. }
37 procedure CreateNode; override;
38 class function ClassX3DType: String; override;
39
40 strict private FFdDescription: TSFString;
41 { 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). }
42 public property FdDescription: TSFString read FFdDescription;
43 { }
44 property Description: String read GetDescription write SetDescription;
45
46 strict private FFdEnabled: TSFBool;
47 { Internal wrapper for property @code(Enabled). This wrapper API may change, we advise to access simpler @code(Enabled) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
48 public property FdEnabled: TSFBool read FFdEnabled;
49 { }
50 property Enabled: Boolean read GetEnabled write SetEnabled;
51
52 strict private FFdGain: TSFFloat;
53 { Internal wrapper for property @code(Gain). This wrapper API may change, we advise to access simpler @code(Gain) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
54 public property FdGain: TSFFloat read FFdGain;
55 { }
56 property Gain: Single read GetGain write SetGain;
57
58 strict private FFdPitch: TSFFloat;
59 { Internal wrapper for property @code(Pitch). This wrapper API may change, we advise to access simpler @code(Pitch) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
60 public property FdPitch: TSFFloat read FFdPitch;
61 { }
62 property Pitch: Single read GetPitch write SetPitch;
63
64 strict private FEventDuration_changed: TSFTimeEvent;
65 { }
66 public property EventDuration_changed: TSFTimeEvent read FEventDuration_changed;
67
68 {$endif read_interface}
69
70 {$ifdef read_implementation}
71
72 { TAbstractSoundSourceNode ----------------------------------------------- }
73
74 function TAbstractSoundSourceNode.GetDescription: String;
75 begin
76 Result := FdDescription.Value;
77 end;
78
79 procedure TAbstractSoundSourceNode.SetDescription(const Value: String);
80 begin
81 FdDescription.Send(Value);
82 end;
83
84 function TAbstractSoundSourceNode.GetEnabled: Boolean;
85 begin
86 Result := FdEnabled.Value;
87 end;
88
89 procedure TAbstractSoundSourceNode.SetEnabled(const Value: Boolean);
90 begin
91 FdEnabled.Send(Value);
92 end;
93
94 function TAbstractSoundSourceNode.GetGain: Single;
95 begin
96 Result := FdGain.Value;
97 end;
98
99 procedure TAbstractSoundSourceNode.SetGain(const Value: Single);
100 begin
101 FdGain.Send(Value);
102 end;
103
104 function TAbstractSoundSourceNode.GetPitch: Single;
105 begin
106 Result := FdPitch.Value;
107 end;
108
109 procedure TAbstractSoundSourceNode.SetPitch(const Value: Single);
110 begin
111 FdPitch.Send(Value);
112 end;
113
114 class function TAbstractSoundSourceNode.ClassX3DType: String;
115 begin
116 Result := 'X3DSoundSourceNode';
117 end;
118
119 procedure TAbstractSoundSourceNode.CreateNode;
120 begin
121 inherited;
122
123 FFdDescription := TSFString.Create(Self, True, 'description', '');
124 FdDescription.ChangeAlways := chNone;
125 AddField(FFdDescription);
126
127 FFdEnabled := TSFBool.Create(Self, True, 'enabled', true);
128 FdEnabled.ChangeAlways := chVisibleNonGeometry;
129 AddField(FFdEnabled);
130
131 FFdGain := TSFFloat.Create(Self, True, 'gain', 1);
132 FdGain.ChangeAlways := chVisibleNonGeometry;
133 AddField(FFdGain);
134
135 FFdPitch := TSFFloat.Create(Self, True, 'pitch', 1.0);
136 FdPitch.ChangeAlways := chVisibleNonGeometry;
137 FdPitch.MustBeNonnegative := true;
138 AddField(FFdPitch);
139
140 FEventDuration_changed := TSFTimeEvent.Create(Self, 'duration_changed', false);
141 AddEvent(FEventDuration_changed);
142
143 DefaultContainerField := 'children';
144 end;
145
146 {$endif read_implementation}