public static class UiShaderLibraryThe eight modules UiRenderer draws with, embedded and compiled on demand.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
The whole set, because half of it is optional in the way that hurts. UiShaders takes four stages positionally and four as init properties, and the four optional ones are documented — correctly — as degrading to a picture rather than to a failure. That is exactly what makes forgetting them expensive: an application with no Image stage has UiRenderer.Compose return having done nothing, so every faded subtree draws at full strength and a disabled button comes out opaque. One with no Colour stage has filter: grayscale(1) cascade, resolve, and do nothing.
⚠ Samples/02-HelloUi wired four of the eight for months and had both bugs. Nothing failed, nothing logged, and the sample's own theme puts an opacity on every disabled control — so the demonstration of the control set was quietly demonstrating the wrong picture. A host that has to name eight modules is a host where somebody names four.
⚠ These are Raven's, compiled from Shaders/Ui.rvn by this repository's own compiler. They were hand-written GLSL until 2026-08-23, committed three times and compiled by whatever glslc was on the machine of whoever last touched them — which is what SharedUiShaderTests existed to police, after two of the three copies had already lost the whole shadow path.
⚠ So the vertex attribute locations are not 0 to 3, and that is the one thing a host cannot guess. Raven's StreamPlan puts a stage's own parameters after the shader's streams, so Ui.rvn's three streams push the four vertex attributes to 3 through 6 — and adding a stream moves them again. They are read out of the compiler's own reflection below rather than written down, because a wrong location is not a validation error: the pipeline binds nothing to that attribute and the stage reads whatever the driver left there, which is an interface drawn from uninitialised memory, on one driver, silently.
Methods (1)
public static UiShaders Load(IGraphicsDevice device)Compiles every stage against a device.
Used by (7)
- ShaderReflectionTestsVixen.Ui.Desktop.Tests
- UiApplicationVixen.Ui.Desktop
- UiRavenAgreementTestsVixen.Graphics.Golden.Tests
- EditorHostVixen.Editor.Host
- EditorUiCompositingDeviceTestsVixen.Editor.App.Tests
- ShadersVixen.Editor.App.Tests
- ThumbnailSurfaceDeviceTestsVixen.Editor.App.Tests