Merge branch 'master' of https://github.com/thomasbiang/assimp into gltf2_sparseAccessor_export
commit
71b16bf3df
|
@ -72,9 +72,12 @@ namespace o3dgc
|
||||||
unsigned char mask = bstream.ReadUChar(m_iterator, m_streamType);
|
unsigned char mask = bstream.ReadUChar(m_iterator, m_streamType);
|
||||||
|
|
||||||
ifs.SetCCW ((mask & 1) == 1);
|
ifs.SetCCW ((mask & 1) == 1);
|
||||||
ifs.SetSolid ((mask & 2) == 1);
|
// (mask & 2) == 1
|
||||||
ifs.SetConvex ((mask & 4) == 1);
|
ifs.SetSolid (false);
|
||||||
ifs.SetIsTriangularMesh((mask & 8) == 1);
|
// (mask & 4) == 1
|
||||||
|
ifs.SetConvex (false);
|
||||||
|
// (mask & 8) == 1
|
||||||
|
ifs.SetIsTriangularMesh(false);
|
||||||
//bool markerBit0 = (mask & 16 ) == 1;
|
//bool markerBit0 = (mask & 16 ) == 1;
|
||||||
//bool markerBit1 = (mask & 32 ) == 1;
|
//bool markerBit1 = (mask & 32 ) == 1;
|
||||||
//bool markerBit2 = (mask & 64 ) == 1;
|
//bool markerBit2 = (mask & 64 ) == 1;
|
||||||
|
|
|
@ -73,9 +73,21 @@ TEST_F(utMatrix3x3Test, FromToMatrixTest) {
|
||||||
|
|
||||||
aiVector3D from, to;
|
aiVector3D from, to;
|
||||||
|
|
||||||
|
auto random_ratio = []() -> float {
|
||||||
|
return static_cast<float>(rand()) / static_cast<float>(RAND_MAX);
|
||||||
|
};
|
||||||
|
|
||||||
for (int i = 0; i < NUM_SAMPLES; ++i) {
|
for (int i = 0; i < NUM_SAMPLES; ++i) {
|
||||||
from = aiVector3D(1.f * rand() / RAND_MAX, 1.f * rand() / RAND_MAX, 1.f * rand() / RAND_MAX).Normalize();
|
from = aiVector3D(
|
||||||
to = aiVector3D(1.f * rand() / RAND_MAX, 1.f * rand() / RAND_MAX, 1.f * rand() / RAND_MAX).Normalize();
|
1.f * random_ratio(),
|
||||||
|
1.f * random_ratio(),
|
||||||
|
1.f * random_ratio())
|
||||||
|
.Normalize();
|
||||||
|
to = aiVector3D(
|
||||||
|
1.f * random_ratio(),
|
||||||
|
1.f * random_ratio(),
|
||||||
|
1.f * random_ratio())
|
||||||
|
.Normalize();
|
||||||
|
|
||||||
aiMatrix3x3::FromToMatrix(from, to, trafo);
|
aiMatrix3x3::FromToMatrix(from, to, trafo);
|
||||||
res = trafo * from;
|
res = trafo * from;
|
||||||
|
|
Loading…
Reference in New Issue