Vertices Engine  v1.9.2.92
A Cross Platform game engine developed by Virtex Edge Design.
Loading...
Searching...
No Matches
VerticesEngine.Graphics.vxMaterial Class Reference

A material is what is used to draw a mesh. It can expose common shader parameters along with allowing for expansion. More...

Inheritance diagram for VerticesEngine.Graphics.vxMaterial:
VerticesEngine.Editor.Entities.vxEditorEntityMaterial VerticesEngine.EnvTerrain.vxTerrainMaterial VerticesEngine.Graphics.vxSkyBoxMaterial VerticesEngine.Graphics.vxWaterMaterial

Public Member Functions

 vxMaterial (Effect effect)
 Creates a new material using the specified effect.
 
 vxMaterial (vxShader shader)
 Creates a new material using the specified shader.
 
virtual void Initalise ()
 
void Dispose ()
 
void SetPass ()
 
void CopyMaterial (vxMaterial material)
 Copies over material properties into this material.
 
void SetEffectParameter (string param, float value)
 
void SetEffectParameter (string param, float[] values)
 
void SetEffectParameter (string param, bool value)
 
void SetEffectParameter (string param, Vector2 value)
 
void SetEffectParameter (string param, Vector3 value)
 
void SetEffectParameter (string param, Vector4 value)
 
void SetEffectParameter (string param, Matrix value)
 
void SetEffectParameter (string param, Color value)
 
void SetEffectParameter (string param, Texture2D value)
 
void SetEffectParameter (string param, TextureCube value)
 
vxMaterial Clone ()
 

Public Attributes

bool ShouldDispose = true
 
string RenderTechnique = "Technique_Main"
 The Current Render Technique for thie Model.
 
string MaterialRenderPass
 Which pass should this material be drawn in?
 
vxUtilityEffect UtilityEffect
 The utility effect.
 

Protected Member Functions

virtual void InitEffectParams ()
 
virtual void OnDisposed ()
 

Protected Attributes

EffectParameter worldEffectParam
 
EffectParameter wvpEffectParam
 
EffectParameter worldInvTEffectParam
 
EffectParameter cameraViewEffectParam
 
EffectParameter cameraProjEffectParam
 
EffectParameter cameraPosEffectParam
 
string shaderkey_mainTexture = "Texture"
 
EffectParameter textureUVOffsetEffectParam
 
string shaderkey_normalMap = "NormalMap"
 
string shaderkey_rmaMap = "maps_RMA"
 

Properties

vxShader Shader [get]
 
EffectParameterCollection Parameters [get]
 
Matrix World [set]
 Sets the world.
 
Matrix WVP [set]
 The World * View * Projection Cumulative Matrix Value.
 
Matrix WorldInverseTranspose [set]
 
Matrix View [set]
 
Matrix Projection [set]
 
Vector3 CameraPosition [set]
 
float Alpha [get, set]
 Model Alpha Value for Transparency.
 
Texture2D Texture [get, set]
 Gets the Main Texture for this material. This will return null if no texture is set.
 
Color DiffuseColor [get, set]
 
Vector2 TextureUVOffset [get, set]
 Off Set for Textures Used On the Model. Uses the 'VX_UV0_OFFSET' shader param.
 
Vector2 UVFactor [get, set]
 A UV Factor to keep repeating UV Coordinates the same during plane scaling.
 
bool IsTextureEnabled [get, set]
 Toggles whether or not the main diffuse texture is shown.
 
bool IsNormalMapEnabled [get, set]
 
Texture2D NormalMap [get, set]
 Gets the Main Texture for this material. This will return null if no texture is set.
 
Texture2D RMAMap [get, set]
 Gets or Set's the RMA map for this material. There is a 4th channel used here, The Alpha channel is used for emissivity as well.
 
Texture2D AlphaMaskTexture [get, set]
 
float AlphaMaskCutoff [get, set]
 
bool IsDefferedRenderingEnabled [get, set]
 Should this material be drawn to the derffered back buffers.
 
bool IsTransparentDefferedRenderingEnabled [get, set]
 If this is a transparent item but we still want to do distortion.
 
