A text-first material language for replacing Unreal Engine material spaghetti graphs.
DreamShaderLang is the source language used by the DreamShader Unreal plugin.
It describes Unreal materials, material functions, Material Layers, shared helpers,
package dependencies, and graph connections with .dsm, .dsf, and .dsh files.
The plugin then generates regular UMaterial, UMaterialFunction,
UMaterialFunctionMaterialLayer, and UMaterialFunctionMaterialLayerBlend assets.
This documentation is organized around the language, so DreamShaderLang can be learned,
searched, and referenced like a normal programming language.
DreamShader plugin 1.4.0 is developed against UE 5.7 and verified with single-plugin RunUAT BuildPlugin builds on UE 5.3 through 5.7.
Substrate generation
The plugin supports UE 5.7 Substrate graph values, Base.FrontMaterial output binding, Substrate.* wrappers, and editor-exported Substrate builtin metadata.
Material preview
VSCode extension 1.5.3 adds a .dsm material preview panel with local WebSocket streaming and Saved/DreamShader/Bridge/preview.json file-bridge fallback.
Callable hover metadata
VSCode extension 1.5.2 shows return and output-pin details for DreamShader callables, UE builtins, and Substrate helpers.
Template / Bridge / Package tools
VSCode extension 1.5.1 adds Template-block language support, bridge commands, status bar integration, diagnostics panel wiring, package tooling, and authoring templates.
.dsf function files
Dream Shader Function files generate reusable ShaderFunction assets and support import between .dsm / .dsf files.
Decompile export
Existing Material and Material Function assets can be exported as initial .dsm / .dsf sources.
Plugin and editor extension support VolumeTexture / Texture3D, default textures, completion, and diagnostics.
Function builtins
The VSCode extension unifies HLSL intrinsics, GLSL aliases, and Unreal sampling helpers for completion, hover, signature help, inlay hints, diagnostics, and semantic highlighting.
Dynamic MaterialExpression metadata
The plugin exports Saved/DreamShader/Bridge/material-expressions.json; VSCode reads reflected UMaterialExpression metadata with a built-in fallback manifest.
Material Layer
ShaderLayer and ShaderLayerBlend generate native Unreal Material Layer / Layer Blend function assets.
GraphFunction
GraphFunction helpers can use UE.* calls inside Custom-node bodies.
Helper value expressions
Single-output Function / GraphFunction calls can be used as Graph value expressions.
Material Function stability
Regeneration preserves input/output IDs for ShaderFunction assets to reduce broken Unreal MaterialFunctionCall links.