Every time I do a load function on a pointcloud, my point of view changes to the middle of the pointcloud

165 Views Asked by At

I'm relatively new to pptk, and im trying to load point clouds one after another, with a fixed point of view.

the main problem is that after I set the point of view, like so:

v = pptk.viewer(xyz)
xyz = pptk.rand(180000, 3)
v.set(lookat=(100, 100, 100))#---> this one is works and set the look at to x:100 y:100 z:100.
v.load(xyz)#--> changes my camera to x:0 y:0 z:0.

Any idea on how to set the camera setting to be fixed?

1

There are 1 best solutions below

0
Mr Z On

You can set your wiev angle and position with this code below;

v.set(phi=0.2)
v.set(theta=0.2)
v.set(r=1)
v.set(lookat=(0, 0, 0))