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

minFilter 9986 vs 9987 - Moiré pattern on model viewer #239

Closed
lanxinger opened this issue Apr 26, 2020 · 4 comments · Fixed by #240
Closed

minFilter 9986 vs 9987 - Moiré pattern on model viewer #239

lanxinger opened this issue Apr 26, 2020 · 4 comments · Fixed by #240

Comments

@lanxinger
Copy link

Hi,

We have been a long time user and have been using google's model viewer implementation which relies on the threeJS library.

We recently found an issue with the model textures that they appear to show a moiré pattern (upon closer inspection) as has also been discussed on this model viewer issue:
google/model-viewer#936

I have then gone ahead and edited the glb files manually and changed the minFilter value to the proposed 9987 and the issue disappeared.

How can we create a .glb file that uses minFilter 9987 instead of 9986.

Has anyone run into this issue before?

@lilleyse
Copy link
Contributor

lilleyse commented May 2, 2020

@lanxinger I think NEAREST_MIPMAP_LINEAR (9986) is a good default given the runtime/quality trade-off. Though I'm not opposed to removing the defaults and letting the runtime engine decide. Would that work for model-viewer?

@lanxinger
Copy link
Author

@lilleyse thank you for your reply.

yes I think that would work. I checked the gltf export from blender and they are not using the minFilter at all and the exported file doesn’t cause moire issues. If people would still need it would it be a good option to have a flag that people can pass via CLI?

@lanxinger
Copy link
Author

@lilleyse according to one of the Google model viewer developers:

"Yes, removing the default would be ideal. Technically that's not letting
the engine decide, as the glTF spec specifies which default the engines
must use. However, they chose that default with input from the engines, as
we know anything other than LINEAR_MIPMAP_LINEAR results in significant
rendering artifacts. The performance difference from this is small since it
is handled in hardware anyway.

Thanks,"

google/model-viewer#936 (comment)

@lilleyse
Copy link
Contributor

@lanxinger opened a PR here: #240

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 a pull request may close this issue.

2 participants