Class TElevationGridNode
Unit
Declaration
type TElevationGridNode = class(TAbstractGeometryNode)
Description
Uniform rectangular grid of varying height above the Y=0 plane, aka "height map".
Hierarchy
- TObject
- TPersistent
- TX3DFileItem
- TX3DNode
- TAbstractNode
- TAbstractGeometryNode
- TElevationGridNode
Overview
Methods
constructor Create(const AX3DName: String = ''; const ABaseUrl: String = ''); override; |
|
function IsNotEmpty: boolean; |
|
function ColorField: TSFNode; override; |
|
function InternalFogCoord: TMFFloat; override; |
|
function AttribField: TMFNode; override; |
|
function SolidField: TSFBool; override; |
|
function FieldSetByEvent(const Event: TX3DEvent): TX3DField; override; |
|
function Proxy(var State: TX3DGraphTraverseState): TAbstractGeometryNode; override; |
|
function LocalBoundingBox(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): TBox3D; override; |
|
function VerticesCount(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): Cardinal; override; |
|
function TrianglesCount(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): Cardinal; override; |
|
class function InternalCreateTriangles( const AXDimension, AZDimension: Integer; const AXSpacing, AZSpacing: Single; const AHeight: TSingleList; const ATexCoord: TAbstractTextureCoordinateNode; const TriangulationIgnoreHeights: Boolean): TIndexedTriangleSetNode; |
|
procedure CreateNode; override; |
|
class function ClassX3DType: String; override; |
|
procedure SetAttrib(const Value: array of TAbstractVertexAttributeNode); |
|
procedure SetHeight(const Value: array of Single); overload; |
|
procedure SetHeight(const Value: TSingleList); overload; |
Properties
property EventSet_height: TMFFloatEvent read FEventSet_height; |
|
property FdAttrib: TMFNode read FFdAttrib; |
|
property FdColor: TSFNode read FFdColor; |
|
property Color: TAbstractColorNode read GetColor write SetColor; |
|
property FdFogCoord: TSFNode read FFdFogCoord; |
|
property FogCoord: TFogCoordinateNode read GetFogCoord write SetFogCoord; |
|
property FdNormal: TSFNode read FFdNormal; |
|
property Normal: TAbstractNormalNode read GetNormal write SetNormal; |
|
property FdTexCoord: TSFNode read FFdTexCoord; |
|
property TexCoord: TAbstractTextureCoordinateNode read GetTexCoord write SetTexCoord; |
|
property FdCcw: TSFBool read FFdCcw; |
|
property Ccw: Boolean read GetCcw write SetCcw; |
|
property FdColorPerVertex: TSFBool read FFdColorPerVertex; |
|
property ColorPerVertex: Boolean read GetColorPerVertex write SetColorPerVertex; |
|
property FdCreaseAngle: TSFFloat read FFdCreaseAngle; |
|
property CreaseAngle: Single read GetCreaseAngle write SetCreaseAngle; |
|
property FdHeight: TMFFloat read FFdHeight; |
|
property FdNormalPerVertex: TSFBool read FFdNormalPerVertex; |
|
property NormalPerVertex: Boolean read GetNormalPerVertex write SetNormalPerVertex; |
|
property FdSolid: TSFBool read FFdSolid; |
|
property FdXDimension: TSFInt32 read FFdXDimension; |
|
property XDimension: Integer read GetXDimension write SetXDimension; |
|
property FdXSpacing: TSFFloat read FFdXSpacing; |
|
property XSpacing: Single read GetXSpacing write SetXSpacing; |
|
property FdZDimension: TSFInt32 read FFdZDimension; |
|
property ZDimension: Integer read GetZDimension write SetZDimension; |
|
property FdZSpacing: TSFFloat read FFdZSpacing; |
|
property ZSpacing: Single read GetZSpacing write SetZSpacing; |
Description
Methods
constructor Create(const AX3DName: String = ''; const ABaseUrl: String = ''); override; |
|
This item has no description. Showing description inherited from TX3DNode.Create. Constructor. Initializes various properties:
|
function IsNotEmpty: boolean; |
|
Do we have (correct) data to render. Checks whether - xDimension and zDimension are >= 2, - xSpacing and zSpacing are > 0 - height list has at least the required number of values. |
function ColorField: TSFNode; override; |
|
This item has no description. |
function InternalFogCoord: TMFFloat; override; |
|
This item has no description. |
function AttribField: TMFNode; override; |
|
This item has no description. |
function SolidField: TSFBool; override; |
|
This item has no description. Showing description inherited from TAbstractGeometryNode.SolidField.
Is backface culling used. |
function FieldSetByEvent(const Event: TX3DEvent): TX3DField; override; |
|
This item has no description. Showing description inherited from TX3DNode.FieldSetByEvent.
Find field set by given event of this node. |
function Proxy(var State: TX3DGraphTraverseState): TAbstractGeometryNode; override; |
|
This item has no description. Showing description inherited from TAbstractGeometryNode.Proxy. Converts this node to another node class that may be better supported. Typically, converts some complex geometry node (like Extrusion or Teapot) into more common node like IndexedFaceSet or IndexedTriangleSet. TShape class wraps this method into a more comfortable interface, that is TShape methods simply automatically convert geometry nodes to their proxy versions if needed. In the base TAbstractGeometryNode class, returns The resulting node's Name (if the result is not Some Proxy implementations (especially for VRML 1.0) will have to create new State (TX3DGraphTraverseState) instance along with a new geometry node. You should do this by copying the State into a new TX3DGraphTraverseState instance, and modyfying the State reference. Simply speaking, do State := TX3DGraphTraverseState.CreateCopy(State);
You should not just modify the fields of the provided State instance. (Reasoning: some proxy methods rely on getting the original State, e.g. with original MaterialBinding, not the transformed state, to work correctly.) You can modify State variable only when returning non-nil geometry. |
function LocalBoundingBox(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): TBox3D; override; |
|
This item has no description. |
function VerticesCount(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): Cardinal; override; |
|
This item has no description. Showing description inherited from TAbstractGeometryNode.VerticesCount. Calculate vertex and triangles count of this node. They require State of this node during VRML traverse state — this is mainly for VRML 1.0 nodes, that depend on such state. Vertices count calculates number of different vertexes in this node. That is, it doesn't eliminate doubles in cases like Coordinate node with multiple points the same. But if some face is known to use twice the same vertex index, then this counts like a single vertex. The idea is that this indicates rendering speed. For triangles count, the returned value may be different then actual if some faces were non-convex. Things like TriangulateFace may remove degenerate triangles, so actual number of triangles may be slightly less. So don't depend on TrianglesCount as a precise measure — but it's a good fast measure of complexity of given node, how fast it will be rendered, used with collision detection etc. Notes for descendants implementors: For coordinate-based nodes (when InternalCoord returns For other nodes, the default implementation of both |
function TrianglesCount(State: TX3DGraphTraverseState; ProxyGeometry: TAbstractGeometryNode; ProxyState: TX3DGraphTraverseState): Cardinal; override; |
|
This item has no description. |
class function InternalCreateTriangles( const AXDimension, AZDimension: Integer; const AXSpacing, AZSpacing: Single; const AHeight: TSingleList; const ATexCoord: TAbstractTextureCoordinateNode; const TriangulationIgnoreHeights: Boolean): TIndexedTriangleSetNode; |
|
Create triangle set to render the elevation grid. Useful for - Proxy in this class - TCastleTerrain which wants direct TIndexedTriangleSetNode (faster to later update than to maintain TElevationGridNode). |
procedure CreateNode; override; |
|
Create node fields and events. |
class function ClassX3DType: String; override; |
|
This item has no description. Showing description inherited from TX3DNode.ClassX3DType. Node type name in VRML/X3D, for this class. Normal VRML/X3D node classes should override this to return something non-empty, and then X3DType automatically will return the same value. Empty for classes that don't have a hardcoded VRML/X3D node name, like a special TX3DUnknownNode. Such special classes should override then X3DType to return actual non-empty name there. You usually should call X3DType. The only use of this method is that it works on classes (it's "class function"), without needing at actual instance. |
procedure SetAttrib(const Value: array of TAbstractVertexAttributeNode); |
|
This item has no description. |
procedure SetHeight(const Value: array of Single); overload; |
|
This item has no description. |
procedure SetHeight(const Value: TSingleList); overload; |
|
This item has no description. |
Properties
property EventSet_height: TMFFloatEvent read FEventSet_height; |
|
This item has no description. |
property FdAttrib: TMFNode read FFdAttrib; |
|
Internal wrapper for property |
property FdColor: TSFNode read FFdColor; |
|
Internal wrapper for property |
property Color: TAbstractColorNode read GetColor write SetColor; |
|
This item has no description. |
property FdFogCoord: TSFNode read FFdFogCoord; |
|
Internal wrapper for property |
property FogCoord: TFogCoordinateNode read GetFogCoord write SetFogCoord; |
|
This item has no description. |
property FdNormal: TSFNode read FFdNormal; |
|
Internal wrapper for property |
property Normal: TAbstractNormalNode read GetNormal write SetNormal; |
|
This item has no description. |
property FdTexCoord: TSFNode read FFdTexCoord; |
|
Internal wrapper for property |
property TexCoord: TAbstractTextureCoordinateNode read GetTexCoord write SetTexCoord; |
|
This item has no description. |
property FdCcw: TSFBool read FFdCcw; |
|
Internal wrapper for property |
property Ccw: Boolean read GetCcw write SetCcw; |
|
This item has no description. |
property FdColorPerVertex: TSFBool read FFdColorPerVertex; |
|
Internal wrapper for property |
property ColorPerVertex: Boolean read GetColorPerVertex write SetColorPerVertex; |
|
This item has no description. |
property FdCreaseAngle: TSFFloat read FFdCreaseAngle; |
|
Internal wrapper for property |
property CreaseAngle: Single read GetCreaseAngle write SetCreaseAngle; |
|
This item has no description. |
property FdHeight: TMFFloat read FFdHeight; |
|
Internal wrapper for property |
property FdNormalPerVertex: TSFBool read FFdNormalPerVertex; |
|
Internal wrapper for property |
property NormalPerVertex: Boolean read GetNormalPerVertex write SetNormalPerVertex; |
|
This item has no description. |
property FdSolid: TSFBool read FFdSolid; |
|
Internal wrapper for property |
property FdXDimension: TSFInt32 read FFdXDimension; |
|
Internal wrapper for property |
property XDimension: Integer read GetXDimension write SetXDimension; |
|
This item has no description. |
property FdXSpacing: TSFFloat read FFdXSpacing; |
|
Internal wrapper for property |
property XSpacing: Single read GetXSpacing write SetXSpacing; |
|
This item has no description. |
property FdZDimension: TSFInt32 read FFdZDimension; |
|
Internal wrapper for property |
property ZDimension: Integer read GetZDimension write SetZDimension; |
|
This item has no description. |
property FdZSpacing: TSFFloat read FFdZSpacing; |
|
Internal wrapper for property |
property ZSpacing: Single read GetZSpacing write SetZSpacing; |
|
This item has no description. |
Generated by PasDoc 0.16.0-snapshot.