| 91 | } |
| 92 | |
| 93 | void Base::PerformRenderTest() |
| 94 | { |
| 95 | SetLights(); |
| 96 | |
| 97 | if (!instances.empty()) |
| 98 | world.setParam("instance", cpp::CopiedData(instances)); |
| 99 | |
| 100 | camera.commit(); |
| 101 | world.commit(); |
| 102 | renderer.commit(); |
| 103 | |
| 104 | framebuffer.resetAccumulation(); |
| 105 | |
| 106 | RenderFrame(); |
| 107 | |
| 108 | void *framebuffer_data = framebuffer.map(OSP_FB_COLOR); |
| 109 | |
| 110 | if (ospEnv->GetDumpImg()) { |
| 111 | EXPECT_EQ(imageTool->saveTestImage(framebuffer_data), OsprayStatus::Ok); |
| 112 | } else { |
| 113 | EXPECT_EQ( |
| 114 | imageTool->compareImgWithBaseline(framebuffer_data), OsprayStatus::Ok); |
| 115 | } |
| 116 | |
| 117 | framebuffer.unmap(framebuffer_data); |
| 118 | } |
| 119 | |
| 120 | void Base::CreateEmptyScene() |
| 121 | { |
nothing calls this directly
no test coverage detected