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

[Rendering] Add hints to some uniform PropertyInfos #89488

Merged
merged 1 commit into from
May 3, 2024

Conversation

AThousandShips
Copy link
Member

  • Enforce range on int/uint
  • Use flags for bvec2/3/4 arrays

Left some TODO notes for possible future improvements, unsure what can be one with them but good to add if we end up improving other contexts

Full change can't be cherry picked as it depends on arrays having hints, but can cherry pick specifically the int/uint case if desired


@AThousandShips AThousandShips added this to the 4.3 milestone Mar 14, 2024
@AThousandShips AThousandShips marked this pull request as ready for review March 14, 2024 18:18
@AThousandShips AThousandShips requested a review from a team as a code owner March 14, 2024 18:18
@AThousandShips
Copy link
Member Author

AThousandShips commented Mar 15, 2024

I'll be experimenting with some improvements to property handling perhaps this weekend, would start with experimenting with remapping unsinged integers to be edited correctly, that should be relatively straight forward to do, adding it as a hint string

Might also look at adding special constants to the range to help with things, like (U)INT8/16/32/64_MIN/MAX to the range handling

Got the former working quite well, will open a PR relatively soon

Copy link
Member

@clayjohn clayjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like a nice improvement!

@akien-mga
Copy link
Member

Should be squashable before merge.

* Enforce range on `int/uint`
* Use flags for `bvec2/3/4` arrays
@akien-mga akien-mga merged commit fa3ad27 into godotengine:master May 3, 2024
16 checks passed
@akien-mga
Copy link
Member

Thanks!

@AThousandShips AThousandShips deleted the shader_hint_fix branch May 3, 2024 08:33
@AThousandShips
Copy link
Member Author

Thank you!

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.

shader uniform uint allows negative numbers in inspector panel
4 participants