POV-Ray : Newsgroups : povray.general : RGB color Index : Re: RGB color Index Server Time
31 Jul 2024 14:29:26 EDT (-0400)
  Re: RGB color Index  
From: Tim Attwood
Date: 18 Jan 2007 19:16:24
Message: <45b00dd8@news.povray.org>
> I am using POV for visualize my finite element analysis results of
> buildings. I use RGB color to represent the displacement of buildings. Now
> I need to put a color index which corresponds to the dispalcement. But I
> dont know how to make a color index in POV. Please somebody help me as 
> soon
> as possible early because next week I have a presentation.
> Thanks a lot in advance.

I'm not entirely clear as to what you mean.

You might want to look at image_map.
The colors come from an image file and can be mapped
onto a 3d object. (3.5.1.5  Image Maps)

If you have a list of  RGB colors you have computed,
then you might want to place them into an array.
(3.2.1.8.1  Declaring Arrays)

#declare disp = arrary[2];
#declare disp[0] = pigment{color <0,0,0>};
#declare disp[1] = pigment{color <1,1,1>};

then later you can use them like this

object { thing
   pigment{disp[0]}
}


Post a reply to this message

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