I have a 3D point cloud that I visualize with the pptk package in python. Viewing the point cloud is no problem but as soon as I call the capture method to take a screenshot no points are visible in the resulting image.
What it looks like in the viewer (changed perspective as I can't show the full data):
What the resulting screenshot looks like:
This is the code I use to display and capture the pointcloud:
# plot the points shaded by distance
v = pptk.viewer(np.array(frame_points))
v.attributes(np.array(frame_colors))
# set point size
v.set(point_size=0.05)
# set background color
v.set(bg_color=[0, 0, 0, 0])
# remove grid
v.set(show_grid=False)
# set camera position correctly
v.set(phi=1.57072818)
v.set(theta=-1.6201359)
v.set(r=18.55500031)
v.set(lookat=[1.64106417, 1.04901338, 16.93110657])
# create screen capture
v.capture('./images/screenshot.png')