-
|
Problem Description Current Behavior
Investigation bool equal(unsigned int lhs, unsigned int rhs) const
{
for (size_t i = 0; i < stream_count; ++i)
{
const meshopt_Stream& s = streams[i];
const unsigned char* data = static_cast<const unsigned char*>(s.data);
if (memcmp(data + lhs * s.stride, data + rhs * s.stride, s.size) != 0)
return false;
}
return true;
}Questions What's the rationale behind the 16-stream limitation? Except the following vertex fetch optimize operation, are there more issue of increasing/removing this limit? *** Use Case *** |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
When using morph targets, the flow that's typically expected is:
While you could include the morph target streams into the remap, this should not be necessary. gltfpack follows the procedure described above; in addition to avoiding the stream count limit, this is also much more efficient. As for why the limit exists in the first place: the current implementation does not depend on the limit; however, in general in other places I found it useful to place an upper bound on input parameters so that future implementation changes would be able to use small stack arrays. This doesn't really matter here. Some other range checks that exist in the assertions are there to avoid accidental parameter order mismatch; again doesn't really matter here as due to the placement of |
Beta Was this translation helpful? Give feedback.
When using morph targets, the flow that's typically expected is:
meshopt_generateVertexRemapMultiusing the "base" mesh streams (excluding morph targets)meshopt_remapVertexBufferto obtain final orderWhile you could include the morph target streams into the remap, this should not be necessary. gltfpack follows the procedure described above; in addition to avoiding the stream count limit, this is also much more efficient.
As for why the limit exists in the first place: the current implementation does not depend on the limit; however, in general in other places I found it useful to p…