Depth map question

I have created a scene which I then use ShowZBuffer and -ViewCaptureToFile to save. If I use “Scale=1” I get what I was hoping for.

However, if I use “Scale=2” I get a file that’s twice the size but the Depth Map info is wrong. It looks like it’s create Scale^2 panels and created a depth map for each panel.

So how do I create a single depth map that is part of a much higher resolution jpg file? In this case my window is 1199 x 700 but I’d like to use Scale=4 to get to (about) 4800 x 2800.

Alternatively, is there a different/better way (e.g. a render setting in Flamingo) to create a depth map of my 3D scene/objects?



Oh yeah, just in case it’s a video card driver issue, I have an NVidia Quadro K2200 card.

Hi Steve- the problem is that in tiling, the Z range is calculated separately for each tile. A workaround is to place a point object at the top an bottom of the scene at locations that force at least one pair to fall in each tile of the final image- that way, the depth of the scene will be equal in all tiles. If there are four tiles, running BoundingBox > Output=Curves and then ExtractPt from the polylines generated and delete the lines is a quick way to get the points. For an oblique view, I guess set CPLane > View, then make the bounding box as CPlane based. Probably a good idea to save the view as well. (NamedView)



I tried your suggestion but got the same result, except now with 8 points in the view.

Hm… it did seem to get it right here - I’ll poke it some more - hang on a second. Oh wait - read the last part of my post above - for an oblique view, you’ll need to tweak the bounding box.


Sorry but I only did half of your first set of instructions… Too eager I guess. If I do the CPlane - View part and repeat the Bounding box steps, I get a result that is much better, close even, but I can still see the seams in the tiles. Maybe the data is valid (it’s going to be used in a wood CNC router to create pictures in wood) and it’s just the computer display that’s off.

Hi Steve - I don’t know if it is the display, I see that here as well in your image. I’ll test something similar here - seems like it ought to work but the perspective view may be throwing it off, maybe… try setting the view to parallel, just as a test.

Hmm - does not fix it. I don’t know- I’ll try some stuff and get back if it looks promising.

@SteveP , I poked around in our bug heap - it looks like this is on that pile:


@pascal, i also get these tiling problems, not only with ZBuffer but with background gradients.

@SteveP, there is a workaround to create huge ZBuffer images with the Rhino renderer:

  • disable skylight, hide any lights
  • assign a material to all objects with self-illumination enabled
  • render large image

Wait until the rendering is completely done, then click on the “show distance channel” button in the render window and save the image. (click no when it asks to save rgba channel)


Hi @Pascal,

Got excited because your workaround ‘on paper’ made sense, but I tested and can confirm still having slight seams problem - used a grid of points @ closer camera-aligned bbox and then projected them from camera to the furthest camera bbox plane, so in V1 they align and in each tile ‘should’ create the same zdepth range… but no. See attached.
ZBuffer_Tiling_Test.3dm (303.8 KB)

@Clement - good suggestion with rendering the Zbuffer; it may get too time consuming or more difficult on complex scenes with a lot of blocks etc. - still hope the tiling range can be fixed, and not per-tile… This also affects the new WIP SkylightShadows which will be critical to make it work for high-res, good looking screenshots.