I am using the following code to get a depth map of my scene. Which works! But even though i used “OrientationAxesVisibility = 0” there is a big square where the orientation axis used to be, with no depth values. Likely because this is some overlay, which is just invisible, but blocks the depth calculation. What could i use to also get depth values in that region.
import vtk
view = GetActiveView().GetRenderWindow()
view.OrientationAxesVisibility = 0
w2i = vtk.vtkWindowToImageFilter()
w2i.SetInputBufferTypeToZBuffer ()
w2i.SetInput(view)
w2i.Update()
writer = vtk.vtkXMLImageDataWriter()
writer.SetInputConnection(w2i.GetOutputPort())
writer.SetFileName("./depthmap.vti")
view.Render()
writer.Write()