The three virtues of a programmer: Laziness, Impatience, and Hubris. – Larry Wall

UE3:MaterialInstance (UT3)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UT3 Object >> Surface >> MaterialInterface >> MaterialInstance
Package: 
Engine
Direct subclasses:
MaterialInstanceConstant, MaterialInstanceTimeVarying
This class in other games:
UDK

Copyright 1998-2007 Epic Games, Inc. All Rights Reserved.

Properties

Property group 'MaterialInstance'

Parent

Type: MaterialInterface

Modifiers: const


PhysMaterial

Type: PhysicalMaterial

Physical material to use for this graphics material. Used for sounds, effects etc.

Internal variables

bHasStaticPermutationResource

Type: bool

indicates whether the instance has static permutation resources (which are required when static parameters are present)

bStaticPermutationDirty

Type: bool

Modifiers: native, transient

indicates whether the static permutation resource needs to be updated on PostEditChange()

ReentrantFlag

Type: bool

Modifiers: private, const, native


ReferencedTextures

Type: array<Texture>

Modifiers: private, const

Array of textures referenced, updated in PostLoad. These are needed to keep the textures used by material resources from getting destroyed by realtime GC.

Resources

Type: pointer{class FMaterialInstanceResource}

Array size: 2

Modifiers: const, native, duplicatetransient


StaticParameters

Type: pointer{FStaticParameterSet}

Array size: 2

Modifiers: const, native, duplicatetransient

The set of static parameters that this instance will be compiled with, one for sm3 and one for sm2. This is indexed by EMaterialShaderPlatform.

StaticPermutationResources

Type: pointer{FMaterialResource}

Array size: 2

Modifiers: const, native, duplicatetransient

The material resources for this instance, one for sm3 and one for sm2. This is indexed by EMaterialShaderPlatform.

Native functions

ClearParameterValues

native function ClearParameterValues ()

Removes all parameter values

SetFontParameterValue

native function SetFontParameterValue (name ParameterName, Font FontValue, int FontPage)

Sets the value of the given font parameter.

Parameters:

  • ParameterName - The name of the font parameter
  • OutFontValue - New font value to set for this MIC
  • OutFontPage - New font page value to set for this MIC

SetParent

native function SetParent (MaterialInterface NewParent)


SetScalarCurveParameterValue

native function SetScalarCurveParameterValue (name ParameterName, Object.InterpCurveFloat Value)


SetScalarParameterValue

native function SetScalarParameterValue (name ParameterName, float Value)


SetTextureParameterValue

native function SetTextureParameterValue (name ParameterName, Texture Value)


SetVectorParameterValue

native function SetVectorParameterValue (name ParameterName, Object.LinearColor Value)