POV-Ray : Newsgroups : povray.general : Gravity well. Need iso-pigment help? : Re: Gravity well. Need iso-pigment help? Server Time
7 Aug 2024 17:28:22 EDT (-0400)
  Re: Gravity well. Need iso-pigment help?  
From: Bill DeWitt
Date: 30 Jul 2001 15:00:38
Message: <3b65aed6@news.povray.org>
"Ron Parker" <ron### [at] povrayorg> wrote in message
news:slr### [at] fwicom...
> On Mon, 30 Jul 2001 14:20:54 -0400, Bill DeWitt wrote:
> >I am trying to make a texture for my gravity well grid and I cannot seem
to
> >get it to work. Problem 1) regular color_maps can only seem to take 64
> >entries in their "Blendmap".
>
> The limit is really 256; I wonder why your code thinks it's lower.


    Because to make a stripe, you need four entries. Sorry, I used a count
variable and forgot to translate for that post. Here's the code:

#declare C = 0;
#declare GridTex3 =
 texture {
 pigment {
 gradient y
 color_map{
            #local   I = 0.00;
            #local   B = 0.01;
            #while ( I < 1.00 )
             [ I-B rgb < 0.0, 0.0, 0.4 >*2 ]
             [ I-B rgb 3 ]
             [ I+B rgb 3 ]
             [ I+B rgb < 0.0, 0.0, 0.4 >*2 ]
            #local B = (B*0.95);
            #declare C = C + 1;
            #local I = I + 0.0159;
            #debug concat("  I : ", str(I,2,4),
                          "  B : ", str(B,2,15),
                          "\n")
                   #end
         } /// end colormap
         } /// end pigment
         } /// end texture

#debug concat("  C : ", str(C,2,4),"\n")


Post a reply to this message

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