POV-Ray : Newsgroups : povray.beta-test : material map bug Server Time
29 Jul 2024 16:21:04 EDT (-0400)
  material map bug (Message 1 to 2 of 2)  
From: Henry Bush
Subject: material map bug
Date: 6 Apr 2002 07:17:51
Message: <3CAEE77F.4060700@hotmail.com>
Apologies if this is known, I'm new to this.

My scene contains a box with a material map on it (80x80x16 colours)

When this scene is rendered several times, I get (seemingly random) 
different colours for the
space outside the circle (which is palette index 15 and not specified in 
the map), and therefore the other two visible sides of the box. I've had 
black and yellow mostly (indices 0 and 2-15), but also red occasionally 
(index 1). And it doesn't make a difference what map_type is used.

According to the docs, the colour should be 15%3=0 , so black. Have 
tested it with both BMP and PNG, with same results.

I've posted the scene on binaries, it's only small.

POV 3.5 Build 15, Athlon 650 o/c to 682, 512Mb RAM, Windows XP Pro.


Post a reply to this message

From: Dean
Subject: Re: material map bug
Date: 8 Apr 2002 14:04:01
Message: <3CB1DB76.3FFA6E1B@twoalpha.net>
Henry ,

Consider the changes to your observation.  I think it might be incomplete
code rather than a bug:

#version 3.5;

global_settings {
        ambient_light 6
  assumed_gamma 1.0
}

// ----------------------------------------

camera {
  location  <0.0, +1.5, -4.0>
  direction 2.5*z
  right     x*4/3 //image_width/image_height
  look_at   <0.5, 0.5,  0.5>
}

background {
        rgb .7
}


// ----------------------------------------



box {
  -<0,0,0>-.0000001 //to pass the interpolation
  <1,1,1>+.0000001 //to pass the interpolation
texture {

material_map {
  sys "circular window 1 stupidly small.bmp" //
  map_type 0
  interpolate 2
  texture { pigment {colour rgb <0,0,0>} }     // Black
  texture { pigment {colour rgb <1,0,0>} }  // Red
  texture { pigment {colour rgb <1,1,0>} }    // Yellow
texture { pigment {colour rgb <0,0,1>} } //Blue
/*
  FROM POV-ray help on material maps......
"If particular index values are not used in an image then it may be
necessary to supply dummy textures.
 It may be necessary to use a paint program or other utility to examine the
map file's palette to determine how to arrange the texture list."
I believe this is why the strange behavior.
*/

texture { pigment {colour rgb <0,1,0>} } //dummy  these dummy pigments show
at high resolution
texture { pigment {colour rgb <0,0,0>} } //dummy   they should be black or
matching the bitmap pallette
texture { pigment {colour rgb <0,1,0>} } //dummy    to make the correct
effect.
texture { pigment {colour rgb <0,0,0>} } //dummy
texture { pigment {colour rgb <0,1,0>} } //dummy
texture { pigment {colour rgb <0,0,0>} } //dummy
texture { pigment {colour rgb <0,1,0>} } //dummy
texture { pigment {colour rgb <0,0,0>} } //dummy
texture { pigment {colour rgb <0,1,0>} } //dummy
texture { pigment {colour rgb <0,0,0>} } //dummy
texture { pigment {colour rgb <0,0,0>} } //dummy
texture { pigment {colour rgb <1,1,1>} } //index 15
} // material_map
}
rotate y*45     // To get a better look
}
//.......eof

Dean Johnson      another beginner......

Bush wrote:

> Apologies if this is known, I'm new to this.
>
> My scene contains a box with a material map on it (80x80x16 colours)
>
> When this scene is rendered several times, I get (seemingly random)
> different colours for the
> space outside the circle (which is palette index 15 and not specified in
> the map), and therefore the other two visible sides of the box. I've had
> black and yellow mostly (indices 0 and 2-15), but also red occasionally
> (index 1). And it doesn't make a difference what map_type is used.
>
> According to the docs, the colour should be 15%3=0 , so black. Have
> tested it with both BMP and PNG, with same results.
>
> I've posted the scene on binaries, it's only small.
>
> POV 3.5 Build 15, Athlon 650 o/c to 682, 512Mb RAM, Windows XP Pro.


Post a reply to this message

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