StaticcreateCreates a complete fragment/pixel shader code from the given pixel nodes. This method performs topological sorting, generates function definitions, and constructs the main shader body for fragment processing.
The engine instance
Array of shader nodes that contribute to fragment processing
The CommonShaderPart instance for shader code generation
Complete fragment shader code as a string, or undefined if generation fails
StaticcreateCreates a complete vertex shader code from the given vertex and varying nodes. This method performs topological sorting of nodes, generates function definitions, and constructs the main shader body with proper variable declarations and connections.
The engine instance
Array of shader nodes that contribute to vertex processing
Array of shader nodes that pass data from vertex to fragment stage
The CommonShaderPart instance for shader code generation
Complete vertex shader code as a string, or undefined if generation fails
StaticgenerateGenerates complete vertex and fragment shader code from a JSON shader node graph definition. This is the main entry point for converting a serialized shader graph into executable shader code. The method performs the full pipeline: node construction, dependency resolution, stage assignment, and final code generation.
The engine instance
JSON representation of the shader node graph containing nodes and connections
StandardShaderPart instance to use for shader code generation
Object containing both vertex and fragment shader code, texture names used, or undefined if generation fails
ShaderGraphResolver is a class that resolves the shader node graph and generates shader code. It provides functionality to convert a graph of shader nodes into complete vertex and fragment shaders.