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 .binvox files being saved with the inverse scale #4710

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

sotpapathe
Copy link

Fixes: no related issue

About

According to the binvox specification the scale stored in binvox should be what the normalized voxel coordinates (in the interval [0, 1]) should be scaled by.

binvox now includes two extra lines in the header (which may be omitted, viewvox and thinvox don't need them):
translate <t_x> <t_y> <t_z>
scale <scale factor>
First scale (x_n, y_n, z_n) by the scale factor, then translate them by (t_x, t_y, t_z)

This is also how the scale is interpreted in this Python binvox implementation.

How Has This Been Tested?

Tested by using other implementations to read the resulting .binvox files.

According to the specification the scale stored in binvox should be what
the normalized voxel coordinates (in the interval [0, 1]) should be
scaled by.

https://www.patrickmin.com/binvox/binvox.html
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.

None yet

1 participant