Class T3DList

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type T3DList = class(T3D)

Description

List of 3D objects (T3D instances), that can be treated like another, larger 3D object.

It inherits from T3D class, so this list is itself a 3D object, representing a sum of all it's children 3D objects. This allows you to group many 3D objects, and treat them as one T3D descendant.

Hierarchy

  • TComponent
  • T3D
  • T3DList

Overview

Methods

Protected function GetChild: T3D; virtual;
Protected procedure Notification(AComponent: TComponent; Operation: TOperation); override;
Protected function HeightCollision(const Position, GravityUp: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc; out AboveHeight: Single; out AboveGround: P3DTriangle): boolean; override;
Protected function MoveCollision( const OldPos, ProposedNewPos: TVector3Single; out NewPos: TVector3Single; const IsRadius: boolean; const Radius: Single; const OldBox, NewBox: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
Protected function MoveCollision( const OldPos, NewPos: TVector3Single; const IsRadius: boolean; const Radius: Single; const OldBox, NewBox: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
Protected function SegmentCollision(const Pos1, Pos2: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc; const ALineOfSight: boolean): boolean; override;
Protected function SphereCollision(const Pos: TVector3Single; const Radius: Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
Protected function BoxCollision(const Box: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
Protected function RayCollision(const RayOrigin, RayDirection: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): TRayCollision; override;
Public constructor Create(AOwner: TComponent); override;
Public destructor Destroy; override;
Public procedure Add(const Item: T3D);
Public procedure Insert(const Index: Integer; const Item: T3D);
Public procedure Remove(const Item: T3D);
Public function Count: Integer;
Public procedure Clear;
Public procedure SortZ;
Public function BoundingBox: TBox3D; override;
Public procedure Render(const Frustum: TFrustum; const Params: TRenderParams); override;
Public procedure RenderShadowVolume( ShadowVolumeRenderer: TBaseShadowVolumeRenderer; const ParentTransformIsIdentity: boolean; const ParentTransform: TMatrix4Single); override;
Public procedure PrepareResources( Options: TPrepareResourcesOptions; ProgressStep: boolean; BaseLights: TAbstractLightInstancesList); override;
Public function PrepareResourcesSteps: Cardinal; override;
Public function Press(const Event: TInputPressRelease): boolean; override;
Public function Release(const Event: TInputPressRelease): boolean; override;
Public procedure Update(const SecondsPassed: Single; var RemoveMe: TRemoveType); override;
Public procedure GLContextClose; override;
Public procedure UpdateGeneratedTextures( const RenderFunc: TRenderFromViewFunction; const ProjectionNear, ProjectionFar: Single; const OriginalViewport: TRectangle); override;
Public procedure VisibleChangeNotification(const Changes: TVisibleChanges); override;
Public function Dragging: boolean; override;

Properties

Public property Items[I:Integer]: T3D read GetItem write SetItem;
Published property List: T3DListCore read FList;

Description

Methods

Protected function GetChild: T3D; virtual;

Additional child inside the list, always processed before all children on the Items list. By default this method returns Nil, indicating no additional child exists. The presence of this child can be calculated in overriden method using any condition, which is sometimes more comfortable than adding item to Items.

This item cannot be removed by methods like T3DList.Remove or by setting RemoveMe in it's T3D.Update implementation. Presence of this item is completely determined by GetChild implementation.

Protected procedure Notification(AComponent: TComponent; Operation: TOperation); override;
 
Protected function HeightCollision(const Position, GravityUp: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc; out AboveHeight: Single; out AboveGround: P3DTriangle): boolean; override;
 
Protected function MoveCollision( const OldPos, ProposedNewPos: TVector3Single; out NewPos: TVector3Single; const IsRadius: boolean; const Radius: Single; const OldBox, NewBox: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
 
Protected function MoveCollision( const OldPos, NewPos: TVector3Single; const IsRadius: boolean; const Radius: Single; const OldBox, NewBox: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
 
Protected function SegmentCollision(const Pos1, Pos2: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc; const ALineOfSight: boolean): boolean; override;
 
Protected function SphereCollision(const Pos: TVector3Single; const Radius: Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
 
Protected function BoxCollision(const Box: TBox3D; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): boolean; override;
 
Protected function RayCollision(const RayOrigin, RayDirection: TVector3Single; const TrianglesToIgnoreFunc: T3DTriangleIgnoreFunc): TRayCollision; override;
 
Public constructor Create(AOwner: TComponent); override;
 
Public destructor Destroy; override;
 
Public procedure Add(const Item: T3D);

Operate on 3D objects contained in the list. You can also operate directly on List instance.

Public procedure Insert(const Index: Integer; const Item: T3D);
 
Public procedure Remove(const Item: T3D);
 
Public function Count: Integer;
 
Public procedure Clear;
 
Public procedure SortZ;

Sort based on average Z of 3D item bounding box. Useful when multiple 3D scenes use blending, and they are ordered in Z (like in most 2D scenes).

Public function BoundingBox: TBox3D; override;
 
Public procedure Render(const Frustum: TFrustum; const Params: TRenderParams); override;
 
Public procedure RenderShadowVolume( ShadowVolumeRenderer: TBaseShadowVolumeRenderer; const ParentTransformIsIdentity: boolean; const ParentTransform: TMatrix4Single); override;
 
Public procedure PrepareResources( Options: TPrepareResourcesOptions; ProgressStep: boolean; BaseLights: TAbstractLightInstancesList); override;
 
Public function PrepareResourcesSteps: Cardinal; override;
 
Public function Press(const Event: TInputPressRelease): boolean; override;
 
Public function Release(const Event: TInputPressRelease): boolean; override;
 
Public procedure Update(const SecondsPassed: Single; var RemoveMe: TRemoveType); override;
 
Public procedure GLContextClose; override;
 
Public procedure UpdateGeneratedTextures( const RenderFunc: TRenderFromViewFunction; const ProjectionNear, ProjectionFar: Single; const OriginalViewport: TRectangle); override;
 
Public procedure VisibleChangeNotification(const Changes: TVisibleChanges); override;
 
Public function Dragging: boolean; override;
 

Properties

Public property Items[I:Integer]: T3D read GetItem write SetItem;
 
Published property List: T3DListCore read FList;

3D objects inside. Freeing these items automatically removes them from this list.


Generated by PasDoc 0.14.0.