POV-Ray : Newsgroups : povray.binaries.images : screen.inc in 3.7 - strange differences in lighting! Server Time
10 Jun 2024 09:37:21 EDT (-0400)
  screen.inc in 3.7 - strange differences in lighting! (Message 4 to 13 of 13)  
<<< Previous 3 Messages Goto Initial 10 Messages
From: clipka
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 22 Aug 2015 22:56:25
Message: <55d93659$1@news.povray.org>
Am 22.08.2015 um 11:45 schrieb "Jörg \"Yadgar\" Bleimann":
> Hi(gh)!
> 
> On 22.08.2015 02:36, Mike Horvath wrote:
> 
>> Is your gamma messed up? Make sure you are using "srgb" in color
>> declarations instead of "rgb".
> 
> I tried assumed_gamma 1.6 (which in fact is my system gamma value),

Don't!

Any value other than assumed_gamma 1.0 screws with the internal colour
computations in an unrealistic manner (or, maybe technically more to the
point, fails to screw with the supplied colour values in a realistic
manner). I guess I mentioned that already on one occasion or two...

If you're not happy with the look of the scene, indeed use "srgb"
instead of "rgb" to combat washed-out colours, and tweak the lighting to
combat overly bright scenes (if that's still an issue then); also, you
may want to reduce some materials' "ambient" settings or reduce
"ambient_light" (or use radiosity instead, which is a better idea anyway).

As for your system gamma value, that should go into the "Display_Gamma"
setting of your master .ini file, and nowhere else.

> and
> now it looks much better - not as dark as the original version, but
> acceptable to me!

Congratulations - you just managed to hide some more fundamental flaw in
your scene, that might bite you again further down the road...

The fact that including "screen.inc" makes any difference indicates that
there's something wrong other than just a change in gamma handling
(which is just a symptom), because "screen.inc" has nothing to do with
gamma.

Have a close look at POV-Ray's log output. Does it happen to say
anything about the #version directive? If I'm guessing correctly about
what is happening, your scene fails to have any. (Also, I guess I happen
to know that you didn't include any standard include files before you
added "screen.inc").

As of POV-Ray 3.7, the #version directive is not only mandatory, but
/must/ be the /first/ non-comment statement in your scene to ensure
flawless operation. And you do get a warning about that (if you'd care
to read it ;)).


Post a reply to this message

From: "Jörg \"Yadgar\" Bleimann"
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 23 Aug 2015 17:52:03
Message: <55da4083$1@news.povray.org>
Hi(gh)!

On 23.08.2015 04:56, clipka wrote:

> If you're not happy with the look of the scene, indeed use "srgb"
> instead of "rgb" to combat washed-out colours, and tweak the lighting to
> combat overly bright scenes (if that's still an issue then); also, you
> may want to reduce some materials' "ambient" settings or reduce
> "ambient_light" (or use radiosity instead, which is a better idea anyway).

Whatever values I tried for "s", I got completely weird hues - a green 
"grass" texture changed to dark blue or magenta!

> As of POV-Ray 3.7, the #version directive is not only mandatory, but
> /must/ be the /first/ non-comment statement in your scene to ensure
> flawless operation. And you do get a warning about that (if you'd care
> to read it ;)).

Yes, I added #version 3.7, but it didn't help either...

See you in Khyberspace!

Yadgar


Post a reply to this message

From: Cousin Ricky
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 23 Aug 2015 21:17:17
Message: <55da709d$1@news.povray.org>
On 08/23/2015 05:52 PM, "Jörg \"Yadgar\" Bleimann" wrote:
> Yes, I added #version 3.7, but it didn't help either...

Did you use assumed_gamma 1?  If so, then you should use srgb instead of 
rgb wherever you define a color.  (If you use the named colors from 
colors.inc, then put srgb before the color name and ignore the 
"suspicious expression" warning.)


Post a reply to this message

