[Bf-python] depth map with inverted z-buffer
Dalai Felinto
dfelinto at gmail.com
Tue Aug 7 22:19:06 CEST 2012
Hi Lynx ,
The depth in the z-buffer represents the distance of the pixels to the
camera. If you need to 'invert' it, you need to know the maximum depth you
have in the scene and do:
newdepth = maxdepth - depth (easy to do with a few Convertor->Math nodes)
Technically speaking, the MaxDepth is the camera Clip End distance.
By the way, this is more of a Blender question than a Python one. As such
it may be better fit in a forum such as BlenderArtists.org
Cheers,
Dalai
www.blendernetwork.org/member/dalai-felinto
2012/8/5 <lynx.abraxas at freenet.de>
> On 02/08/12 23:18:56, lynx.abraxas at freenet.de wrote:
> > Is it possible to create a depth map (as this demonstrated e.g.
> here:
> > https://sites.google.com/site/paprmh/zbuf_float) with an inverted
> z‐buffer?
> > I.e. that the resulting image of e.g. suzanne shows the z‐buffer of
> the back
> > of her head although the camera sees her from the front?
>
> Just found out how to do this for single objcets:
> Under Material disable! Transparency and choose "Invert Z Depth"
> under
> Options.
>
> But how can one achieve this for a whole scene in which objects overlap
> from
> the view of the camera?
>
> Thanks for any help or hints
> Lynx
> _______________________________________________
> Bf-python mailing list
> Bf-python at blender.org
> http://lists.blender.org/mailman/listinfo/bf-python
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.blender.org/pipermail/bf-python/attachments/20120807/bf8bb3bc/attachment.html>
More information about the Bf-python
mailing list