0
\$\begingroup\$

Let's say I have a few voxel at (1,1,1) and (2,2,2), I would like to know if would be better to consider that the smallest box that contains both voxels is either (1,1,1) to (2,2,2) or (1,1,1) to (3,3,3). That is to say is it more correct to make the box contains the lower point of the voxels or the voxels as cubes inside the box?

\$\endgroup\$
2
  • \$\begingroup\$ Better in what sense/context? For a broad collision detection doing the smaller of the two would be incorrect, while it's better when looping through them \$\endgroup\$
    – Bálint
    Aug 7 '19 at 22:42
  • \$\begingroup\$ It's for looping through the inner voxels of that box. I agree for that second point, but the issue with the second approach in this case is that a box that is assimilable to a point (ie 0 width, height and depth) will still contain one voxel so there is no way to represent an empty box. But then looping on the points seems better \$\endgroup\$
    – Vinz243
    Aug 8 '19 at 10:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.