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

Add test of animated base color #140

Merged
merged 3 commits into from
Oct 23, 2024
Merged

Add test of animated base color #140

merged 3 commits into from
Oct 23, 2024

Conversation

emackey
Copy link
Member

@emackey emackey commented Aug 1, 2024

This model tests the KHR_animation_pointer extension's effect on the baseColorFactor of a material. When animated, the top cube should rotate above other colored cubes, and change its own color to match the cubes below.

screenshot

@emackey
Copy link
Member Author

emackey commented Oct 22, 2024

@lexaknyazev is there someone from Interactivity who would be willing to review this?

It's intentionally simpler than other animation pointer samples. I suppose it's intended to be the "hello world" of animation pointer, just change the base color and see if anything works. I believe this is useful to first-time implementers, but I'm curious what others think about it.

Copy link

@bghgary bghgary left a comment

Choose a reason for hiding this comment

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

Small comment. Otherwise, LGTM. I also tested in Babylon.js.

Models/AnimatedColorsCube/glTF/AnimatedColorsCube.gltf Outdated Show resolved Hide resolved
@emackey
Copy link
Member Author

emackey commented Oct 22, 2024

Pulled out from a now-resolved comment:

It seems odd to default to something that is likely to run worse.

This is off-topic here, but it's worth understanding. Blender chooses its default materials based on what's best for its own purposes, which may not place real-time interactive rendering as the top priority. The glTF exporter can't tell if the user intentionally chose to have backface culling turned off, or if the user just didn't bother to visit the correct property panel where the choice is offered.

In any case, I believe it's correct for the Khronos exporter to honor the setting in Blender, regardless if it was intentional, and without any guessing as to whether it was altered by the user. This way, the exported result is a closer match to what's in the Blender preview window.

For these sample assets though, I agree we should be more careful to intentionally choose the better option for glTF.

@emackey emackey merged commit d86791b into main Oct 23, 2024
3 checks passed
@emackey emackey deleted the animated-colors branch October 23, 2024 00:25
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.

3 participants