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

Method UpdatePaths

Rendering/Image/vtkImageStack.cxx:557–587  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

555
556//------------------------------------------------------------------------------
557void vtkImageStack::UpdatePaths()
558{
559 if (this->GetMTime() > this->PathTime ||
560 (this->Paths && this->Paths->GetMTime() > this->PathTime))
561 {
562 if (this->Paths)
563 {
564 this->Paths->Delete();
565 }
566
567 // Create the list to hold all the paths
568 this->Paths = vtkAssemblyPaths::New();
569 vtkAssemblyPath* path = vtkAssemblyPath::New();
570
571 // Add ourselves to the path to start things off
572 path->AddNode(this, this->GetMatrix());
573
574 // Add the active image
575 vtkImageSlice* image = this->GetActiveImage();
576
577 if (image)
578 {
579 path->AddNode(image, image->GetMatrix());
580 image->BuildPaths(this->Paths, path);
581 path->DeleteLastNode();
582 }
583
584 path->Delete();
585 this->PathTime.Modified();
586 }
587}
588
589//------------------------------------------------------------------------------
590void vtkImageStack::BuildPaths(vtkAssemblyPaths* paths, vtkAssemblyPath* path)

Callers 4

GetBoundsMethod · 0.95
RenderOpaqueGeometryMethod · 0.95
InitPathTraversalMethod · 0.95
GetNumberOfPathsMethod · 0.95

Calls 9

GetMTimeMethod · 0.95
GetActiveImageMethod · 0.95
DeleteMethod · 0.65
NewFunction · 0.50
AddNodeMethod · 0.45
GetMatrixMethod · 0.45
BuildPathsMethod · 0.45
DeleteLastNodeMethod · 0.45
ModifiedMethod · 0.45

Tested by

no test coverage detected