From: clipka
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 24 Aug 2015 09:30:42
Message: <55db1c82@news.povray.org>
Am 23.08.2015 um 23:52 schrieb "Jörg \"Yadgar\" Bleimann":
> Hi(gh)!
> 
> On 23.08.2015 04:56, clipka wrote:
> 
>> If you're not happy with the look of the scene, indeed use "srgb"
>> instead of "rgb" to combat washed-out colours, and tweak the lighting to
>> combat overly bright scenes (if that's still an issue then); also, you
>> may want to reduce some materials' "ambient" settings or reduce
>> "ambient_light" (or use radiosity instead, which is a better idea
>> anyway).
> 
> Whatever values I tried for "s", I got completely weird hues - a green
> "grass" texture changed to dark blue or magenta!

What do you mean by "s"? And can you provide examples with a bit of SDL
code and the resulting imagery?

Green (i.e. a colour with the "green" channel having the highest value
of all channels) should never turn magenta (i.e. a colour with the
"green" channel having the lowest value of all channels), no matter the
gamma handling (as long as you're not trying pathological stuff like use
negative gamma values or some such). Therefore, if you actually see such
symptoms, my next best bet would be that there's something much more
fundamentally wrong about your POV-Ray binary and/or your hardware.


>> As of POV-Ray 3.7, the #version directive is not only mandatory, but
>> /must/ be the /first/ non-comment statement in your scene to ensure
>> flawless operation. And you do get a warning about that (if you'd care
>> to read it ;)).
> 
> Yes, I added #version 3.7, but it didn't help either...

What do you mean by "didn't help"? If "help" = "fix the colour issues",
then you're approaching the situation with wrong expectations. If "help"
= "provoke the colour issues even without including 'screen.inc'", then
I'm pretty surprised it didn't.

Specifying the "#version" directive should do no more nor less than
"stabilize" POV-Ray's behaviour with regards to whether "screen.inc" is
included or not (and along the way suppress a warning you should get
otherwise). If the "#version" directive achieves that, it means that I'm
on the right track as to why the include file makes a difference (please
let me know whether that is the case), and also confirms that the colour
changes are probably related to gamma. If it doesn't, it means something
entirely different is at work.


Post a reply to this message

From: Nekar Xenos
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 24 Aug 2015 14:00:18
Message: <op.x3vwapf1ufxv4h@xena>


<yaz### [at] gmxde> wrote:

> Hi(gh)!
>
> On 23.08.2015 04:56, clipka wrote:
>
>> If you're not happy with the look of the scene, indeed use "srgb"
>> instead of "rgb" to combat washed-out colours, and tweak the lighting
 to
>> combat overly bright scenes (if that's still an issue then); also, yo
u
>> may want to reduce some materials' "ambient" settings or reduce
>> "ambient_light" (or use radiosity instead, which is a better idea  

>> anyway).
>
> Whatever values I tried for "s", I got completely weird hues - a green
  

> "grass" texture changed to dark blue or magenta!
>

srgb is a 3_Term_Vector

-- 

-Nekar Xenos-


Post a reply to this message

From: "Jörg \"Yadgar\" Bleimann"
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 24 Aug 2015 14:19:43
Message: <55db603f@news.povray.org>
Hi(gh)!

On 24.08.2015 15:30, clipka wrote:

> What do you mean by "s"? And can you provide examples with a bit of SDL
> code and the resulting imagery?
>
> Green (i.e. a colour with the "green" channel having the highest value
> of all channels) should never turn magenta (i.e. a colour with the
> "green" channel having the lowest value of all channels), no matter the
> gamma handling (as long as you're not trying pathological stuff like use
> negative gamma values or some such). Therefore, if you actually see such
> symptoms, my next best bet would be that there's something much more
> fundamentally wrong about your POV-Ray binary and/or your hardware.

O. k., meanwhile I also found out that srgb does not expect a four-part 
color vector - I removed the fourth value, and now everything works fine 
(see attachment)!

See you in Khyberspace!

Yadgar


Post a reply to this message


Attachments:
Download 'povigma000.png' (908 KB)

Preview of image 'povigma000.png'
povigma000.png


 

From: Mike Horvath
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 24 Aug 2015 17:02:33
Message: <55db8669$1@news.povray.org>
On 8/23/2015 5:52 PM, "Jörg \"Yadgar\" Bleimann" wrote:
> Whatever values I tried for "s", I got completely weird hues - a green
> "grass" texture changed to dark blue or magenta!
>

"s" is not a value you supply. It just tells povray to use the newer 
color system.


Mike


Post a reply to this message

From: clipka
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 25 Aug 2015 01:26:30
Message: <55dbfc86$1@news.povray.org>
Am 24.08.2015 um 20:19 schrieb "Jörg \"Yadgar\" Bleimann":

> O. k., meanwhile I also found out that srgb does not expect a four-part
> color vector - I removed the fourth value, and now everything works fine
> (see attachment)!

Whoops - it never crossed my mind that the keyword could be
misinterpreted that way, but yes, now that you mention it I see why...


For the records: The "srgb" keyword (along with its siblings, "srgbf",
"srgbt" and "srgbft") was chosen because it tells POV-Ray to interpret
the following vector (or the RGB portion of it, for the sibling
keywords) as colour coordinates in the colour space officially called
"sRGB" ("standard RGB").

This colour space has the benefit of (A) being a good approximation of
Your Average Uncalibrated Computer Display (it was designed in 1996
specifically to match typical display hardware of that time), and (B)
indeed having become a de-facto standard supported by everything that is
even remotely aware of colour spaces - including the World Wide Web,
which officially defaults to sRGB for everything that isn't explicitly
colour managed.


(Also for the records, nitpicking section, POV-Ray only properly
supports sRGB if you presume that its internal colour space uses the
same RGB primaries; that's a valid assumption though, as POV-Ray makes
no claims about its RGB primaries anywhere else, so POV-Ray's claim to
support sRGB can thus be interpreted as an implicit definition of its
internal RGB primaries as being those of sRGB.)


Post a reply to this message

From: Cousin Ricky
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 28 Aug 2015 23:22:28
Message: <55e12574@news.povray.org>
On 2015-25-08 01:26 AM (-4), clipka wrote:
> Am 24.08.2015 um 20:19 schrieb "Jörg \"Yadgar\" Bleimann":
>
>> O. k., meanwhile I also found out that srgb does not expect a four-part
>> color vector - I removed the fourth value, and now everything works fine
>> (see attachment)!
>
> Whoops - it never crossed my mind that the keyword could be
> misinterpreted that way, but yes, now that you mention it I see why...

Me neither.  His comment about trying values for "s" went straight by me.


Post a reply to this message

From: Mike Horvath
Subject: Re: screen.inc in 3.7 - strange differences in lighting!
Date: 1 Sep 2015 21:40:31
Message: <55e6538f$1@news.povray.org>
On 8/21/2015 5:42 PM, "Jörg \"Yadgar\" Bleimann" wrote:
> Hi(gh)!
>
> To add the scrolling info text (to be displayed when the ball runs
> through one of the two rotating "i" characters), I now used screen.inc
> in my POVigma project - and noticed a strange deviation in brightness
> and contrast (lighting settings are not changed since)!
>
> With screen.inc (nevertheless using a conventional camera, as a
> straight-down top view otherwise would yield an error), the whole scene
> is brighter and with less contrast, as showed in the two attached pictures.
>
> How can I fix this?
>
> See you in Khyberspace!
>
> Yadgar

IIRC I encountered some washed out and overly bright colors when 
switching between orthographic and perspective camera modes in 
screen.inc. Compare these two images:

http://s421.photobucket.com/user/SharkD2161/media/Povray/pov_screenupdate_a.png.html
http://s421.photobucket.com/user/SharkD2161/media/Povray/pov_screenupdate_b.png.html


Post a reply to this message

<<< Previous 3 Messages Goto Initial 10 Messages

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