POV-Ray : Newsgroups : moray.win : rainbow : Re: rainbow Server Time
5 Jul 2024 08:08:25 EDT (-0400)
  Re: rainbow  
From: Mitchell Waite
Date: 12 Jan 2002 19:01:55
Message: <3c40ce73@news.povray.org>
Here is the rainbow function as described in the 3.1g docs. Is it something
that I can turn into a UDO? When I do will it look like the rainbow shape
that it is suppose to produce except in a wire frame mode?

#include "colors.inc"
  camera {
    location <0, 20, -100>
    look_at <0, 25, 0>
    angle 80
  }
  background { color SkyBlue }
  plane { y, -10 pigment { color Green } }
  light_source {<100, 120, 40> color White}
  // declare rainbow's colors
  #declare r_violet1 = color rgbf<1.0, 0.5, 1.0, 1.0>;
  #declare r_violet2 = color rgbf<1.0, 0.5, 1.0, 0.8>;
  #declare r_indigo  = color rgbf<0.5, 0.5, 1.0, 0.8>;
  #declare r_blue    = color rgbf<0.2, 0.2, 1.0, 0.8>;
  #declare r_cyan    = color rgbf<0.2, 1.0, 1.0, 0.8>;
  #declare r_green   = color rgbf<0.2, 1.0, 0.2, 0.8>;
  #declare r_yellow  = color rgbf<1.0, 1.0, 0.2, 0.8>;
  #declare r_orange  = color rgbf<1.0, 0.5, 0.2, 0.8>;
  #declare r_red1    = color rgbf<1.0, 0.2, 0.2, 0.8>;
  #declare r_red2    = color rgbf<1.0, 0.2, 0.2, 1.0>;
  // create the rainbow
  rainbow {
    angle 42.5
    width 5
    distance 1.0e7
    direction <-0.2, -0.2, 1>
    jitter 0.01
    color_map {
      [0.000  color r_violet1]
      [0.100  color r_violet2]
      [0.214  color r_indigo]
      [0.328  color r_blue]
      [0.442  color r_cyan]
      [0.556  color r_green]
      [0.670  color r_yellow]
      [0.784  color r_orange]
      [0.900  color r_red1]
    }
  }
"Dearmad" <dea### [at] applesnakenet> wrote in message
news:3C408FC9.9CB9A0F9@applesnake.net...
> UDO it.  You can do basic manipulation of it then.
>
> -peter
>
> Mitchell Waite wrote:
> >
> > But if I use an include they I can't manipulate it in Moray as an
object,
> > right?
> >
> > "Jan Walzer" <jan### [at] lzernet> wrote in message
> > news:3c402f39@news.povray.org...
> > > create an include file, where you define the rainbow, and ehhm ...
include
> > it
> > > ...
> > >
> > > But think of the changed hand-ness of moray ... in MOray there is z
up,
> > and y
> > > into the depth ...
> > >
> > > --
> > > "Somehow what you suggest is like suggesting to add drills \
> > jan### [at] lzernet
> > > to cars so you can drill for oil when you run out of fuel.  \
> > > Sure you could do it, but it might not be the most practical >
> > Jan
> > > solution." [Thorsten Froehlich in p.u.p]                    /
> > Walzer
> > >
> > >
> > >
>
> --
> Current obsession: "Ballet pour ma fille."
> http://www.applesnake.net


Post a reply to this message

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