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

Method SetControlPoint

Charts/Core/vtkColorTransferControlPointsItem.cxx:133–146  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

131
132//------------------------------------------------------------------------------
133void vtkColorTransferControlPointsItem::SetControlPoint(vtkIdType index, double* newPos)
134{
135 double xrgbms[6];
136 this->ColorTransferFunction->GetNodeValue(index, xrgbms);
137 if (newPos[0] != xrgbms[0] || newPos[2] != xrgbms[1] || newPos[3] != xrgbms[2])
138 {
139 xrgbms[0] = newPos[0];
140 xrgbms[4] = newPos[2];
141 xrgbms[5] = newPos[3];
142 this->StartChanges();
143 this->ColorTransferFunction->SetNodeValue(index, xrgbms);
144 this->EndChanges();
145 }
146}
147
148//------------------------------------------------------------------------------
149void vtkColorTransferControlPointsItem::EditPoint(float tX, float tY)

Callers

nothing calls this directly

Calls 4

StartChangesMethod · 0.80
EndChangesMethod · 0.80
GetNodeValueMethod · 0.45
SetNodeValueMethod · 0.45

Tested by

no test coverage detected