Fix K-bits range for meshopt octahedral filter#2463
Fix K-bits range for meshopt octahedral filter#2463lexaknyazev merged 2 commits intoKhronosGroup:mainfrom
Conversation
|
While 1 is the smallest possible K from the encoding perspective, unsure if the spec should state that as the bounds - a 1-bit signed normalized integer has two values, -1 and 0, so that's not super useful for normal encoding :) My recollection for why the spec stated K=4 is the minimum was that I felt that this is the lowest value assets could be reasonably encoded in (at a great quality loss!), but maybe this is too conservative. When normals are used for specular reflections, Suzanne from glTF-Sample-Assets looks broken on K=3: ... but BrainStem model is perhaps okay for some contexts with K=3: ... or K=2 A 2-bit signed normalized integer can represent values -1, 0, 1 in [-1, 1] range. So if we want to update the spec then minimum K should probably start with 2; K=1 is not useful. |
|
@lilleyse What's the use case here, is it 3D Tiles with unlit and hence no normals are being used? What's the next step here? |
|
It's a request to align the extension spec with the implementation. I think the next step is to update the PR to use 2 as the lower bound. |
|
FWIW I've updated this for the new extension proposal (#2517). |
|
@lilleyse Could you please change 1 to 2 as discussed above so this PR could be merged? |
|
@lexaknyazev done |




Looking at
meshopt_encodeFilterOctas a reference, the bit range should be1 <= K <= 16, not4 <= K <= 16.@zeux does this change look correct?