POV-Ray : Newsgroups : povray.general : Override textures and materials? : Re: Override textures and materials? Server Time
1 Jun 2024 22:42:41 EDT (-0400)
  Re: Override textures and materials?  
From: Mike Horvath
Date: 17 Jan 2016 12:23:35
Message: <569bce17$1@news.povray.org>
On 1/17/2016 12:21 PM, Mike Horvath wrote:
> The color map should be more like this:
>
> pigment
> {
>      gradient (lookFrom - lookAt)
>      color_map
>      {
>          [0/6 srgb <1,0,0,>]
>          [1/6 srgb <1,1,0,>]
>          [2/6 srgb <0,1,0,>]
>          [3/6 srgb <0,1,1,>]
>          [4/6 srgb <0,0,1,>]
>          [5/6 srgb <1,0,1,>]
>          [6/6 srgb <1,0,0,>]
>      }
>      scale vlength(lookFrom - lookAt) * 2
>      translate lookFrom * -1
> }
>


Forgot to mention that the gradient should maybe not be linear, but 
rather tan() some angle. (Not 100% sure how to write the formula.)


Mike


Post a reply to this message

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