Transparent materials render during skybox pass instead of deferred #42
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Transparent materials (e.g.
models/effects/vol_light001, Refract materials with$refracttinttexture) render during the skybox render pass and show only the skybox behind them. They should be deferred to a final transparent object render pass after all opaque world geometry has been drawn, so they composite correctly over the scene.Current behavior
The multi-pass rendering order is:
Transparent materials on entities and BSP surfaces render during pass 4 but don't see geometry behind them correctly — they appear to only show the skybox.
Expected behavior
Transparent objects should be sorted back-to-front and rendered after all opaque geometry, so they blend over the correct background.
Related
Fixed in
a27c9ef. Transparent materials now render on layer 2 in a separate pass after all opaque geometry:material.transparentis true (after VMT resolution)camera.layers.set(2)after the opaque world passThis ensures transparent surfaces composite against the full scene depth buffer instead of just the skybox.