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

Method ClearRemovedInputs

Rendering/VolumeOpenGL2/vtkOpenGLGPUVolumeRayCastMapper.cxx:2976–3013  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

2974
2975//------------------------------------------------------------------------------
2976void vtkOpenGLGPUVolumeRayCastMapper::vtkInternal::ClearRemovedInputs(vtkWindow* win)
2977{
2978 bool orderChanged = false;
2979 for (const int& port : this->Parent->RemovedPorts)
2980 {
2981 auto it = this->Parent->AssembledInputs.find(port);
2982 if (it == this->Parent->AssembledInputs.cend())
2983 {
2984 continue;
2985 }
2986
2987 auto input = (*it).second;
2988 if (input.Texture)
2989 {
2990 input.Texture->ReleaseGraphicsResources(win);
2991 }
2992 if (input.GradientOpacityTables)
2993 {
2994 input.GradientOpacityTables->ReleaseGraphicsResources(win);
2995 }
2996 if (input.OpacityTables)
2997 {
2998 input.OpacityTables->ReleaseGraphicsResources(win);
2999 }
3000 if (input.RGBTables)
3001 {
3002 input.RGBTables->ReleaseGraphicsResources(win);
3003 }
3004 this->Parent->AssembledInputs.erase(it);
3005 orderChanged = true;
3006 }
3007 this->Parent->RemovedPorts.clear();
3008
3009 if (orderChanged)
3010 {
3011 this->ForceTransferInit();
3012 }
3013}
3014
3015//------------------------------------------------------------------------------
3016bool vtkOpenGLGPUVolumeRayCastMapper::vtkInternal::UpdateInputs(vtkRenderer* ren, vtkVolume* vol)

Callers 2

PreLoadDataMethod · 0.80
GPURenderMethod · 0.80

Calls 6

ForceTransferInitMethod · 0.95
findMethod · 0.45
cendMethod · 0.45
eraseMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected