Got something to show up
The problem is that we will have to transform every vtkPoints
to destination gcs (like geotransform in vtk) and then we can have
reasonable near and far and also proper radius
MODIFY
src/camera.js
src/camera.js
right: 1,
top: 1,
bottom: -1,
- far: -2,
- near: -1
+ far: -100000,
+ near: 100000
};
/**

MODIFY
src/vtkjs/pointFeature.js
src/vtkjs/pointFeature.js
@@ -86,18 +86,22 @@ var vtkjs_pointFeature = function (arg) {
position[i3 + 2] = posVal.z || 0;
nonzeroZ = nonzeroZ || position[i3 + 2];
}
- // position = transform.transformCoordinates(
- // m_this.gcs(), m_this.layer().map().gcs(),
- // position, 3);
+ position = transform.transformCoordinates(
+ m_this.gcs(), m_this.layer().map().gcs(),
+ position, 3);
+
+ if (!nonzeroZ && m_this.gcs() !== m_this.layer().map().gcs()) {
+ for (i = i3 = 0; i < numPts; i += 1, i3 += 3) {
+ position[i3 + 2] = 0;
+ }
+ }
/* Some transforms modify the z-coordinate. If we started with all zero z
* coordinates, don't modify them. This could be changed if the
* z-coordinate space of the gl cube is scaled appropriately. */
- if (!nonzeroZ && m_this.gcs() !== m_this.layer().map().gcs()) {
for (i = i3 = 0; i < numPts; i += 1, i3 += 3) {
- position[i3 + 2] = 0;
var source = vtkSphereSource.newInstance();
source.setCenter(position[i3], position[i3 + 1], position[i3 + 2]);
- source.setRadius(100.0);
+ source.setRadius(100000.0);
var actor = vtkActor.newInstance();
var mapper = vtkMapper.newInstance();
actor.getProperty().setEdgeVisibility(true);
@@ -107,7 +111,7 @@ var vtkjs_pointFeature = function (arg) {
m_actors.push(actor);
}
m_this.buildTime().modified();
- }
+
console.debug("built vtkjs point feature");
};

Got something to show up

The problem is that we will have to transform every vtkPoints
to destination gcs (like geotransform in vtk) and then we can have
reasonable near and far and also proper radius