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

Color wise Component swizzle and function on vector types #183

Open
lieene opened this issue Dec 2, 2020 · 1 comment
Open

Color wise Component swizzle and function on vector types #183

lieene opened this issue Dec 2, 2020 · 1 comment

Comments

@lieene
Copy link

lieene commented Dec 2, 2020

For shader language compatibility and ease of use.
float4.rgba alike swizzle is expected.
And color-wise functions are expected too.
For example:
HsvToRgb()
RgbToHsv()
GammarToLinear()
LinearToGammar()

@unpacklo
Copy link
Collaborator

unpacklo commented Dec 2, 2020

Yes, we've already been working on this internally to see if it can be done!

The main issues blocking us right now are that it actually requires Burst changes to support it and making sure that Mathematics compile time is not significantly affected. Because the swizzle permutation count is so large, we suspect that it's a significant contributor to long compile times and we don't want to make it longer.

We'll update this issue in the future when we have made a determination about whether or not this feature will be completed.

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

No branches or pull requests

2 participants