POV-Ray : Newsgroups : povray.binaries.scene-files : "povmap.gif" problem. Server Time
1 Sep 2024 18:15:52 EDT (-0400)
  "povmap.gif" problem. (Message 1 to 10 of 10)  
From: CFM
Subject: "povmap.gif" problem.
Date: 3 May 2004 14:10:00
Message: <web.40968a1badc19618b90c55f80@news.povray.org>
I don't know where else to post this, so I'll post it here. I'm using the
tutorial to help me understand and learn POV-ray. In the
Beginning Tutorial, under Advanced Texture Options, in the When All Else
Fails: Material Maps section, I tried the "povmap.gif" statement given.
However, it comes back with an error message that says, "Error opening GIF
image." Is the file even stored in my hard drive? If so, where do I go to
get the program to read this file? I don't know what to do.


Post a reply to this message

From: Alf Peake
Subject: Re: "povmap.gif" problem.
Date: 3 May 2004 17:14:04
Message: <4096b61c@news.povray.org>
"CFM" <nomail@nomail> wrote in message
news:web.40968a1badc19618b90c55f80@news.povray.org...

>  ... I tried the "povmap.gif" statement given.

Hi

Use "povmap.png" instead, it is in the include folder.
"gif" support has been removed.

Alf


Post a reply to this message

From: CFM
Subject: Re: "povmap.gif" problem.
Date: 3 May 2004 19:30:00
Message: <web.4096d4ea2058b0b962bddb9c0@news.povray.org>
"Alf Peake" <alf### [at] peake42freeservecouk> wrote:
> "CFM" <nomail@nomail> wrote in message
> news:web.40968a1badc19618b90c55f80@news.povray.org...
>
> >  ... I tried the "povmap.gif" statement given.
>
> Hi
>
> Use "povmap.png" instead, it is in the include folder.
> "gif" support has been removed.
>
> Alf

Thanks. Unfortunately, I don't know how to use comment tags properly to
comment out stuff. I rendered with an error saying, "No */ closing comment
found." The error was found at the BACKGROUND command. Could you check
below to see what I did wrong?
#include "colors.inc"
#include "textures.inc"
#include "metals.inc"
camera {location <0,20,-35>
        look_at <0,0,0>
}
light_source {<-20,50,-50>color rgb<2,2,2>}
/*light_source {<10,30,-10>color White}
light_source {<0,30,10>color White}*/
plane {y,0 pigment {checker color Green color Yellow}}
background {rgb <.7,.7,1>}
/*This part declare a pigment for use
in the rust patch texture pattern*/
/*#declare Rusty=pigment {
  granite
  color_map {
    [0 rgb<.2,0,0>]
    [1 Brown]
  }
  frequency 20
}
//And this part applies it
//Notice that our original layered texture
//"Speckled_Metal" is now part of the map
#declare Rust_Patches=texture {
  bozo
  texture_map {
    [0,pigment {Rusty}]
    [.75, texture { //...has some flecks of rust...
    pigment {
      granite
      color_map {
        [0 rgb <.2,0,0>]
        [.2 color Brown]
        [.2 rgbt <1,1,1,1>]
        [1 rgbt <1,1,1,1>]
      }
      frequency 16
    }
  ] // (end rust fleck texture)
        [1, texture { //...and some sooty black marks
    pigment {
      bozo
      color_map {
        [0 color Black]
        [.2 color rgbt <0,0,0,.5>]
        [.4 color rgbt <.5,.5,.5,.5>]
        [.5 color rgbt <1,1,1,1>]
        [1 color rgbt <1,1,1,1>]
      }
      scale 3
    }
  ]} // (end of sooty mark texture)
} // (end of box declaration)
  }
}
/*box {
  <-10,0,-10>,<10,10,10>
    texture {
      Rust_Patches}}/*Silver_Metal //a metal object...
    normal { //...which has suffered a beating
      dents 2
      scale 1.5
    }
  } // (end of base texture)*/


plane {
  -z, 0
  texture {
    material_map {
      png "povmap.png"
      interpolate 2
      once
      texture {PinkAlabaster}//the inner border
      texture {pigment {DMFDarkOak}}//outer border
      texture {Gold_Metal}//lettering
      texture {Chrome_Metal}//the window panel
    }
    translate <-.5,-.5,0>
    scale 5
  }
}


Post a reply to this message

