World consist from voxels.
Voxels groupped to blocks.
So one thing I still cannot understand:
Why do we need to iterate through blocks voxels here:
for (int z = 0; z < VoxelFarm::BLOCK_SIZE; z++)

Is CellId don't contain each voxel data info we need to fill?
Kind regards
Denis B.
0 0
The world is composed of multiple Voxel Layers.

Each Voxel Layer (IVoxelLayer) will be asked to provide voxel data. This is what the getContourData() method does. In this method, the layer is expected to produce the voxels for the cell ID provided as a parameter. A single cell will have BLOCK_SIZE^3 voxels in it. For this reason, most getContourData() implementations will iterate over z,y,x setting values to the voxels in the cell.

The following topics in our help portal discuss scenes, how they are broken into cells, and how each voxel layer is asked to produce voxel data:
0 0
Understood, cell contain blocks.
So octree works with cells (not voxels)?
Is block and cell is the same term?

One more question:
I try to do simple scene with single Cell [smile]
But after several tries, I cannot get worked scene.
I had test getContourData, and input cells level start from 3.
What value I must to set for each lod level for correct one cell output?

And one more question:
This code a little confuse me:
double dx = (double)(x - VoxelFarm::BLOCK_MARGIN) / (double)(VoxelFarm::BLOCK_DIMENSION);

For x = 0:
dx = 0 - 2 / 40 = -0.05

For x = 44:
dx = (44-2)/40 = 1.05

So what this dx mean? Relative voxel position in relative to cell with margin?

Denis B.
0 0
The world is broken down into cells, each cell is 40x40x40 voxels plus 2 margin voxels in each side. For this reason the voxel buffer you are expected to fill in a getContourData() call is 44x44x44 (BLOCK_SIZE == 44). A block is a cell, these two terms refer to the same thing.

Not sure what you meant by "do simple scene with single Cell". Normally a single scene will involve many cells. You can send your code to support at and we will take a look at it.
0 0