POV-Ray : Newsgroups : povray.general : Storing depth - normal map : Re: Storing depth - normal map Server Time
5 May 2024 00:25:37 EDT (-0400)
  Re: Storing depth - normal map  
From: clipka
Date: 1 Jun 2016 08:08:12
Message: <574ed02c@news.povray.org>
Am 01.06.2016 um 13:01 schrieb Mark B:

> I would like to store the scene depth values (and if possible the normal vector
> values as well) for every pixel. How can this be achieved using Pov ray 3.7? I
> have found no such examples online.

POV-Ray 3.7 does not have any native mechanism to obtain depth
information, so you'll need to design your scene in such a way that the
colours in the image happen to depend on the distance to the camera.

The most straightforward way to achieve this is to disable the
individual textures of all the scene's objects, bundle those objects
into one big union, and assign a texture with a gradient or spherical
pattern to it, with an emission-only finish.

An alternative is to set all objects' textures to a plain white
emission-only texture, and flood the scene with an absorbing atmosphere.
Or set all objects' textures to a pitch black texture, and flood the
scene with an emissive atmosphere.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.