POV-Ray : Newsgroups : povray.advanced-users : Override textures/materials? : Re: Override textures/materials? Server Time
19 Apr 2024 05:17:06 EDT (-0400)
  Re: Override textures/materials?  
From: clipka
Date: 19 Jun 2021 10:38:08
Message: <60ce0150$1@news.povray.org>
Am 19.06.2021 um 15:37 schrieb Norbert Kern:

> If you set every diffuse, specular, phong, ambient, emission and reflection
> value as zero, you get a black material.
> A white fog turns this to an inverse depthmap. Then you can adapt the color_map
> of your blurring file or you can invert it via Photoshop and co to get a
> "regular" depthmap.
> Here is a depthmap of my last image.

Some caveats of this approach:

- The brightness will not depend on the Z coordinate, but on the 
distance to the camera; this may or may not be what you want.

- The image value will not represent the distance itself, but rather an 
exponential-ish function thereof, something like:

     f(d) = 1 - p^d

where p is a value < 1. Again, this may or may not be what you want.


Also, like with every other thing where you want to get a per-pixel 
value out of the render rather than a color, the topic of gamma needs 
attention, and also precision, i.e. bit depth.


Post a reply to this message

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