| 320 | } |
| 321 | |
| 322 | void vtkOSOpenGLRenderWindow::DestroyOffScreenWindow() |
| 323 | { |
| 324 | // Release graphic resources. |
| 325 | |
| 326 | // First release graphics resources on the window itself |
| 327 | // since call to Renderer's SetRenderWindow(nullptr), just |
| 328 | // calls ReleaseGraphicsResources on vtkProps. And also |
| 329 | // this call invokes Renderer's ReleaseGraphicsResources |
| 330 | // method which only invokes ReleaseGraphicsResources on |
| 331 | // rendering passes. |
| 332 | this->ReleaseGraphicsResources(this); |
| 333 | |
| 334 | if (this->Internal->OffScreenContextId) |
| 335 | { |
| 336 | this->Internal->OSMesaDestroyContext(this->Internal->OffScreenContextId); |
| 337 | this->Internal->OffScreenContextId = nullptr; |
| 338 | vtkOSMesaDestroyWindow(this->Internal->OffScreenWindow); |
| 339 | this->Internal->OffScreenWindow = nullptr; |
| 340 | } |
| 341 | } |
| 342 | |
| 343 | void vtkOSOpenGLRenderWindow::ResizeOffScreenWindow(int width, int height) |
| 344 | { |
no test coverage detected