0

我正在使用点云。我想以 Z 方向的因子比例显示我的点云。然后我在视觉上增加默认值。我在我的实体上测试了转换“Scale”,但它似乎不起作用:

  PointCloud c = new PointCloud(pts.Count,1, PointCloud.natureType.Multicolor);
  c.Vertices = pts.ToArray();
  c.DrawingStyle = PointCloud.drawingStyleType.Points;
  c.Scale(new Point3D(0, 0, 0), 1, 1, 10); // Z => x10

  viewportLayout1.Entities.Add(c);

谢谢你的帮助

4

1 回答 1

1

you are just missing

viewportLayout1.Invalidate();

at the end of that. So you are scaling it, it just is not rendering it on your screen. Invalidate forces it to redraw your point cloud.

When in doubt I usually throw both of these after my changes. Make sure to take them out when not needed as they are expensive calls:

        viewportLayout1.Entities.Regen();
        viewportLayout1.Invalidate();
于 2020-09-23T21:48:50.430 回答