-
-
Notifications
You must be signed in to change notification settings - Fork 149
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
Support resizing textures to nearest powers of two #1213
Comments
Hi @Yason83 – Thanks for your comments, and for the request! I think this is a good idea. There's a similar feature built into the Perhaps the current "resize" option could be extended with interface TextureCompressOptions {
...
resize?: vec2,
resizePowerOfTwo?: 'nearest' | 'ceil' | 'floor',
}
Do square textures avoid the issue? It looked to me like the texture in that issue was already square. |
Please forgive me, not absolving, this is my mistake. |
All good! Maybe we'd stick to |
Yes its will be perfect!!! |
Work in progress: |
Merged! I'm currently working toward the v4.0 release and not planning to make a v3.11 release, so it may be a little while before this is generally available. If you'd like to try it out in the meantime, you can install from the npm install --global @gltf-transform/cli@next |
Thank you, the tool works quite well. However, I have noticed a few issues that might need attention. Additionally, I observed an interesting behavior. With the command I am attaching the file for your reference. input.zip |
Yes, they're intended to be mutually exclusive and
Hm that's certainly not intended! I see the same issue here, and will take a look. Note that the intention for |
Dear glTF-Transform Team,
I hope this message finds you well. First and foremost, I would like to extend my gratitude for your continuous efforts in improving the glTF-Transform tool. Your work significantly contributes to the 3D modeling and rendering community.
I am writing to request an enhancement for the resize module. Specifically, I am interested in a feature that checks and corrects textures with non-power-of-two dimensions. The desired functionality would include parameters to resize the texture either upwards, downwards, or to the nearest power-of-two dimension.
For instance, if a texture is sized at 1000x100, the resize operation could be as follows:
Downward to 512x512
Upward to 1024x1024
Nearest to 1024x1024
Additionally, it would be highly beneficial to have an option to make textures square, aiding in overcoming issues like the one discussed in Issue #1007.
Implementing these features would greatly enhance the usability of glTF-Transform for many users who deal with a variety of texture dimensions, especially in complex 3D models.
Thank you for considering this request. I am looking forward to any possibilities of seeing this enhancement in a future update.
The text was updated successfully, but these errors were encountered: