Standard |
The StandardMaterialBase type exposes the following members.
Name | Description | |
---|---|---|
AlphaClipThreshold | Pixels with alpha color values below this value will be clipped (not rendered and their depth will not be written to depth buffer). Expected values are between 0 and 1. When 0 (by default) then alpha clipping is disabled - this means that also pixels with alpha value 0 are fully processed (they are not visible but its depth value is still written so objects that are rendered afterwards and are behind the pixel will not be visible). | |
DiffuseColor | Gets or sets a Color3 that specifies the diffuse color of this material. Default value is Black. But when the DiffuseTexture is set and the user does not set the DiffuseColor, then the DiffuseColor is automatically set to White color to preserve the colors in the texture. | |
DiffuseTexture | Gets or sets a GpuImage objects that define the texture. When rendering texture, the colors from texture are multiplied by the DiffuseColor (White color is used when a texture is set and DiffuseColor is not changed by the user). When user does not set the DiffuseColor but sets the DiffuseTexture, then the DiffuseColor is automatically set to White color to preserve the colors in the texture. The GpuImage is not disposed when disposing this Material (except when calling DisposeWithTexture method). | |
DiffuseTextureSampler | Gets the GpuSampler that defines how the diffuse texture is read by the graphics card. The sampler can be set by DiffuseTextureSamplerType or by calling the SetDiffuseTextureSampler(GpuSampler) method. | |
DiffuseTextureSamplerType | Gets or sets the sampler type for the diffuse texture. Sampler type defines how the texture is read by the graphics card. Default value is Mirror. Setting this property sets the DiffuseTextureSampler with the actual GpuSampler when the material is initialized. It is also possible to set the DiffuseTextureSampler by calling the SetDiffuseTextureSampler(GpuSampler) method. | |
HasTransparency | Gets or sets a boolean that specifies if this material is semi-transparent and needs to be alpha blended with the scene. This value is automatically set to true when Opacity is set to a value smaller than 1. When using DiffuseTextures, user need to manually set the HasTransparency value based on the texture format and content. | |
IsPreMultipliedAlphaColor | When IsPreMultipliedAlphaColor is true (false by default) and Opacity is less then 1, then the color components of the DiffuseColor are already multiplied with alpha value to produce pre-multiplied colors. When false, then non-premultiplied color is converted in pre-multiplied color when this is required by the shader. Default value is false. | |
Opacity | Gets or sets a float value that defines the opacity for the material, for example 1 means fully opaque and 0 means fully transparent. When HasTransparency was not manually set, then changing Opacity value also updates HasTransparency value. Default value is 1; | |
TextureSource | Gets a source string that can contain file name or other string that defines the source of this GpuImage (TextureSource is read from GpuImage object and can be null even when DiffuseTexture is set). |