Endoscopy flythrough loop doesn't start from the same camera angle and changes every loop

Operating system: Windows 10
Slicer version: 4.11.20200930
I am using the endoscopy module and in it, the flythrough works fine but once one loop is over the camera angle(or up, down) changes and starts from a different angle. is there any way to fix the camera orientation?
Also, can the camera be set to one view and not rotate every loop.

There are many methods for moving a camera along a curve. The current method just updates the camera view plane normal and orthogonalizes the axes (Slicer/Endoscopy.py at master · Slicer/Slicer · GitHub).

We compute a transform that keeps one axis of the frame orthogonal to the curve’s plane (Slicer/Endoscopy.py at master · Slicer/Slicer · GitHub). You could change the Endoscopy module (it is just a Python script, you can edit with any text editor then click “Reload”) to use these axes as camera plane normal and view up directions.

Markups curves can provide coordinate frame for each curve point, too
(computed by parallel transport method). You could modify the code to use these axes (returned by

Thanks, this pointed me in the right direction

1 Like

If you make any improvements to the camera trajectory creation in Endoscopy module then it would be great if you could contribute it back. It allows other users benefit from your work and you can save time by not having to maintain your own version of the module.

1 Like