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

Fix: Texture offset/tiling values getting lost when switching to other shaders #140

Conversation

hybridherbst
Copy link
Contributor

This is already an improvement, but there are some open questions:

  • not sure if the call to SetVector("_MainTex_ST" is still needed now
  • for the ShaderGraphMaterialGenerator, the right texture to set these on would be _BaseMap_ST
    • I saw TrySetTextureTransform actually takes a propertyId but then ignores it, so that could be directly used; I think the reason it isn't right now is that it's not trivial to also set Rotation?

@atteneder
Copy link
Owner

Thank you very much for this contribution!

As far as I remember, the _MainTex_ST is used for all textures throughout.

Clearly this limitation should be re-evaluated, but it works for most models and keeps the shaders simple (and doesn't add shader variants).

@atteneder atteneder merged commit 4815a66 into atteneder:main Feb 19, 2021
atteneder added a commit that referenced this pull request May 27, 2024
…aternion`. (#140)

* doc: Fixed duplicate headline.
* feat: `float4x4.Decompose` overload that outputs rotation as type `quaternion`.
* Deprecated `float4x4.Decompose` overload that outputs rotation as type `float4` (quaternion values).
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