Can you help me understand why there is a discrepancy in SPAN_HEIGHT_BITS and SPAN_MAX_HEIGHT values between recastnavigation
and recast4j
?
#173
-
Hello, I am currently comparing the original source code of recastnavigation with the relevant section in recast4j to understand the differences.
The values for SPAN_HEIGHT_BITS and SPAN_MAX_HEIGHT are set differently between these two code snippets. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
rcSpan struct is defined as follows in recastnavigation:
Which means These values are expended to full 32-bit integers in recast4j as follows:
Hence the limits are increased, potentially they could be increased to 31 bits instead of 20 if really needed. |
Beta Was this translation helpful? Give feedback.
-
thank you |
Beta Was this translation helpful? Give feedback.
rcSpan struct is defined as follows in recastnavigation:
Which means
smin
occupies 13 bits,smax
another 13 bits andarea
the remaining 6 bits of the 32-bit word.These values are expended to full 32-bit integers in recast4j as follows:
Hence the limits are increased, potentially they could be increased to 31 bits instead of 20 if really needed.