POV-Ray : Newsgroups : povray.general : Illuminated Pie Chart : Re: Illuminated Pie Chart Server Time
10 Aug 2024 13:20:09 EDT (-0400)
  Re: Illuminated Pie Chart  
From: Chris Colefax
Date: 9 Dec 1999 03:29:29
Message: <384f6869@news.povray.org>
David Vincent-Jones <geo### [at] galaxynetcom> wrote:
> I would like to create a sector light, such as would be found on a small
> boat.
> It is rather like a pie chart with one part showing a red light, one part
> green and one part remains black.
> It is important that as the angle changes there is no black area between
the
> red and green nor any bleed from one color to the other.
> 2 spotlights with a very sharp fall-off looks about correct but how can I
> fit two of them ( or more ) into a single cylinder?

How about recreating the light just as it would be in real life, ie. put a
white light source behind a coloured filter with the pattern you desire, eg:

camera {location <1, 1, -3> look_at <0, 0, 10>}
light_source {<-100, 200, -400> rgb .5}  // Filler light
plane {z, 10 pigment {checker rgb .5, rgb 1}}

union {
   light_source {0, rgb 1
      spotlight point_at z radius 30 falloff 45}
   disc {z*.1, z, 1 hollow
      pigment {radial color_map {
         [.3 rgb 0] [.3 rgbf <1, 0, 0, 1>]
         [.7 rgbf <1, 0, 0, 1>]  [.7 rgbf <0, 1, 0, 1>]}
         rotate x*90}}
   scale .001} // Scale very small so filtering disc isn't visible

You can use all sorts of filtered pigments (including image maps and
animated pigments) to create projections of just about anything you want...


Post a reply to this message

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