Class TCastleRenderOptions
Unit
Declaration
type TCastleRenderOptions = class(TCastleComponent)
Description
Options that control rendering, available at every scene through TCastleScene.RenderOptions.
Source: base/castlerenderoptions_renderoptions.inc (line 26).
Hierarchy
- TObject
- TPersistent
- TComponent
- TCastleComponent
- TCastleRenderOptions
Overview
Constants
| Public | DefaultPointSize = 3.0; |
| Public | DefaultLineWidth = 2.0; |
| Public | DefaultBumpMapping = bmBasic; |
| Public | DefaultBumpMappingParallaxHeight = 0.01; |
| Public | DefaultPhongShading = true; |
| Public | DefaultMaxLightsPerShape = 64; |
| Public | DefaultBlendingSourceFactor = bsSrcAlpha; |
| Public | DefaultBlendingDestinationFactor = bdOneMinusSrcAlpha; |
| Public | DefaultWireframeColor: TCastleColorRGB = (X: 0; Y: 0; Z: 0); |
| Public | DefaultSolidWireframeScale = 1; |
| Public | DefaultSolidWireframeBias = 1; |
| Public | DefaultSilhouetteScale = 5; |
| Public | DefaultSilhouetteBias = 5; |
| Public | DefaultShadowSampling = ssPCF16; |
Fields
| Public | class var DefaultMinificationFilter: TMinificationFilter; |
| Public | DefaultMagnificationFilter: TMagnificationFilter; |
| Public | OnCreate: TCastleRenderOptionsEvent; |
Methods
| Protected | function GetInternalText: String; virtual; |
| Protected | procedure SetInternalText(const Value: String); virtual; |
| Protected | procedure SetName(const Value: TComponentName); override; |
| Protected | procedure TranslateProperties(const TranslatePropertyEvent: TTranslatePropertyEvent); virtual; |
| Public | procedure SetTransient; |
| Public | procedure AddNonVisualComponent(const NonVisualComponent: TComponent); |
| Public | procedure InsertNonVisualComponent(const Index: Integer; const NonVisualComponent: TComponent); |
| Public | procedure RemoveNonVisualComponent(const NonVisualComponent: TComponent); |
| Public | function NonVisualComponentsIndexOf(const NonVisualComponent: TComponent): Integer; |
| Public | function NonVisualComponentsCount: Integer; |
| Public | function NonVisualComponentsEnumerate: TNonVisualComponentsEnumerator; |
| Public | function ValueIsStreamed: Boolean; virtual; |
| Public | procedure DesignerInfo(const SList: TStrings); virtual; |
| Public | procedure DesignerWarnings(const SList: TStrings); virtual; |
| Protected | procedure ReleaseCachedResources; virtual; |
| Public | constructor Create(AOwner: TComponent); override; |
| Public | destructor Destroy; override; |
| Public | procedure CustomSerialization(const SerializationProcess: TSerializationProcess); override; |
| Public | function PropertySections(const PropertyName: String): TPropertySections; override; |
| Public | procedure Assign(Source: TPersistent); override; |
| Public | function Equals(Obj: TObject): Boolean; override; |
Properties
| Public | property NonVisualComponents [const Index: Integer]: TComponent read GetNonVisualComponents; |
| Public | property IsLoading: Boolean read FIsLoading; |
| Public | property Mode: TRenderingMode read FMode write SetMode default rmFull; |
| Public | property DepthTest: boolean read FDepthTest write SetDepthTest default true; |
| Public | property SolidColor: TCastleColorRGB read FSolidColor write SetSolidColor; |
| Public | property WireframeColor: TCastleColorRGB
read FWireframeColor write SetWireframeColor; |
| Public | property InternalColorChannels: TColorChannels
read FColorChannels write SetColorChannels default AllColorChannels; |
| Published | property Lighting: boolean read FLighting write SetLighting default true; |
| Published | property ReceiveSceneLights: boolean
read FReceiveSceneLights write SetReceiveSceneLights default true; |
| Published | property ReceiveGlobalLights: boolean
read FReceiveGlobalLights write SetReceiveGlobalLights default true; |
| Published | property Textures: boolean
read FTextures write SetTextures default true; |
| Published | property MinificationFilter: TAutoMinificationFilter
read FMinificationFilter write SetMinificationFilter default minDefault; |
| Published | property MagnificationFilter: TAutoMagnificationFilter
read FMagnificationFilter write SetMagnificationFilter default magDefault; |
| Published | property PointSize: Single
read FPointSize write SetPointSize stored IsStoredPointSize; |
| Published | property LineWidth: Single
read FLineWidth write SetLineWidth stored IsStoredLineWidth; |
| Published | property BumpMapping: TBumpMapping
read FBumpMapping write SetBumpMapping default DefaultBumpMapping; |
| Published | property BumpMappingParallaxHeight: Single
read FBumpMappingParallaxHeight write SetBumpMappingParallaxHeight
stored IsStoredBumpMappingParallaxHeight; |
| Published | property PhongShading: boolean read FPhongShading write SetPhongShading
default DefaultPhongShading; |
| Published | property ShadowSampling: TShadowSampling
read FShadowSampling write SetShadowSampling
default DefaultShadowSampling; |
| Published | property MaxLightsPerShape: Cardinal
read FMaxLightsPerShape write SetMaxLightsPerShape default DefaultMaxLightsPerShape; |
| Published | property Blending: boolean
read FBlending write SetBlending default true; |
| Published | property BlendingSourceFactor: TBlendingSourceFactor
read FBlendingSourceFactor write SetBlendingSourceFactor
default DefaultBlendingSourceFactor; |
| Published | property BlendingDestinationFactor: TBlendingDestinationFactor
read FBlendingDestinationFactor write SetBlendingDestinationFactor
default DefaultBlendingDestinationFactor; |
| Published | property WireframeEffect: TWireframeEffect
read FWireframeEffect write SetWireframeEffect default weNormal; |
| Published | property SolidWireframeScale: Single
read FSolidWireframeScale write SetSolidWireframeScale stored IsStoredSolidWireframeScale; |
| Published | property SolidWireframeBias: Single
read FSolidWireframeBias write SetSolidWireframeBias stored IsStoredSolidWireframeBias; |
| Published | property SilhouetteScale: Single
read FSilhouetteScale write SetSilhouetteScale stored IsStoredSilhouetteScale; |
| Published | property SilhouetteBias: Single
read FSilhouetteBias write SetSilhouetteBias stored IsStoredSilhouetteBias; |
| Published | property RobustNegativeScale: Boolean
read FRobustNegativeScale write SetRobustNegativeScale default false; |
| Published | property WholeSceneManifold: Boolean
read FWholeSceneManifold write SetWholeSceneManifold default false; |
| Published | property SkinnedAnimationShaders: Boolean
read FSkinnedAnimationShaders write SetSkinnedAnimationShaders default true; |
| Published | property WireframeColorPersistent: TCastleColorRGBPersistent read FWireframeColorPersistent ; |
Description
Constants
| Public | DefaultPointSize = 3.0; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 122). | |
| Public | DefaultLineWidth = 2.0; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 123). | |
| Public | DefaultBumpMapping = bmBasic; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 124). | |
| Public | DefaultBumpMappingParallaxHeight = 0.01; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 125). | |
| Public | DefaultPhongShading = true; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 126). | |
| Public | DefaultMaxLightsPerShape = 64; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 127). | |
| Public | DefaultBlendingSourceFactor = bsSrcAlpha; |
|
Default value of TCastleRenderOptions.BlendingSourceFactor. This is the typical blending operation. Source: base/castlerenderoptions_renderoptions.inc (line 131). | |
| Public | DefaultBlendingDestinationFactor = bdOneMinusSrcAlpha; |
|
Default value of TCastleRenderOptions.BlendingDestinationFactor. This is the typical blending operation. Source: base/castlerenderoptions_renderoptions.inc (line 135). | |
| Public | DefaultWireframeColor: TCastleColorRGB = (X: 0; Y: 0; Z: 0); |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 137). | |
| Public | DefaultSolidWireframeScale = 1; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 139). | |
| Public | DefaultSolidWireframeBias = 1; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 140). | |
| Public | DefaultSilhouetteScale = 5; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 141). | |
| Public | DefaultSilhouetteBias = 5; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 142). | |
| Public | DefaultShadowSampling = ssPCF16; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 144). | |
Fields
| Public | class var DefaultMinificationFilter: TMinificationFilter; |
|
Value used when MinificationFilter is minDefault. By default, this is minLinearMipmapLinear. Source: base/castlerenderoptions_renderoptions.inc (line 149). | |
| Public | DefaultMagnificationFilter: TMagnificationFilter; |
|
Value used when MagnificationFilter is magDefault. By default, this is magLinear. Source: base/castlerenderoptions_renderoptions.inc (line 152). | |
| Public | OnCreate: TCastleRenderOptionsEvent; |
|
Adjust attributes of all loaded resources. Source: base/castlerenderoptions_renderoptions.inc (line 154). | |
Methods
| Protected | function GetInternalText: String; virtual; |
|
This item is declared in ancestor TCastleComponent. This item has no description. | |
| Protected | procedure SetInternalText(const Value: String); virtual; |
|
This item is declared in ancestor TCastleComponent. This item has no description. | |
| Protected | procedure SetName(const Value: TComponentName); override; |
|
This item is declared in ancestor TCastleComponent. This item has no description. | |
| Protected | procedure TranslateProperties(const TranslatePropertyEvent: TTranslatePropertyEvent); virtual; |
|
This item is declared in ancestor TCastleComponent. Enumerate all properties that are possible to translate in this component. E.g. in TCastleLabel it will return TCastleLabel.Caption, in TCastleEdit it will return TCastleEdit.Text and TCastleEdit.Placeholder. Returns only non-empty properties, thus assuming that if current (by convention, English) text is empty, then there is no point in translating it. Moreover descendants may define boolean properties to exclude particular text from translating, e.g. TCastleLabel.CaptionTranslate, TCastleEdit.TextTranslate, TCastleEdit.PlaceholderTranslate. It is not recursive (it doesn't enumerate children properties). Use global TranslateProperties procedure to call this on a hierarchy of TComponent. You usually don't want to call this method (it is called by other engine routines). But you may find it useful to override this, if you define new component. | |
| Public | procedure SetTransient; |
|
This item is declared in ancestor TCastleComponent. Ignore this component when serializing parent's TCastleUserInterface.Controls list or TCastleTransform.List, and do not show this component in CGE editor. This simply sets csTransient flag in ComponentStyle. This is useful for children that are automatically managed by the parent, and should not be modified by user code. For example, TCastleCheckbox is internally composed from TCastleImageControl and TCastleLabel children, but we don't want to serialize or even show these children to user. Note that if you want to prevent this component from serializing as part of TCastleUserInterface.Controls list or TCastleTransform.List, but you still want it to be visible in CGE editor, then make it a "subcomponent" instead, by Note that both csSubComponent and csTransient only disable the component serialization as part of parent's lists enumerated by CustomSerialization (see internal TCastleUserInterface.SerializeChildrenEnumerate , TCastleTransform.SerializeChildrenEnumerate, TCastleTransform.SerializeBehaviorsEnumerate). If you will make the component published in its own property (which is normal for "subcomponents") then it will be serialized anyway, just as part of it's own property (like TCastleScrollView.ScrollArea). So to really avoid serializing a children component make it csSubComponent and/or csTransient, and do not publish it. | |
| Public | procedure AddNonVisualComponent(const NonVisualComponent: TComponent); |
|
This item is declared in ancestor TCastleComponent. Add non-visual component to this component. This is used to organize non-visual components in a tree hierarchy, in CGE designs and editor.
See also
| |
| Public | procedure InsertNonVisualComponent(const Index: Integer; const NonVisualComponent: TComponent); |
|
This item is declared in ancestor TCastleComponent. Insert non-visual component to this component. This is used to organize non-visual components in a tree hierarchy, in CGE designs and editor.
See also
| |
| Public | procedure RemoveNonVisualComponent(const NonVisualComponent: TComponent); |
|
This item is declared in ancestor TCastleComponent. Removes the component previously added by AddNonVisualComponent. | |
| Public | function NonVisualComponentsIndexOf(const NonVisualComponent: TComponent): Integer; |
|
This item is declared in ancestor TCastleComponent. Index of the previously added non-visual component. Returns -1 if the component was not found. | |
| Public | function NonVisualComponentsCount: Integer; |
|
This item is declared in ancestor TCastleComponent. Count of components added by AddNonVisualComponent.
See also
| |
| Public | function NonVisualComponentsEnumerate: TNonVisualComponentsEnumerator; |
|
This item is declared in ancestor TCastleComponent.
You can enumerate current non-visual components using loop like See also
| |
| Public | function ValueIsStreamed: Boolean; virtual; |
|
This item is declared in ancestor TCastleComponent.
Whether the current value of this object should be written to the stream. This should be This is used by CastleComponentSerialize, which is used in Castle Game Engine for all serialization. In simple cases, this just says whether the current value of this object equals to some default value. The default implementation of this class returns Descendants that override this to sometimes return The name of this method is consistent with TPropertyEditor.ValueIsStreamed in LCL. | |
| Public | procedure DesignerInfo(const SList: TStrings); virtual; |
|
This item is declared in ancestor TCastleComponent.
Override to add information that should be visible at design-time. Call | |
| Public | procedure DesignerWarnings(const SList: TStrings); virtual; |
|
This item is declared in ancestor TCastleComponent.
Override to add warnings that should be visible at design-time. Call | |
| Protected | procedure ReleaseCachedResources; virtual; |
|
Called before changing an attribute that requires the release of things cached in a renderer. This includes attributes that affect:
Source: base/castlerenderoptions_renderoptions.inc (line 119). | |
| Public | constructor Create(AOwner: TComponent); override; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 156). | |
| Public | destructor Destroy; override; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 157). | |
| Public | procedure CustomSerialization(const SerializationProcess: TSerializationProcess); override; |
|
This item has no description. Showing description inherited from TCastleComponent.CustomSerialization. Override this method to call various methods of SerializationProcess, which in turn allows to serialize/deserialize things that are not published. This allows to serialize/deserialize with more freedom, e.g. to serialize/deserialize some private field. Source: base/castlerenderoptions_renderoptions.inc (line 158). | |
| Public | function PropertySections(const PropertyName: String): TPropertySections; override; |
|
This item has no description. Showing description inherited from TCastleComponent.PropertySections. Section where to show property in the editor. Source: base/castlerenderoptions_renderoptions.inc (line 159). | |
| Public | procedure Assign(Source: TPersistent); override; |
|
Copies all propeties from Source, the same properties that affect Equals. Source: base/castlerenderoptions_renderoptions.inc (line 163). | |
| Public | function Equals(Obj: TObject): Boolean; override; |
|
Equal TCastleRenderOptions produce the same effect when rendering and can be treated as exactly equivalent by the TCastleViewport.DynamicBatching algorithm. Source: base/castlerenderoptions_renderoptions.inc (line 168). | |
Properties
| Public | property NonVisualComponents [const Index: Integer]: TComponent read GetNonVisualComponents; |
|
This item is declared in ancestor TCastleComponent. Components added by AddNonVisualComponent. | |
| Public | property IsLoading: Boolean read FIsLoading; |
|
This item is declared in ancestor TCastleComponent. Is the component during deserialization now. Note: We can't use | |
| Public | property Mode: TRenderingMode read FMode write SetMode default rmFull; |
|
Rendering mode, can be used to disable many rendering features at once. Source: base/castlerenderoptions_renderoptions.inc (line 178). | |
| Public | property DepthTest: boolean read FDepthTest write SetDepthTest default true; |
|
By default, we use depth testing to determine which objects are in front of the others. This allows to display all 3D content (all TCastleScene instances, and all shapes inside them) in any order. For very special purposes, you can disable depth testing. This means that 3D objects will always be drawn in front of the previous ones, in the order in which they are rendered, ignoring the contents of the depth buffer. Use only if you know what you're doing, if you're sure that the order of rendering will always be good. Source: base/castlerenderoptions_renderoptions.inc (line 190). | |
| Public | property SolidColor: TCastleColorRGB read FSolidColor write SetSolidColor; |
|
Color used when Mode is rmSolidColor. By default BlackRGB. Source: base/castlerenderoptions_renderoptions.inc (line 194). | |
| Public | property WireframeColor: TCastleColorRGB
read FWireframeColor write SetWireframeColor; |
|
Wireframe color, used with some WireframeEffect values. Default value is DefaultWireframeColor. Source: base/castlerenderoptions_renderoptions.inc (line 198). | |
| Public | property InternalColorChannels: TColorChannels
read FColorChannels write SetColorChannels default AllColorChannels; |
|
Which color buffer channels (RGBA) to write when rendering this model. This makes a cool effect, avoiding writing to some color channels, but writing others, and writing depth buffer. This property may change to be non-internal some day, please report on Castle Game Engine forum / Discord / GitHub ( https://castle-engine.io/talk.php ) if you find it useful. Source: base/castlerenderoptions_renderoptions.inc (line 208). | |
| Published | property Lighting: boolean read FLighting write SetLighting default true; |
|
Enable real-time lighting when rendering. Source: base/castlerenderoptions_renderoptions.inc (line 212). | |
| Published | property ReceiveSceneLights: boolean
read FReceiveSceneLights write SetReceiveSceneLights default true; |
|
Use lights defined in this scene (in the model loaded to this TCastleScene) to light the shapes in this scene. Note: This property controls whether lights defined within a model (TCastleScene) affect the shapes in the same model. In case of such lights, the value of TCastleScene.CastGlobalLights and ReceiveGlobalLights doesn't matter. Only this property, The other lights are controlled by ReceiveGlobalLights. This doesn't matter if Lighting is Source: base/castlerenderoptions_renderoptions.inc (line 228). | |
| Published | property ReceiveGlobalLights: boolean
read FReceiveGlobalLights write SetReceiveGlobalLights default true; |
|
Use lights defined in other scenes to light the shapes in this scene. This property controls whether other scenes with TCastleScene.CastGlobalLights, as well as headlight, shine on this scene. This doesn't matter if Lighting is Source: base/castlerenderoptions_renderoptions.inc (line 240). | |
| Published | property Textures: boolean
read FTextures write SetTextures default true; |
|
Use textures. Source: base/castlerenderoptions_renderoptions.inc (line 244). | |
| Published | property MinificationFilter: TAutoMinificationFilter
read FMinificationFilter write SetMinificationFilter default minDefault; |
|
Default minification and magnification filters for textures. These can be overridden on a per-texture basis in VRML / X3D files by X3D TextureProperties node (see X3D specification). They can be equal to minDefault, magDefault in which case they actually use the values from DefaultMinificationFilter, DefaultMagnificationFilter (by default minLinearMipmapLinear, magLinear). Source: base/castlerenderoptions_renderoptions.inc (line 257). | |
| Published | property MagnificationFilter: TAutoMagnificationFilter
read FMagnificationFilter write SetMagnificationFilter default magDefault; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 259). | |
| Published | property PointSize: Single
read FPointSize write SetPointSize stored IsStoredPointSize; |
|
Size of points. This has an effect on TPointSetNode rendering. Must be > 0. Source: base/castlerenderoptions_renderoptions.inc (line 265). | |
| Published | property LineWidth: Single
read FLineWidth write SetLineWidth stored IsStoredLineWidth; |
|
Line width. This has an effect on TLineSetNode rendering, and on wireframe rendering when TCastleRenderOptions.WireframeEffect indicates it. Must be > 0. Source: base/castlerenderoptions_renderoptions.inc (line 271). | |
| Published | property BumpMapping: TBumpMapping
read FBumpMapping write SetBumpMapping default DefaultBumpMapping; |
|
Use bump mapping. The bump mapping is only done when particular shape defines a normal map (and a height map, if you want parallax bump mapping). See https://castle-engine.io/bump_mapping . The normal map is usually provided in the TAbstractOneSidedMaterialNode.NormalTexture field. TAbstractOneSidedMaterialNode is an ancestor of all useful material nodes, like TMaterialNode (Phong lighting), TPhysicalMaterialNode (PBR lighting), and even TUnlitMaterialNode (unlit – doesn't use normals for lighting, but may still use them e.g. for tex coord generation). So all material nodes allow to specify normal map. See TBumpMapping for various possible values. Source: base/castlerenderoptions_renderoptions.inc (line 288). | |
| Published | property BumpMappingParallaxHeight: Single
read FBumpMappingParallaxHeight write SetBumpMappingParallaxHeight
stored IsStoredBumpMappingParallaxHeight; |
|
Maximum height expressed in the normal map alpha channel, used only when BumpMapping indicates one of the "parallax" options. By default this is ignored because BumpMapping by default is just bmBasic, which ignores the height map in the normal map alpha channel. If your normal map includes an alpha channel, and you set BumpMapping to a value bmParallax, bmSteepParallax, bmSteepParallaxShadowing then this property is used to interpret the height information. Source: base/castlerenderoptions_renderoptions.inc (line 299). | |
| Published | property PhongShading: boolean read FPhongShading write SetPhongShading
default DefaultPhongShading; |
|
Whether to use Phong shading by default. Note that each shape may override it by TAbstractShapeNode.Shading field. Note that Phong shading is forced anyway by various situations:
Source: base/castlerenderoptions_renderoptions.inc (line 315). | |
| Published | property ShadowSampling: TShadowSampling
read FShadowSampling write SetShadowSampling
default DefaultShadowSampling; |
|
Shadow maps sampling. Various approaches result in various quality and speed. Source: base/castlerenderoptions_renderoptions.inc (line 319). | |
| Published | property MaxLightsPerShape: Cardinal
read FMaxLightsPerShape write SetMaxLightsPerShape default DefaultMaxLightsPerShape; |
|
For efficiency reasons, we only allow a finite number of lights that can affect the given shape. You can increase this number if necessary, although note that it is alreday quite large by default. Instead of increasing this limit, it is always more efficient to design your scenes to fit within this limit. Use the light source radius and/or scope (e.g. you can use "radius" in Blender, it is exported OK to glTF), and make smaller shapes. Note that on ancient dekstops, with fixed-function OpenGL pipeline, there is an additional hard limit (dependent on GPU, but usually 8, for this). But on modern desktops, as well as mobile and other platforms, you can increase this limit freely. Source: base/castlerenderoptions_renderoptions.inc (line 337). | |
| Published | property Blending: boolean
read FBlending write SetBlending default true; |
|
Render partially transparent objects. More precisely: if this is If this is Source: base/castlerenderoptions_renderoptions.inc (line 349). | |
| Published | property BlendingSourceFactor: TBlendingSourceFactor
read FBlendingSourceFactor write SetBlendingSourceFactor
default DefaultBlendingSourceFactor; |
|
Blending function parameters, used when Blending. See https://castle-engine.io/blending for more information about blending. For the exact meaning of The typical blending setup (default) is to use
This is the standard that follows most intuitive transparency equation. The major drawback of this default (and why you may want to consider alternatives) is that it depends on a correct order of rendering partially-transparent shapes. CGE allows to cope with it:
Note that these properties can be overridden on each shape using TBlendModeNode. See https://castle-engine.io/x3d_extensions.php#section_ext_blending for details of TBlendModeNode. Source: base/castlerenderoptions_renderoptions.inc (line 417). | |
| Published | property BlendingDestinationFactor: TBlendingDestinationFactor
read FBlendingDestinationFactor write SetBlendingDestinationFactor
default DefaultBlendingDestinationFactor; |
|
This item has no description. Source: base/castlerenderoptions_renderoptions.inc (line 420). | |
| Published | property WireframeEffect: TWireframeEffect
read FWireframeEffect write SetWireframeEffect default weNormal; |
|
Activate various effects related to wireframe rendering. When this is weNormal (default), we simply render polygons as polygons. See description of TWireframeEffect for what other modes do. Note: How the wireframe effects work when Mode = rmDepth is undefined now. Don't use Mode = rmDepth with Source: base/castlerenderoptions_renderoptions.inc (line 431). | |
| Published | property SolidWireframeScale: Single
read FSolidWireframeScale write SetSolidWireframeScale stored IsStoredSolidWireframeScale; |
|
Depth scale in SolidWireframeScale and depth bias in SolidWireframeBias are used to render the mesh when WireframeEffect = weSolidWireframe. Larger values will "push forward" the rendered mesh a bit, meaning that the wireframe will be more clearly visible in front of it. To explain it best, understand how rendering with WireframeEffect = weSolidWireframe is done:
Source: base/castlerenderoptions_renderoptions.inc (line 460). | |
| Published | property SolidWireframeBias: Single
read FSolidWireframeBias write SetSolidWireframeBias stored IsStoredSolidWireframeBias; |
|
See SolidWireframeScale for explanation. Source: base/castlerenderoptions_renderoptions.inc (line 464). | |
| Published | property SilhouetteScale: Single
read FSilhouetteScale write SetSilhouetteScale stored IsStoredSilhouetteScale; |
|
Depth scale in SilhouetteScale and depth bias in SilhouetteBias are used to render the silhouette when WireframeEffect = weSilhouette. Larger values will "push back" the rendered lines a bit, meaning that the effect will more clearly outline the object, and not look like a wireframe over the object. To explain it best, understand how rendering with WireframeEffect = weSilhouette is done:
When both SilhouetteScale and SilhouetteBias are zero, the wireframe is rendered with the same depth as a regular object, and it's undefined which one will be visible . Most likely it will look similar to WireframeEffect = weSolidWireframe actually. When both SilhouetteScale and SilhouetteBias are > zero, then only the lines that are "silhouettes" will be visible – other lines will be hidden by the object rendered in the 1st pass. You can make the effect more or less "subtle" by changing these parameters. Source: base/castlerenderoptions_renderoptions.inc (line 505). | |
| Published | property SilhouetteBias: Single
read FSilhouetteBias write SetSilhouetteBias stored IsStoredSilhouetteBias; |
|
See SilhouetteScale for explanation. Source: base/castlerenderoptions_renderoptions.inc (line 509). | |
| Published | property RobustNegativeScale: Boolean
read FRobustNegativeScale write SetRobustNegativeScale default false; |
|
Support lighting and backface culling for models using negative scale. This has a small performance cost, and so is disabled by default. Source: base/castlerenderoptions_renderoptions.inc (line 514). | |
| Published | property WholeSceneManifold: Boolean
read FWholeSceneManifold write SetWholeSceneManifold default false; |
|
Use this scene as a shadow caster for shadow volumes, regardless of whether it is detected as 2-manifold. Note: The engine automatically detects if a scene is 2-manifold, which can mean that:
If the engine detected that scene is 2-manifold (regardless of whether each shape was 2-manifold or only whole scene is 2-manifold) then using this property is not necessary. Setting this property to
Source: base/castlerenderoptions_renderoptions.inc (line 571). | |
| Published | property SkinnedAnimationShaders: Boolean
read FSkinnedAnimationShaders write SetSkinnedAnimationShaders default true; |
|
Enable using GPU shaders to animate skinned models. This is advised, as it increases performance of skinned. There are however certain cases when disabling this may be necessary: https://castle-engine.io/gltf#_alternative_solution_force_recalculating_precise_octree_every_frame Note that in certain cases, skinned animation on GPU is disabled even when this property is Source: base/castlerenderoptions_renderoptions.inc (line 582). | |
| Published | property WireframeColorPersistent: TCastleColorRGBPersistent read FWireframeColorPersistent ; |
|
WireframeColor that can be visually edited in Castle Game Engine Editor, Lazarus and Delphi. Normal user code does not need to deal with this, instead read or write WireframeColor directly. See also
| |
Generated by PasDoc 0.17.0.snapshot.