Commit 06d12e7a authored by David Flynn's avatar David Flynn
Browse files

geom/m46512: fix incorrect calculation of num_leaf_points_minus2

A leaf node by definition contains at least one point.  Therefore the
single point flag indicates if there are one or two points in the leaf.
The remainder should be signalled as numpoints - 2 as per the working
draft text.
parent fcfcc871
......@@ -134,8 +134,9 @@ GeometryOctreeDecoder::decodePositionLeafNumPoints()
int count = 1;
if (!isSinglePoint) {
count += _arithmeticDecoder->decodeExpGolomb(
0, _ctxEquiProb, _ctxPointCountPerBlock);
count += 1
+ _arithmeticDecoder->decodeExpGolomb(
0, _ctxEquiProb, _ctxPointCountPerBlock);
return count;
......@@ -146,7 +146,7 @@ GeometryOctreeEncoder::encodePositionLeafNumPoints(int count)
} else {
_arithmeticEncoder->encode(0, _ctxSinglePointPerBlock);
uint32_t(count - 1), 0, _ctxEquiProb, _ctxPointCountPerBlock);
uint32_t(count - 2), 0, _ctxEquiProb, _ctxPointCountPerBlock);
return count;
  • Look at this very nice blog here it is the amazing way for all of you can got file explorer windows this is the way for easily save to all file and data here to connecting the feature easily here so thanks for the update.

Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment