POV-Ray : Newsgroups : povray.general : Dynamic Normals : Dynamic Normals Server Time
7 Aug 2024 09:26:25 EDT (-0400)
  Dynamic Normals  
From: Batronyx
Date: 13 Oct 2001 23:23:26
Message: <3bc9052e@news.povray.org>
Does anyone know of a way to determine the normal of a surface dynamically at
render time? trace() is static/parse time. Attempting to infer from a functions
using the slope pattern doesn't work; its not allowed in pattern syntax and
isn't evaluated dynamically during a render using pigment syntax.
And of course there isn't a f_normal() in functions include.

I created a generic box mapping function that works similar to uv_mapping for a
box and can use box map images made in UV Mapper or alternatively, one of up to
six other pigment functions. It behaves better with cutaway_textures than
uv_mapping for a box, and can be applied to spheres, or other arbitrary shapes.
However, it behaves more like the boxed pigment meaning it is better with mostly
convex objects whereas a proper implementation should take the direction of the
surface normal into account, thereby allowing proper behavior with more concave
objects as well.

I can think of a couple of other uses for having the normal available at
rendertime as well. Any ideas?


--
Batronyx ^"^
bat### [at] cadronhsacom //old & going away
bat### [at] alliancecablenet //new & active now.
http://www.batronyx.com


Post a reply to this message

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