Browse Source

DebugTools: wow MSVC thanks for existing.

pull/432/merge
Vladimír Vondruš 6 years ago
parent
commit
2c43e817db
  1. 4
      src/Magnum/DebugTools/Test/FrameProfilerGLTest.cpp
  2. 4
      src/Magnum/DebugTools/Test/FrameProfilerTest.cpp

4
src/Magnum/DebugTools/Test/FrameProfilerGLTest.cpp

@ -115,15 +115,17 @@ void FrameProfilerGLTest::test() {
GLFrameProfiler profiler{data.values, 4};
CORRADE_COMPARE(profiler.maxFrameCount(), 4);
/* MSVC 2015 needs the {} */
for(auto value: {GLFrameProfiler::Value::CpuDuration,
GLFrameProfiler::Value::GpuDuration,
#ifndef MAGNUM_TARGET_GLES
GLFrameProfiler::Value::VertexFetchRatio,
GLFrameProfiler::Value::PrimitiveClipRatio
#endif
})
}) {
if(data.values & value)
CORRADE_VERIFY(!profiler.isMeasurementAvailable(value));
}
profiler.beginFrame();
shader.draw(mesh);

4
src/Magnum/DebugTools/Test/FrameProfilerTest.cpp

@ -961,10 +961,12 @@ void FrameProfilerTest::gl() {
CORRADE_COMPARE(profiler.maxFrameCount(), 4);
CORRADE_COMPARE(profiler.measurementCount(), data.measurementCount);
/* MSVC 2015 needs the {} */
for(auto value: {GLFrameProfiler::Value::CpuDuration,
GLFrameProfiler::Value::FrameTime})
GLFrameProfiler::Value::FrameTime}) {
if(data.values & value)
CORRADE_VERIFY(!profiler.isMeasurementAvailable(value));
}
profiler.beginFrame();
Utility::System::sleep(1);

Loading…
Cancel
Save