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

Draco compression extension #2

Open
wants to merge 15 commits into
base: 2.0
Choose a base branch
from

Conversation

fanzhanggoogle
Copy link
Owner

@fanzhanggoogle fanzhanggoogle commented Sep 27, 2017

This work compresses a glTF 2.0 asset according to the KHR_draco_mesh_compression extension. Currently it's only tested against mesh compression only. Working along with other optimization methods is temporarily disabled.

Please follow the gltf-pipeline guideline to install the repo and use the following command to compress your glTF 2.0 assets.

Example:
node ./bin/gltf-pipeline.js -i ./specs/data/Duck/glTF/Duck.gltf -d --draco.quantizePosition=10 --draco.quantizeNormal=8 --draco.quantizeTexcoord=8 --draco.quantizeColor=6 --draco.quantize Skin=12 -s -o Duck.gltf

@zynga-jpetersen
Copy link

I actually end up getting this working with my model and being able to load the model in three.js with donmccurdy's work in https://github.com/donmccurdy/three.js/blob/feat-gltf-draco-extension-v4/examples/js/loaders/GLTFLoader.js .

It turned out that I had some bad meshes in my scene with 0 verts which three dealt with fine but were definitely incorrect. Fixing the exporter to strip those (and subsequently fixing the model), corrected the issues.

Thanks!

@fanzhanggoogle
Copy link
Owner Author

@zynga-jpetersen Awesome! Thanks for letting me know.

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