SetMaterialAttribute()

Syntax

SetMaterialAttribute(#Material, Attribute, Value [, Layer])
Description
Sets the specified attribute value to the given material.

Parameters

#Material The material to use.
Attribute The attribute to set. It can be one of the following values:
  #PB_Material_DepthCheck : Enables or disables the depth check for the material.
                            Value can be #True (depth check enabled) or #False (depth check disabled).
  #PB_Material_DepthWrite : Enables or disables the depth write for the material.
                            Value can be #True (depth write enabled) or #False (depth write disabled).
  #PB_Material_AlphaReject: Enables alpha reject on the texture (useful for semi transparent textures like
                            trees, window, etc).
  #PB_Material_TAM        : Changes the 'Texture Addressing Mode' (TAM). It can be one of the following values:
                            #PB_Material_WrapTAM  : wrap mode
                            #PB_Material_MirrorTAM: mirror mode
                            #PB_Material_ClampTAM : clamp mode
                            #PB_Material_BorderTAM: border mode
  #PB_Material_EnvironmentMap: Enables environment map. It can be one of the following values:
                            #PB_Material_NoMap        : disable environment map
                            #PB_Material_PlanarMap    : planar environment map
                            #PB_Material_CurvedMap    : curved environment map
                            #PB_Material_ReflectionMap: reflection environment map
                            #PB_Material_NormalMap    : normal environment map
 #PB_Material_ProjectiveTexturing: Enable projective texturing for this material. The value is a #Camera number to use.
 #PB_Material_PointSprite : Enables or disables point sprite for the material.
                            If greater than zero, the value is the point size / 1000. If zero, point size is disabled.
 #PB_Material_DepthBias   : Enables or disables the depth bias for the material.
                            If greater than zero, the value is the depth bias / 1000. If zero, depth bias is disabled.

Value Value of the attribute to set.
Layer (optional) The layer to use. The first layer is zero (if this parameter is omitted, the layer zero is used).

Return value

None.

See Also

GetMaterialAttribute()

Supported OS

All

<- ScrollMaterial() - Material Index - SetMaterialColor() ->