BBMOD_Shader

A constructor defined in BBMOD_Shader.gml

new BBMOD_Shader([_shader[, _vertexFormat]])

Description

Base class for wrappers of raw GameMaker shader assets.

Arguments

Name Type Description
_shader Asset.GMShader The raw GameMaker shader asset.
_vertexFormat Struct.BBMOD_VertexFormat The vertex format required by the shader.

Methods

Name Description
add_variant Adds a shader variant to be used with a specific vertex format.
get_variant Retrieves a shader variant for given vertex format.
has_variant Checks whether the shader has a variant for given vertex format.
is_compiled Checks whether all shader variants are compiled.
is_current Checks if the shader is currently in use.
on_reset A function executed when the shader is reset.
on_set A function executed when the shader is set.
reset Unsets the shaders.
set Sets the shader as the current shader.
set_material Sets shader uniforms using values from the material.

Note

You can use method BBMOD_Shader.add_variant to add different variants of the shader to be used with different vertex formats.

Child structs

BBMOD_BaseShader

Do you find this page helpful?

Copyright © 2024, BlueBurn. Built on January 21, 2024 using GMDoc.