I’m wondering if anyone knows of any existing code for saving a point cloud from all frames in an .svo file as .ply files rather than just saving them through depth viewer.
I’ve only seen codes that can save point clouds from a live camera feed and I’ve been unable to successfully modify any of them to be able to do what I need. Any advice or info from anyone would be really appreciated!
Just coming back to this after a bit of a break & still haven’t quite figured this out. I am trying to save a large number of point clouds from a recorded svo file. I’ve wrote this python code but have been unable to get any results. From what I understand I don’t need the lines for opening the camera because I’m trying to use an already recorded svo but I’m not sure I’m setting the path correctly?
I also wanted to check if I’m using the retrieve measure function correctly?
Thanks in advance
import pyzed.sl as sl
zed = sl.Camera()
#Set configuration parameters
svo_input_path = “C:/050523Bridge.svo”
init_params = sl.InitParameters()
init_params.coordinate_units = sl.UNIT.METER # Set units in meters
init_params.depth_mode = sl.DEPTH_MODE.ULTRA
init_params.depth_maximum_distance = 21
#open camera
err = zed.open(init_params)
if err !=sl.ERROR_CODE.SUCCESS:
print(repr(err))
exit(-1)
point_cloud = sl.Mat()
timer = 0
while timer < 600:
if zed.grab() == sl.ERROR_CODE.SUCCESS:
zed.retrieve_measure(point_cloud, MEASURE.XYZBGRA)