Rendering wireframe in offscreen renderer

How do you render the wireframe in the offscreen renderer?

My current workaround is to render the mesh on a black background, render the wireframe on a white background, and then multiply the two. It kinda of works, but it falls apart when there are occluding objects, as the wireframe doesn’t handle occlusions well, like the table in this LiDAR scan:


Is there a way to render the wireframe lines on their own using the offscreen renderder?

Note that this is easy to do in the current (soon-to-be-deprecated) visualizer by simply showing the wireframe and saving the image buffer. However, this action is not clearly exposed in the new visualizer or offscreen renderer.