MCPcopy Create free account
hub / github.com/Kitware/VTK / PostDraw

Function PostDraw

Rendering/ContextOpenGL2/vtkOpenGLContextDevice2D.cxx:183–196  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Call after glDraw* commands to ensure that vertices are properly captured for GL2PS export.

Source from the content-addressed store, hash-verified

181// Call after glDraw* commands to ensure that vertices are properly captured
182// for GL2PS export.
183void PostDraw(vtkOpenGLHelper& helper, vtkRenderer* ren, unsigned char col[4])
184{
185 vtkOpenGLGL2PSHelper* gl2ps = vtkOpenGLGL2PSHelper::GetInstance();
186 if (gl2ps && gl2ps->GetActiveState() == vtkOpenGLGL2PSHelper::Capture && helper.Program)
187 {
188 if (vtkTransformFeedback* tfc = helper.Program->GetTransformFeedback())
189 {
190 tfc->ReadBuffer();
191 tfc->ReleaseGraphicsResources();
192 gl2ps->ProcessTransformFeedback(tfc, ren, col);
193 tfc->ReleaseBufferData();
194 }
195 }
196}
197
198//------------------------------------------------------------------------------
199// Returns true if the startAngle and stopAngle (as used in the ellipse drawing

Callers 4

DrawPolyMethod · 0.85
DrawLinesMethod · 0.85
DrawPointsMethod · 0.85
CoreDrawTrianglesMethod · 0.85

Calls 4

ReleaseBufferDataMethod · 0.80
ReadBufferMethod · 0.45

Tested by

no test coverage detected