Is BC4 good for distance field compression? Analysis follows...
Conversation
We switched from BC4 to U8 to be able to render bricks directly. Need the precision for normals but also to keep shared texels identical for neighbouring bricks (we store 8^3 voxel corners to render 7^3 volume).
2
6
Yep texels are duplicated on all shared faces. Not sure what you mean about mip maps, bricks form an octree for level of detail, each octree node is 7 texels long, octree node corners line up with texel centres at all levels (so need 8^3 storage for each).
1
2
In 2D, layout is like this (black: octree node bounds, blue: current node texels, red: top-left child node texels)
Oh yes... if the leaf node represents a 7x7x7 region, then the parent of course represents 14x14x14 region (at half res) and the grandparent represents 28x28x28 region (at quarter res). Thus all nodes are 7x7x7 at 1 voxel border. This is better for GPU cache lines than 8x8x8+1.
1
1
For some reason I was thinking it backwards. The node size doesn't matter. You can always multiply it by a pow2 and add +1 border.
1
with this layout, you’ll have to lookup and sample octree neighbors in order to do central difference without seams. or do I miss something?
1
Yeah smooth normals need neighbour lookups. Can get a faceted normal without though, which is sometimes useful.
1
Show replies


