bevy icon indicating copy to clipboard operation
bevy copied to clipboard

Sync up bevy_sprite and bevy_ui shader View struct

Open superdump opened this issue 1 year ago • 3 comments

Objective

  • Similar to #5512 , the View struct definition in the shaders in bevy_sprite and bevy_ui were out of sync with the rust-side ViewUniform. Only view_proj was being used and is the first member and as those shaders are not customisable it makes little difference in practice, unlike for Mesh2d.

Solution

  • Sync shader View struct definition in bevy_sprite and bevy_ui with the correct definition that matches ViewUniform

superdump avatar Aug 01 '22 16:08 superdump

Longer-term, I think we should define a shader import for this in bevy_render and use it everywhere. But doing this for now as a minimal fix in case it were to be pulled into a 0.8.1. I don't think this one would be necessary but perhaps @cart would rather bundle the update.

superdump avatar Aug 01 '22 16:08 superdump

couldn't they be imports?

mockersf avatar Aug 01 '22 16:08 mockersf

couldn't they be imports?

See above. :D

superdump avatar Aug 01 '22 16:08 superdump

Yeah I think it makes sense to do this one first for 0.8.1

cart avatar Aug 05 '22 02:08 cart

bors r+

cart avatar Aug 05 '22 02:08 cart