From: stephen parkinson
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 00:38:39
Message: <40971e4f$1@news.povray.org>
CFM wrote:
> "Alf Peake" <alf### [at] peake42freeservecouk> wrote:
> 
>>"CFM" <nomail@nomail> wrote in message
>>news:web.40968a1badc19618b90c55f80@news.povray.org...
>>
>>
>>> ... I tried the "povmap.gif" statement given.
>>
>>Hi
>>
>>Use "povmap.png" instead, it is in the include folder.
>>"gif" support has been removed.
>>
>>Alf
> 
> 
> Thanks. Unfortunately, I don't know how to use comment tags properly to
> comment out stuff. I rendered with an error saying, "No */ closing comment
> found." The error was found at the BACKGROUND command. Could you check
> below to see what I did wrong?
> #include "colors.inc"
> #include "textures.inc"
> #include "metals.inc"
> camera {location <0,20,-35>
>         look_at <0,0,0>
> }
> light_source {<-20,50,-50>color rgb<2,2,2>}
> /*light_source {<10,30,-10>color White}
> light_source {<0,30,10>color White}*/
> plane {y,0 pigment {checker color Green color Yellow}}
> background {rgb <.7,.7,1>}
> /*This part declare a pigment for use
> in the rust patch texture pattern*/
> /*#declare Rusty=pigment {
>   granite
>   color_map {
>     [0 rgb<.2,0,0>]
>     [1 Brown]
>   }
>   frequency 20
> }  */
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^*******
> //And this part applies it
> //Notice that our original layered texture
> //"Speckled_Metal" is now part of the map
> #declare Rust_Patches=texture {
>   bozo
>   texture_map {
>     [0,pigment {Rusty}]
>     [.75, texture { //...has some flecks of rust...
>     pigment {
>       granite
>       color_map {
>         [0 rgb <.2,0,0>]
>         [.2 color Brown]
>         [.2 rgbt <1,1,1,1>]
>         [1 rgbt <1,1,1,1>]
>       }
>       frequency 16
>     }
>   ] // (end rust fleck texture)
>         [1, texture { //...and some sooty black marks
>     pigment {
>       bozo
>       color_map {
>         [0 color Black]
>         [.2 color rgbt <0,0,0,.5>]
>         [.4 color rgbt <.5,.5,.5,.5>]
>         [.5 color rgbt <1,1,1,1>]
>         [1 color rgbt <1,1,1,1>]
>       }
>       scale 3
>     }
>   ]} // (end of sooty mark texture)
> } // (end of box declaration)
>   }
> }
> /*box {
>   <-10,0,-10>,<10,10,10>
>     texture {
>       Rust_Patches}}/*Silver_Metal //a metal object...
>     normal { //...which has suffered a beating
>       dents 2
>       scale 1.5
>     }
>   } // (end of base texture)*/
> 
> 
> plane {
>   -z, 0
>   texture {
>     material_map {
>       png "povmap.png"
>       interpolate 2
>       once
>       texture {PinkAlabaster}//the inner border
>       texture {pigment {DMFDarkOak}}//outer border
>       texture {Gold_Metal}//lettering
>       texture {Chrome_Metal}//the window panel
>     }
>     translate <-.5,-.5,0>
>     scale 5
>   }
> }

two styles
c++ two forward slashes "//" from here to end of line is comment

c style  /* everything inside "/* ....... */" is a
comment, and it does multiple lines as
well
*/

i have a feeling that the error is usually not the line it last prints 
but is something to do with the next one
in this case the first comment parsed
but the next comment, trying to comment out the rusty texture was
not terminated.

stephen


Post a reply to this message

From: Spock
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 09:13:56
Message: <40979714@news.povray.org>
Stephen Parkinson has already explained the two comment types so I won't repeat his
text, but I should point out that when you close the comment that 
starts with

/*#declare Rusty=pigment

then you have a second problem on the line that starts with

/*box {

In traditional C programming (which this is not) it is not possible to nest the /* */
comments.  The following is invalid and will not parse:

/* hello /* world */ */

I mention this because the box contains a Silver_Metal texture that has been commented
out.

Kinda messy right now but I'm sure you will figure it out.

Good luck.


Post a reply to this message

