@kitware/vtk.js 22.5.10 → 22.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -175,9 +175,15 @@ function vtkImplicitPlaneRepresentation(publicAPI, model) {
|
|
|
175
175
|
// Update normal parameters
|
|
176
176
|
// --------------------------------
|
|
177
177
|
|
|
178
|
+
var pixelScale = 1;
|
|
179
|
+
|
|
180
|
+
if (model.scaleInPixels) {
|
|
181
|
+
pixelScale = publicAPI.getPixelWorldHeightAtCoord(origin);
|
|
182
|
+
}
|
|
183
|
+
|
|
178
184
|
model.pipelines.normal.source.set({
|
|
179
185
|
height: Math.max(xRange, yRange, zRange),
|
|
180
|
-
radius: model.handleSizeRatio * Math.min(xRange, yRange, zRange) * model.axisScale,
|
|
186
|
+
radius: model.handleSizeRatio * Math.min(xRange, yRange, zRange) * model.axisScale * pixelScale,
|
|
181
187
|
resolution: model.sphereResolution
|
|
182
188
|
});
|
|
183
189
|
var yAxis = model.pipelines.normal.source.getOutputData();
|
|
@@ -191,7 +197,7 @@ function vtkImplicitPlaneRepresentation(publicAPI, model) {
|
|
|
191
197
|
// --------------------------------
|
|
192
198
|
|
|
193
199
|
model.pipelines.origin.actor.setPosition(origin);
|
|
194
|
-
var handleScale = model.handleSizeRatio * Math.min(xRange, yRange, zRange);
|
|
200
|
+
var handleScale = model.handleSizeRatio * Math.min(xRange, yRange, zRange) * pixelScale;
|
|
195
201
|
model.pipelines.origin.actor.setScale(handleScale, handleScale, handleScale); // --------------------------------
|
|
196
202
|
// Update style since state changed
|
|
197
203
|
// --------------------------------
|