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

CPU Voxelizer reports all voxel positions as (0.0, 0.0, 0.0) #12

Open
absolutelynothinghere opened this issue Jun 17, 2021 · 0 comments

Comments

@absolutelynothinghere
Copy link

Hello, I'm trying to do CPU voxelization of a mesh and get the positions of the resulting voxels, but they're all reported as (0.0, 0.0, 0.0).
Here is my code:

// voxelize a mesh
List<Voxel_t> voxels;
float unit;
CPUVoxelizer.Voxelize(
    mesh,
    resolution,
    out voxels,
    out unit
);

// print each voxel's position
for (int v = 0; v < voxels.Count; v++) {
    Debug.Log(voxels[v].position.ToString());
}

Thank you very much for this tool.

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

No branches or pull requests

1 participant