From: stephen parkinson
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 12:02:12
Message: <4097be84$1@news.povray.org>
Spock wrote:
> Stephen Parkinson has already explained the two comment types so I won't 
> repeat his text, but I should point out that when you close the comment 
> that starts with
> 
> /*#declare Rusty=pigment
> 
> then you have a second problem on the line that starts with
> 
> /*box {
> 
> In traditional C programming (which this is not) it is not possible to 
> nest the /* */ comments.  The following is invalid and will not parse:
> 
> /* hello /* world */ */
> 
> I mention this because the box contains a Silver_Metal texture that has 
> been commented out.
> 
> Kinda messy right now but I'm sure you will figure it out.
> 
> Good luck.
> 
> 

missed that one, didn't spot it at all due to not actually trying the 
code. If i had, i would probably left it as 'an exercise for the 
student' to find any remaining problem(s)
                                        ^ just to worry him :-)

stephen


Post a reply to this message

From: Marvin T
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 12:42:44
Message: <4097c804@news.povray.org>
CFM wrote:
> 
> Thanks. Unfortunately, I don't know how to use comment tags properly to
> comment out stuff. I rendered with an error saying, "No */ closing comment
> found." The error was found at the BACKGROUND command. Could you check
> below to see what I did wrong?

In addition, and especially if you are trying to "comment" a section 
that has embedded /*-*/ comments, you can also "if" them out:

#if (0)
    #include "something.inc"	// blah, blah
    /* some text */
    object { MyObj scale <5,2,3> translate <50,1,3.25>
#end


Post a reply to this message

From: CFM
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 16:35:00
Message: <web.4097fe122058b0b9f1c8a6e90@news.povray.org>
stephen parkinson <ste### [at] zmemw16demoncouk> wrote:
> Spock wrote:
> > Stephen Parkinson has already explained the two comment types so I won't
> > repeat his text, but I should point out that when you close the comment
> > that starts with
> >
> > /*#declare Rusty=pigment
> >
> > then you have a second problem on the line that starts with
> >
> > /*box {
> >
> > In traditional C programming (which this is not) it is not possible to
> > nest the /* */ comments.  The following is invalid and will not parse:
> >
> > /* hello /* world */ */
> >
> > I mention this because the box contains a Silver_Metal texture that has
> > been commented out.
> >
> > Kinda messy right now but I'm sure you will figure it out.
> >
> > Good luck.
> >
> >
>
> missed that one, didn't spot it at all due to not actually trying the
> code. If i had, i would probably left it as 'an exercise for the
> student' to find any remaining problem(s)
>                                         ^ just to worry him :-)
>
> stephen


Thanks for the help. That really cleared up everything for me.


Post a reply to this message

From: stephen parkinson
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 16:55:15
Message: <40980333$1@news.povray.org>
CFM wrote:
> stephen parkinson <ste### [at] zmemw16demoncouk> wrote:
> 
>>Spock wrote:
>>
>>>Stephen Parkinson has already explained the two comment types so I won't
>>>repeat his text, but I should point out that when you close the comment
>>>that starts with
>>>
>>>/*#declare Rusty=pigment
>>>
>>>then you have a second problem on the line that starts with
>>>
>>>/*box {
>>>
>>>In traditional C programming (which this is not) it is not possible to
>>>nest the /* */ comments.  The following is invalid and will not parse:
>>>
>>>/* hello /* world */ */
>>>
>>>I mention this because the box contains a Silver_Metal texture that has
>>>been commented out.
>>>
>>>Kinda messy right now but I'm sure you will figure it out.
>>>
>>>Good luck.
>>>
>>>
>>
>>missed that one, didn't spot it at all due to not actually trying the
>>code. If i had, i would probably left it as 'an exercise for the
>>student' to find any remaining problem(s)
>>                                        ^ just to worry him :-)
>>
>>stephen
> 
> 
> 
> Thanks for the help. That really cleared up everything for me.
> 

pleasure

forgive my strange snse of humour

stephen


Post a reply to this message

From: Slime
Subject: Re: "povmap.gif" problem.
Date: 4 May 2004 20:25:58
Message: <40983496$1@news.povray.org>
> Thanks. Unfortunately, I don't know how to use comment tags properly to
> comment out stuff. I rendered with an error saying, "No */ closing comment
> found." The error was found at the BACKGROUND command. Could you check
> below to see what I did wrong?

Although, as Spock mentioned, C++ and most similar languages do not support
/* /* */ */ nesting, POV-Ray *does* support comment nesting, and that's why
it doesn't like your code. Your code has:

/*#declare Rusty=pigment {
...
/*box {
...
} // (end of base texture)*/
...

But POV-Ray expects another */ somewhere to end the comment that began at
#declare Rusty. Note that the syntax coloring does not accurately reflect
this fact.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

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