POV-Ray : Newsgroups : povray.general : Parser messages Server Time
29 Jul 2024 14:17:52 EDT (-0400)
  Parser messages (Message 1 to 5 of 5)  
From: SGeier
Subject: Parser messages
Date: 13 May 2011 14:08:38
Message: <4dcd73a6@news.povray.org>
Low priority and not really a "bug", but there's a couple error/warning 
messages floating around that aren't really useful (and/or possibly 
misleading). I don't think they warrant a bug report, but I'm not sure where 
I would report them so that someone can think about them.

The one that triggered this post (and has been around for a metric 
forever[*]) is this one:
      Parse Warning: Suspicious expression after rgb.

which I get whenever I do something like this:

     color rgb CHSV2RGB(<n*2,.85,.7>)

Now CHSV2RGB isn't a built-in (it's in colors.inc) - but does that alone 
make it "suspicious"? And of course I use it mostly when I have something 
algorithmic (place a lot of objects in a circle, say, and color them by 
angle). So this error message tends to arise in large quantities, that can 
obscure other (legitimate) warnings.





([*] a metric forever is about 20% longer than an imperial forever)


Post a reply to this message

From: Jim Holsenback
Subject: Re: Parser messages
Date: 13 May 2011 15:07:31
Message: <4dcd8173@news.povray.org>
On 05/13/2011 03:08 PM, SGeier wrote:
> Low priority and not really a "bug", but there's a couple error/warning
> messages floating around that aren't really useful (and/or possibly
> misleading). I don't think they warrant a bug report, but I'm not sure where
> I would report them so that someone can think about them.
>
> The one that triggered this post (and has been around for a metric
> forever[*]) is this one:
>        Parse Warning: Suspicious expression after rgb.
>
> which I get whenever I do something like this:
>
>       color rgb CHSV2RGB(<n*2,.85,.7>)
>
> Now CHSV2RGB isn't a built-in (it's in colors.inc) - but does that alone
> make it "suspicious"? And of course I use it mostly when I have something
> algorithmic (place a lot of objects in a circle, say, and color them by
> angle). So this error message tends to arise in large quantities, that can
> obscure other (legitimate) warnings.
>
>
>
>
>
> ([*] a metric forever is about 20% longer than an imperial forever)
>
>
from colors.inc:
// Converts a color in HSL color space to a color in RGB color space.
// Input:  < Hue, Saturation, Lightness, Filter, Transmit >
// Output: < Red, Green, Blue, Filter, Transmit >

I'd suspect that since it's output has a transmit value specifying rgb 
is the problem ... try:

color rgbft CHSV2RGB(<n*2,.85,.7>)


Post a reply to this message

From: Jim Holsenback
Subject: Re: Parser messages
Date: 13 May 2011 15:09:32
Message: <4dcd81ec$1@news.povray.org>
On 05/13/2011 04:07 PM, Jim Holsenback wrote:
> On 05/13/2011 03:08 PM, SGeier wrote:
>> Low priority and not really a "bug", but there's a couple error/warning
>> messages floating around that aren't really useful (and/or possibly
>> misleading). I don't think they warrant a bug report, but I'm not sure
>> where
>> I would report them so that someone can think about them.
>>
>> The one that triggered this post (and has been around for a metric
>> forever[*]) is this one:
>> Parse Warning: Suspicious expression after rgb.
>>
>> which I get whenever I do something like this:
>>
>> color rgb CHSV2RGB(<n*2,.85,.7>)
>>
>> Now CHSV2RGB isn't a built-in (it's in colors.inc) - but does that alone
>> make it "suspicious"? And of course I use it mostly when I have something
>> algorithmic (place a lot of objects in a circle, say, and color them by
>> angle). So this error message tends to arise in large quantities, that
>> can
>> obscure other (legitimate) warnings.
>>
>>
>>
>>
>>
>> ([*] a metric forever is about 20% longer than an imperial forever)
>>
>>
> from colors.inc:
> // Converts a color in HSL color space to a color in RGB color space.
> // Input: < Hue, Saturation, Lightness, Filter, Transmit >
> // Output: < Red, Green, Blue, Filter, Transmit >
>
> I'd suspect that since it's output has a transmit value specifying rgb

oops ... meant to say transmit/filter value

> is the problem ... try:
>
> color rgbft CHSV2RGB(<n*2,.85,.7>)


Post a reply to this message

From: SGeier
Subject: Re: Parser messages
Date: 16 May 2011 12:57:38
Message: <4dd15782$1@news.povray.org>
"Jim Holsenback" <jho### [at] povrayorg> wrote in message 
news:4dcd8173@news.povray.org...
> On 05/13/2011 03:08 PM, SGeier wrote:
>> Low priority and not really a "bug", but there's a couple error/warning
>> messages floating around that aren't really useful (and/or possibly
>> misleading). I don't think they warrant a bug report, but I'm not sure 
>> where
>> I would report them so that someone can think about them.
>>
[...]
> I'd suspect that since it's output has a transmit value specifying rgb is 
> the problem ... try:
>
> color rgbft CHSV2RGB(<n*2,.85,.7>)

Woah - that may well be it. And it is exactly what I mean with messages that 
"aren't really useful (and/or possibly misleading)". If it expects a 3d 
vector and gets a 5d one, why can the message not simply say so? "Suspicious 
expression after rgb" doesn't tell me what it means with "suspicious".

Hence this post.

Could whoever is messing with the code have a look at some of these odd 
messages and make them a little more clear?


Post a reply to this message

From: Jim Holsenback
Subject: Re: Parser messages
Date: 16 May 2011 14:08:56
Message: <4dd16838$1@news.povray.org>
On 05/16/2011 01:57 PM, SGeier wrote:
> "Jim Holsenback"<jho### [at] povrayorg>  wrote in message
> news:4dcd8173@news.povray.org...
>> On 05/13/2011 03:08 PM, SGeier wrote:
>>> Low priority and not really a "bug", but there's a couple error/warning
>>> messages floating around that aren't really useful (and/or possibly
>>> misleading). I don't think they warrant a bug report, but I'm not sure
>>> where
>>> I would report them so that someone can think about them.
>>>
> [...]
>> I'd suspect that since it's output has a transmit value specifying rgb is
>> the problem ... try:
>>
>> color rgbft CHSV2RGB(<n*2,.85,.7>)
>
> Woah - that may well be it. And it is exactly what I mean with messages that
> "aren't really useful (and/or possibly misleading)". If it expects a 3d
> vector and gets a 5d one, why can the message not simply say so? "Suspicious
> expression after rgb" doesn't tell me what it means with "suspicious".
>
> Hence this post.
>
> Could whoever is messing with the code have a look at some of these odd
> messages and make them a little more clear?
>
>
the warning message is valid ... you can turn off the warning stream if 
it's troublesome for you. Have you tried rgbft instead of rgb? If that 
suppresses the warning then problem solved ... am I correct?

http://wiki.povray.org/content/Documentation:Reference_Section_1.3#Text_Streams


Post a reply to this message

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