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

Method UpdateVisibleSceneExtent

Views/Infovis/vtkHeatmapItem.cxx:675–690  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

673
674//------------------------------------------------------------------------------
675void vtkHeatmapItem::UpdateVisibleSceneExtent(vtkContext2D* painter)
676{
677 float position[2];
678 painter->GetTransform()->GetPosition(position);
679 this->SceneBottomLeft[0] = -position[0];
680 this->SceneBottomLeft[1] = -position[1];
681 this->SceneBottomLeft[2] = 0.0;
682
683 this->SceneTopRight[0] = static_cast<double>(this->GetScene()->GetSceneWidth() - position[0]);
684 this->SceneTopRight[1] = static_cast<double>(this->GetScene()->GetSceneHeight() - position[1]);
685 this->SceneTopRight[2] = 0.0;
686 vtkNew<vtkMatrix3x3> inverse;
687 painter->GetTransform()->GetInverse(inverse);
688 inverse->MultiplyPoint(this->SceneBottomLeft, this->SceneBottomLeft);
689 inverse->MultiplyPoint(this->SceneTopRight, this->SceneTopRight);
690}
691
692//------------------------------------------------------------------------------
693bool vtkHeatmapItem::LineIsVisible(double x0, double y0, double x1, double y1)

Callers 1

PaintBuffersMethod · 0.95

Calls 7

GetSceneWidthMethod · 0.80
GetSceneHeightMethod · 0.80
GetPositionMethod · 0.45
GetTransformMethod · 0.45
GetSceneMethod · 0.45
GetInverseMethod · 0.45
MultiplyPointMethod · 0.45

Tested by

no test coverage detected