Class TGLRenderer
Unit
CastleRenderer
Declaration
type TGLRenderer = class(TObject)
Description
Hierarchy
Overview
Fields
Methods
Properties
Description
Fields
 |
PrepareRenderShape: Cardinal; |
If > 0, RenderShape will not actually render, only prepare per-shape resources for fast rendering (arrays and vbos).
|
Methods
 |
destructor Destroy; override; |
|
 |
procedure Prepare(State: TX3DGraphTraverseState); |
Prepare given State, to be able to render shapes with it. Between preparing and unpreparing, nodes passed here are "frozen": do not change, do not free them.
|
 |
procedure UnprepareAll; |
Release every OpenGL and VRML resource. That is release any knowledge connecting us to the current OpenGL context and any knowledge about your prepared VRML nodes, states etc.
Calling UnprepareAll is valid (and ignored) call if everything is already released.
Destructor callls UnprepareAll automatically. So be sure to either call UnprepareAll or destroy this renderer when your OpenGL context is still active.
|
 |
procedure RenderEnd; |
|
 |
procedure UpdateGeneratedTextures(Shape: TShape; TextureNode: TAbstractTextureNode; const Render: TRenderFromViewFunction; const ProjectionNear, ProjectionFar: Single; var NeedsRestoreViewport: boolean; CurrentViewpoint: TAbstractViewpointNode; CameraViewKnown: boolean; const CameraPosition, CameraDirection, CameraUp: TVector3Single); |
Update generated texture for this shape.
NeedsRestoreViewport will be set to True if viewport was (possibly) changed by this procedure (otherwise, NeedsRestoreViewport will not be modified).
|
 |
procedure PrepareScreenEffect(Node: TScreenEffectNode); |
Load GLSL shader for the ScreenEffect node. Makes sure that Node.ShaderLoaded is true. When changing Node.ShaderLoaded false to true tries to initialize the shader, setting Node.Shader if some GLSL program was successfully loaded.
The GLSL program (TGLSLProgram) will be stored here, and will be automatically freed during UnprepareAll call.
|
Properties
 |
property Attributes: TRenderingAttributes read FAttributes; |
Rendering attributes. You can change them only when renderer is not tied to the current OpenGL context, so only after construction or after UnprepareAll call (before any Prepare or Render* calls).
|
Generated by PasDoc 0.13.0 on 2013-08-17 21:27:13
|