Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wgsl PBR fixes #12

Merged
merged 3 commits into from
Jun 29, 2021
Merged

wgsl PBR fixes #12

merged 3 commits into from
Jun 29, 2021

Conversation

superdump
Copy link

No description provided.

Putting the largest things first got rid of a ton of seemingly unnecessary padding
that was being ignored when the data was written (i.e. data we wanted was being
written into the padding???)
The world_position is just model * vertex position.
view_proj * world_position is the clip space position.
@cart
Copy link
Owner

cart commented Jun 29, 2021

Made a few small tweaks:

  • Removed unused clip_position from fragment input
  • Added a note about the omni_lights field position
  • Removed the reordering of OmniLight fields: this isn't needed and id actually prefer to keep "weird alignment positions" there to ensure userspace doesn't need to rely on field placement.

@cart cart merged commit 03cf087 into cart:pipelined-rendering Jun 29, 2021
cart pushed a commit that referenced this pull request Jul 24, 2021
bevy_pbr2: Fix light uniforms
cart pushed a commit that referenced this pull request Jul 24, 2021
bevy_pbr2: Fix light uniforms
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants