POV-Ray : Newsgroups : povray.general : What have I done? Server Time
5 Nov 2024 20:17:27 EST (-0500)
  What have I done? (Message 1 to 4 of 4)  
From: Doug Finch
Subject: What have I done?
Date: 6 Aug 1998 12:56:24
Message: <35C9D649.7C64@despam-synapse.com>
Here it is paired down to a minimum. In the Sphere pigment, what does
the stand-alone "1" do? I can't figure it out in the Manuals. 

This is strange!

camera {
    location <0, 0, -2>
    look_at <0, 0, 0>
  }

  plane { z, 4
    pigment { checker color rgb 0, color rgb .3 }
    finish { ambient 1 diffuse 0 }
    scale 0.5
  }

  sphere { 0, .5
    pigment { rgb <0,0,0> 1}
  }


Post a reply to this message

From: K  Tyler
Subject: Re: What have I done?
Date: 6 Aug 1998 14:00:41
Message: <35C9D2F6.AA3351EE@pacbell.net>
Doug Finch wrote:

> Here it is paired down to a minimum. In the Sphere pigment, what does
> the stand-alone "1" do? I can't figure it out in the Manuals.
>
> This is strange!
>   sphere { 0, .5  pigment { rgb <0,0,0> 1} }

From the POV-Ray 3.01 docs.

7.1.5.4 Color Operators

Color vectors may be combined in expressions the same as float or vector values.
Operations are performed on a component-by-component basis.
For example rgb<1, .5, .2> * 0.9 evaluates the same as rgb <1,.5,.2>*<.9,.9,.9>
or rgb<.9,.45,.18>. Other operations are done on a similar
component-by-component basis.

They say it better than I could.

K.Tyler


Post a reply to this message

From: Doug Finch
Subject: Re: What have I done?
Date: 6 Aug 1998 16:15:25
Message: <35CA04EF.408C@despam-synapse.com>
But <0,0,0> * 1 = <0,0,0> !!!

And if you run this POV file you'll see that it displays a white
transparent circle (not even a sphere). I still don't understand. Plus
you see that in my source, I an NOT multipling anything!

Did you run this file?

Thanks, but I still don't understand...

K. Tyler wrote:
> 
> Doug Finch wrote:
> 
> > Here it is paired down to a minimum. In the Sphere pigment, what does
> > the stand-alone "1" do? I can't figure it out in the Manuals.
> >
> > This is strange!
> >   sphere { 0, .5  pigment { rgb <0,0,0> 1} }
> 
> From the POV-Ray 3.01 docs.
> 
> 7.1.5.4 Color Operators
> 
> Color vectors may be combined in expressions the same as float or vector values.
> Operations are performed on a component-by-component basis.
> For example rgb<1, .5, .2> * 0.9 evaluates the same as rgb <1,.5,.2>*<.9,.9,.9>
> or rgb<.9,.45,.18>. Other operations are done on a similar
> component-by-component basis.
> 
> They say it better than I could.
> 
> K.Tyler


Post a reply to this message

From: K  Tyler
Subject: Re: What have I done?
Date: 6 Aug 1998 16:41:46
Message: <35C9F8B3.6AD4D4DB@pacbell.net>
Doug Finch wrote:

> But <0,0,0> * 1 = <0,0,0> !!!

> And if you run this POV file you'll see that it displays a white
> transparent circle (not even a sphere). I still don't understand. Plus
> you see that in my source, I an NOT multipling anything!
>
> Did you run this file?

Yes! After which I turned to the docs for an explanation.Since the phrasing used in
the docs was so similar i had answered the question.

> Thanks, but I still don't understand...

So in retrospect I will attempt to give a good guess instead.
I think what is happening is the pigment statement syntax used
is instructing pov to apply a value of 1 to all 5 functions of the
color operatives

If - pigment{rgb<0,0,0> 0} produces a solid sphere  ( I checked )

And - pigment{rgb<0,0,0> 1} produces a near totally transperent sphere  ( we both have
confrmed )

Of which probably evaluates to the equivilent of this - pigment{rgbft<1,1,1,1,1>}

I then conclude my guess to be correct.

Replace the questionable statement with pigment{rgbft<1,1,1,1,1>}
and compare the differences in the resulting image.
I'm betting they will be identical.

Have a nice render! er a day!

K.Tyler


Post a reply to this message

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