Tweaks to cubic surface tests.
This commit is contained in:
parent
c0added385
commit
e2051ed713
@ -121,18 +121,18 @@ void TestCubicSurfaceExtractor::testBehaviour()
|
|||||||
|
|
||||||
void TestCubicSurfaceExtractor::testEmptyVolumePerformance()
|
void TestCubicSurfaceExtractor::testEmptyVolumePerformance()
|
||||||
{
|
{
|
||||||
auto emptyVol = createAndFillVolumeWithNoise< RawVolume<uint32_t> >(32, 0, 0);
|
auto emptyVol = createAndFillVolumeWithNoise< SimpleVolume<uint32_t> >(128, 0, 0);
|
||||||
CubicMesh< uint32_t, uint16_t > emptyMesh;
|
CubicMesh< uint32_t, uint16_t > emptyMesh;
|
||||||
QBENCHMARK{ extractCubicMeshCustom(emptyVol, emptyVol->getEnclosingRegion(), &emptyMesh); }
|
QBENCHMARK{ extractCubicMeshCustom(emptyVol, Region(32, 32, 32, 63, 63, 63), &emptyMesh); }
|
||||||
QCOMPARE(emptyMesh.getNoOfVertices(), uint16_t(0));
|
QCOMPARE(emptyMesh.getNoOfVertices(), uint16_t(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
void TestCubicSurfaceExtractor::testNoiseVolumePerformance()
|
void TestCubicSurfaceExtractor::testNoiseVolumePerformance()
|
||||||
{
|
{
|
||||||
auto noiseVol = createAndFillVolumeWithNoise< RawVolume<uint32_t> >(32, 0, 1);
|
auto noiseVol = createAndFillVolumeWithNoise< SimpleVolume<uint32_t> >(128, 0, 2);
|
||||||
CubicMesh< uint32_t, uint16_t > noiseMesh;
|
CubicMesh< uint32_t, uint16_t > noiseMesh;
|
||||||
QBENCHMARK{ extractCubicMeshCustom(noiseVol, noiseVol->getEnclosingRegion(), &noiseMesh); }
|
QBENCHMARK{ extractCubicMeshCustom(noiseVol, Region(32, 32, 32, 63, 63, 63), &noiseMesh); }
|
||||||
QCOMPARE(noiseMesh.getNoOfVertices(), uint16_t(28429));
|
QCOMPARE(noiseMesh.getNoOfVertices(), uint16_t(57729));
|
||||||
}
|
}
|
||||||
|
|
||||||
QTEST_MAIN(TestCubicSurfaceExtractor)
|
QTEST_MAIN(TestCubicSurfaceExtractor)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user