Navigation
API > API/Runtime > API/Runtime/DatasmithCore
References
Module | DatasmithCore |
Header | /Engine/Source/Runtime/Datasmith/DatasmithCore/Public/DatasmithMaterialsUtils.h |
Include | #include "DatasmithMaterialsUtils.h" |
Source | /Engine/Source/Runtime/Datasmith/DatasmithCore/Private/DatasmithMaterialsUtils.cpp |
namespace DatasmithMaterialsUtils
{
IDatasmithMaterialExpression &42; DatasmithMaterialsUtils&58;&58;CreateWeightedMaterialExpression
&40;
const TSharedRef< IDatasmithUEPbrMaterialElement > & MaterialElement,
const TCHAR &42; ParameterName,
TOptional< FLinearColor > Color,
TOptional< float > Scalar,
IDatasmithMaterialExpression &42; Expression,
float Weight,
EDatasmithTextureMode TextureMode
&41;
}
Remarks
Generate material expressions on a given DatasmithUEPbrMaterialElement that output a color or scalar interpolated with a MaterialExpression Material expression that outputs a Color or Scalar interpolated with Expression; nullptr if no Color, Scalar or Expression are given
Parameters
Name | Description |
---|---|
MaterialElement | The UEPbrMaterialElement on which to create the material expressions |
ParameterName | The display name for the Color or Scalar input |
Color | The color to interpolate the Expression with. If no color is given, use the scalar |
Scalar | The scalar to interpolate the Expression with. If no color or scalar are given, use the Expression only |
Expression | The MaterialExpression to interpolate the Color or Scalar with |
Weight | The weight of the Expression in the interpolation |
TextureMode | The TextureMode of the Expression to determine if it requires normal flattening (bump and normal mode) or interpolation |