Editor.Assets.PassInfo
ClassThe Editor.Assets.Pass on a Editor.Assets.Material.
Index
Properties
Methods
Example
// Import built in helpers
import * as Utils from 'LensStudio:Utils@1.0.js';
// In the plugin create function
const model = pluginSystem.findInterface(Editor.Model.IModel);
const assetManager = model.project.assetManager;
const destination = destination;
const material = const assetManager.createNativeAsset('Material', 'Material Name', destination);
const absGraphPath = new Editor.Path(params.graph_path);
const pass = await Utils.findOrCreateAsync(assetManager, absGraphPath, destination);
const passInfo = material.addPass(pass);
Extends
Properties
blendMode
blendMode:
BlendMode
Blending mode for color output.
colorMask
colorMask:
vec4b
RGBA channel mask for color writes.
cullMode
cullMode:
CullMode
Face culling mode.
defines
defines:
string[]
Preprocessor defines applied to shaders.
depthFunction
depthFunction:
DepthFunction
Depth comparison function.
depthTest
depthTest:
boolean
Whether depth testing is enabled.
depthWrite
depthWrite:
boolean
Whether depth buffer writes are enabled.
frustumCulling
frustumCulling:
FrustumCullMode
Frustum culling mode.
id
readonlyid:Uuid
The unique id of the entity.
Inherited from
instanceCount
instanceCount:
number
Number of instances to render.
meta
readonlymeta:Meta
Metadata associated with this entity, providing access to its unique identifier and other descriptive properties.
Inherited from
polygonOffset
polygonOffset:
vec2
Whether polygon offset is enabled.
twoSided
twoSided:
boolean
Whether both front and back faces are rendered.
type
readonlytype:string
The entity's type.
Inherited from
uiData
readonlyuiData:PassUiData
UI metadata for this pass.
Methods
getDirectlyReferencedEntities()
getDirectlyReferencedEntities():
Entity[]
A list of entities which this entity has a reference to.
Returns
Entity[]
Inherited from
Entity.getDirectlyReferencedEntities
getMeta()
staticgetMeta():Meta
Returns metadata about this type.
Returns
Overrides
getOwnedEntities()
getOwnedEntities():
Entity[]
A list of entities which has a reference to this entity.
Returns
Entity[]
Inherited from
getPropertyNames()
getPropertyNames():
string[]
Get the list of property names for this pass.
Returns
string[]
getTypeName()
staticgetTypeName():string
Returns the type name of this class.
Returns
string
Overrides
getTypeName()
getTypeName():
string
Returns the name of this object's type.
Returns
string
Inherited from
isOfType()
isOfType(
type):boolean
Returns true if the object is of the specified type.
Parameters
| Parameter | Type |
|---|---|
type | string |
Returns
boolean
Inherited from
isSame()
isSame(
other):boolean
Returns true if this object refers to the same instance as the given object.
Parameters
| Parameter | Type |
|---|---|
other | ScriptObject |
Returns
boolean
Inherited from
setPassConfiguration()
setPassConfiguration(
config):void
Applies the given PassConfiguration to this pass, updating its Pass asset, blend mode, and shader defines in a single call.
Parameters
| Parameter | Type |
|---|---|
config | PassConfiguration |
Returns
void