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

Shaders don't mark any exposed properties as "Main Color" #714

Open
andybak opened this issue Mar 17, 2024 · 2 comments
Open

Shaders don't mark any exposed properties as "Main Color" #714

andybak opened this issue Mar 17, 2024 · 2 comments

Comments

@andybak
Copy link

andybak commented Mar 17, 2024

image

This breaks any code that uses "someMaterial.color" without checking and forces implementation of code paths specifically for UnityGLTF materials.

@hybridherbst
Copy link
Collaborator

Thanks — the ShaderGraphs in UnityGltf were compatible back to 2019.x where that didn’t exist, but now that we support 2021.x+ it’s a good idea to add that.

Worth noting that

breaks any code that uses "someMaterial.color" without checking

is a bit of a misnomer, code that doesn’t check it is already broken, not every shader even has a main color.

@hybridherbst
Copy link
Collaborator

@pfcDorn we should also add to the docs that shader properties in UnityGltf always match their glTF spec names for ease of use

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