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

Method BuildLabels2D

Rendering/Annotation/vtkAxisActor.cxx:541–558  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Set 2D label values and properties. ------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

539// Set 2D label values and properties.
540//------------------------------------------------------------------------------
541void vtkAxisActor::BuildLabels2D(vtkViewport* viewport, bool force)
542{
543 if (!force && (!this->LabelVisibility || this->NumberOfLabelsBuilt == 0))
544 {
545 return;
546 }
547
548 for (int i = 0; i < this->NumberOfLabelsBuilt; i++)
549 {
550 this->UpdateLabelActorProperty(i);
551 }
552
553 this->NeedBuild2D = this->BoundsDisplayCoordinateChanged(viewport);
554 if (force || this->NeedBuild2D)
555 {
556 this->SetLabelPositions2D(viewport, force);
557 }
558}
559
560//------------------------------------------------------------------------------
561// Determine and set scale factor and position for 2D labels.

Callers 1

BuildAxisMethod · 0.95

Calls 3

SetLabelPositions2DMethod · 0.95

Tested by

no test coverage detected