|
![](/i/fill.gif) |
High!
I just started to program a skript which should generate color_maps from
bitmap files... but eval_pigment doesn't seem to work as expected!
Whenever I run the skript, the generated satring.pov contains only
zeroes instead of the real red values from the read-in bitmap!
Another strange thing is that, otherwise than in the PoV 3.5 manual
stated, #write accepts only strings, not floats or vectors!
Here is the code:
#include "c:\Programme\POV-Ray for Windows v3.5/include/functions.inc"
#declare Sample=
pigment
{
image_map
{
png "e:\povdaten\Sonnensystem\Saturn\ring_sample_color.png"
once
}
scale <1, 380, 1>
}
plane
{
-z, 0
texture
{
pigment { Sample }
finish { ambient 1 }
}
}
camera
{
location <0, 190, -380>
look_at <0, 190, 0>
angle 50
}
#fopen Sample_File "e:\povscn\satring.pov" write
#declare i=0;
#while(i<256)
#declare col=eval_pigment(Sample, <0.5, 380-i, 0>);
#write (Sample_File, str(col.red, 3, 0), "\n")
#declare i=i+1;
#end
#fclose Sample_File
Post a reply to this message
|
![](/i/fill.gif) |