X Tutup
Skip to content

Reorganize canvas shader varyings in RD renderer#112800

Merged
Repiteo merged 1 commit intogodotengine:masterfrom
clayjohn:canvas-rd-varying
Nov 17, 2025
Merged

Reorganize canvas shader varyings in RD renderer#112800
Repiteo merged 1 commit intogodotengine:masterfrom
clayjohn:canvas-rd-varying

Conversation

@clayjohn
Copy link
Member

Fixes: #112799

Regression from #112481

The simple fix was to increase the value of actions.base_varying_index to 1 + whatever the highest varying index is in the shader. However, in doing so, I set it to 10, which struck me as way too high. We should not be using up ten varying slots in our internal shader. Some hardware is limited to 16 total, so us reserving 10 for our own use is a bit extreme.

I took a look at our current varying usage and was able to clean it up a bit and free up two extra slots. With more extreme optimizations, we could potentially free up 1-2 more as well. But I figured this was enough for now.

In addition to freeing up more varying slots for our users, this PR also may improve performance on some Adreno devices

@Repiteo Repiteo merged commit e81f1df into godotengine:master Nov 17, 2025
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Nov 17, 2025

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GDShader error when using varyings

3 participants

X Tutup