float SpecularIntensity [get, set]
 SpecularIntensity of the Shader.
 
float SpecularPower [get, set]
 SpecularIntensity of the Shader.
 
Vector3 LightDirection [get, set]
 The Light Direction which is Shining on this Object.
 
Color LightColor [get, set]
 The Light Colour to be used in the Model Shader.
 
Color AmbientLightColor [get, set]
 The Ambient Light Colour for this Models Shader.
 
float AmbientLightIntensity [get, set]
 Gets or sets the ambient light intensity.
 
float DiffuseIntensity [get, set]
 
bool IsEmissionEnabled [get, set]
 
Texture2D EmissionMap [get, set]
 The Emission Map.
 
Color EmissiveColour [get, set]
 Emissive Colour for use in Highlighting a Model.
 
float EmissiveIntensity [get, set]
 
TextureCube ReflectionTextureCube [get, set]
 Texture which is applied as the Reflection Texture. NOTE: This must be added to the Main Model Shader.
 
ReflectionType ReflectionType [get, set]
 
bool IsBasicReflectionsEnabled [get, set]
 
bool IsSSREnabled [get, set]
 Is SSR enabled for this entity.
 
float ReflectionIntensity [get, set]
 The overall Reflection Amount to be applied in the Shader.
 
float FresnelBias [get, set]
 
float FresnelPower [get, set]
 
bool IsShadowCaster [get, set]
 Gets or sets a value indicating whether this T:VerticesEngine.Entities.vxEntity3D should do shadow map.
 
float ShadowBrightness [get, set]
 Gets or sets the shadow brightness.
 
bool IsDistortionEnabled [get, set]
 Gets or sets a value indicating whether this T:VerticesEngine.Entities.vxEntity3D render shadow split index.
 
float DistortionScale [get, set]
 A global amount controlling the amount of distortion this entity causes.
 
Texture2D DistortionMap [get, set]
 The Distortion Map.
 
Vector2 DistortionUVOffset [get, set]
 Off Set for Textures Used On the Model.
 
bool IsAuxDepthCalculated [get, set]
 Is this entity used in a auxiliary depth calucaltions.
 

Detailed Description

A material is what is used to draw a mesh. It can expose common shader parameters along with allowing for expansion.

Constructor & Destructor Documentation

◆ vxMaterial() [1/2]

VerticesEngine.Graphics.vxMaterial.vxMaterial ( Effect effect)

Creates a new material using the specified effect.

Parameters
shader

◆ vxMaterial() [2/2]

VerticesEngine.Graphics.vxMaterial.vxMaterial ( vxShader shader)

Creates a new material using the specified shader.

Parameters
shader

Member Function Documentation

◆ CopyMaterial()

void VerticesEngine.Graphics.vxMaterial.CopyMaterial ( vxMaterial material)

Copies over material properties into this material.

Parameters
material

Property Documentation

◆ AmbientLightIntensity

float VerticesEngine.Graphics.vxMaterial.AmbientLightIntensity
getset

Gets or sets the ambient light intensity.

The ambient light intensity.

◆ IsDistortionEnabled

bool VerticesEngine.Graphics.vxMaterial.IsDistortionEnabled
getset

Gets or sets a value indicating whether this T:VerticesEngine.Entities.vxEntity3D render shadow split index.

true if render shadow split index; otherwise, false.

The Poisson Kernel to be used for Shadow Mapping Edge Blending

Gets the random texture2 d.

The random texture2 d.

◆ IsShadowCaster

bool VerticesEngine.Graphics.vxMaterial.IsShadowCaster
getset

Gets or sets a value indicating whether this T:VerticesEngine.Entities.vxEntity3D should do shadow map.

true if do shadow map; otherwise, false.

◆ ShadowBrightness

float VerticesEngine.Graphics.vxMaterial.ShadowBrightness
getset

Gets or sets the shadow brightness.

The shadow brightness.

◆ World

Matrix VerticesEngine.Graphics.vxMaterial.World
set

Sets the world.

The world.


The documentation for this class was generated from the following file: