POV-Ray : Newsgroups : povray.general : Glass Server Time
8 Aug 2024 14:22:49 EDT (-0400)
  Glass (Message 10 to 19 of 19)  
<<< Previous 9 Messages Goto Initial 10 Messages
From: Peter Popov
Subject: Re: Glass
Date: 10 Jan 2001 10:13:31
Message: <838o5t8ke8ok7tpc1vid8cj519dq2tg97c@4ax.com>
On Tue, 09 Jan 2001 12:09:44 -0500, Chris Huff <chr### [at] maccom>
wrote:

>It sounds like you mean the fade_color addition...it lets you specify 
>the color that light passing through the object attenuates to, and adds 
>an attenuation calculation that is supposed to be more realistic. And it 
>has nothing to do with light source fading, it is more of a solid-color 
>media-like effect.

I actually mean this:

>:: 7.2. Realistic attenuation
>:: If you set fade_power in the interior of an object at 1000 or above, 
>:: MegaPov will use a realistic exponential attenuation function:
>:: 
>:: Attenuation = exp(-depth/fade_dist)
>:: 
>:: Colored attenuation does work with this exponential attenuation also.

Sorry abouit not being precise before but I just finished installing.


Peter Popov ICQ : 15002700
Personal e-mail : pet### [at] vipbg
TAG      e-mail : pet### [at] tagpovrayorg


Post a reply to this message

From: Warp
Subject: Re: Glass Reflections
Date: 10 Jan 2001 10:25:39
Message: <3a5c7ef2@news.povray.org>
J-Print News <vir### [at] iconcoza> wrote:
: Can this be done in Pov?

  The question would better be "could this be avoided with povray?".

  Povray does this by design. Trying to avoid this would be the hard thing
(I can't think of any way right now). Of course there's no reason to avoid
it...

-- 
char*i="b[7FK@`3NB6>B:b3O6>:B:b3O6><`3:;8:6f733:>::b?7B>:>^B>C73;S1";
main(_,c,m){for(m=32;c=*i++-49;c&m?putchar('\n'):m)for(_
=(c>>2)&7;putchar(m),_--?m:(_=(1<<(c&3))-1,(m^=3)&3););}  /*- Warp -*/


Post a reply to this message

From: Tom Melly
Subject: Re: Glass Reflections
Date: 10 Jan 2001 10:31:56
Message: <3a5c806c@news.povray.org>
"J-Print News" <vir### [at] iconcoza> wrote in message
news:3a5c77fc@news.povray.org...
> I just thought of something else. Glass reflects not only on the outside
but
> on the inside as well. If you look carefully at a window pane at night
> you'll notice there is actually a double reflection.
>
> Can this be done in Pov?
>

I wasn't sure so I tried it. This behaviour as far as I can see is
reproduced by default in both pov and mp. Try the following code:

#include "colors.inc"

light_source{<0,0,0> color rgb<1,1,1>*2 translate <0, 30, 0>}
light_source{<0,0,0> color rgb<1,1,1>*2 translate <0, -30, 0>}

camera{location  <5.0, 0.0, -5.0> look_at   <0.0, 0.0,  0.0>}

box{
  <-10,-10,0>,<10,10,1>
  pigment{rgbf 1}
  finish{reflection 1/2 ambient 0 diffuse 0}
}

sphere{0, 1 translate<-5,0,-5> pigment{Red}}


Post a reply to this message

From: Chris Huff
Subject: Re: Glass Reflections
Date: 10 Jan 2001 15:50:37
Message: <chrishuff-BEFAA0.15521810012001@news.povray.org>
In article <3a5c7ef2@news.povray.org>, Warp <war### [at] tagpovrayorg> 
wrote:

>   The question would better be "could this be avoided with povray?".
> 
>   Povray does this by design. Trying to avoid this would be the hard thing
> (I can't think of any way right now). Of course there's no reason to avoid
> it...

In the official version, textures affect both sides of each surface the 
same way, so glass panes will have that double-reflection effect 
(actually, many more than two reflections, depending on 
max_trace_level). MegaPOV allows you to override the texture of the 
"interior" side of the surface with the interior_texture feature. This 
feature also works with objects like bezier patches or triangles, which 
don't have an "interior" but clearly have two sides.

-- 
Christopher James Huff
Personal: chr### [at] maccom, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tagpovrayorg, http://tag.povray.org/

<><


Post a reply to this message

From: Jamie Davison
Subject: Re: Glass Reflections
Date: 10 Jan 2001 15:56:03
Message: <MPG.14c6dbdad88f5cb2989867@news.povray.org>
>   The question would better be "could this be avoided with povray?".

[snip]

Easy.  Define two textures for the glass, one with reflection, and one 
with none.

Construct your pane of glass as a CSG difference of two cubes, one taking 
a face off the other.  Assign the textures, one to each cube, and viola!  
You have a pane of glass which has one face which eiother reflects or 
does not reflect, depending on how you assigned the textures.

Bye for now,
     Jamie.


Post a reply to this message

From: Ron Parker
Subject: Re: Glass Reflections
Date: 10 Jan 2001 15:58:54
Message: <slrn95pj8h.agl.ron.parker@fwi.com>
On Wed, 10 Jan 2001 20:54:04 -0000, Jamie Davison wrote:
>Construct your pane of glass as a CSG difference of two cubes, one taking 
>a face off the other.  Assign the textures, one to each cube, and viola!  
>You have a pane of glass which has one face which eiother reflects or 
>does not reflect, depending on how you assigned the textures.

Maybe, maybe not.  There's also TIR, which is solely dependent on the
IOR of the object.

-- 
Ron Parker   http://www2.fwi.com/~parkerr/traces.html
My opinions.  Mine.  Not anyone else's.


Post a reply to this message

From: Jamie Davison
Subject: Re: Glass Reflections
Date: 10 Jan 2001 17:09:58
Message: <MPG.14c6ed695d0c3372989868@news.povray.org>
> >Construct your pane of glass as a CSG difference of two cubes, one taking 
> >a face off the other.  Assign the textures, one to each cube, and viola!  
> >You have a pane of glass which has one face which eiother reflects or 
> >does not reflect, depending on how you assigned the textures.
> 
> Maybe, maybe not.  There's also TIR, which is solely dependent on the
> IOR of the object.

True enough I suppose.  Then you could always just use a clipped plane as 
a single face of a pane of glass, and fake it.  (the great maxim of 
computer graphics as far as I'm concerned, if it's too tricky to do the 
real way, fake it.  <grin>)

Although thinking about it, assuming that both textures were identical 
apart from the reflection settings (Interior etc.) then surely the non-
reflective face would work to kill any TIR that might be taking place?

I'll try playing with it tomorrow night, as I need to hit the shower and 
get to bed since I'm knackered.

Bye for now,
     Jamie.


Post a reply to this message

From: Warp
Subject: Re: Glass Reflections
Date: 11 Jan 2001 06:30:57
Message: <3a5d9971@news.povray.org>
Jamie Davison <jam### [at] dh70qdu-netcom> wrote:
: Construct your pane of glass as a CSG difference of two cubes, one taking 
: a face off the other.  Assign the textures, one to each cube, and viola!  
: You have a pane of glass which has one face which eiother reflects or 
: does not reflect, depending on how you assigned the textures.

  This works only when looking from one side of the glass, but not the other
side.
  Suppose that we are also seeing the other side of the glass at the same
time through a mirror...

-- 
char*i="b[7FK@`3NB6>B:b3O6>:B:b3O6><`3:;8:6f733:>::b?7B>:>^B>C73;S1";
main(_,c,m){for(m=32;c=*i++-49;c&m?putchar('\n'):m)for(_
=(c>>2)&7;putchar(m),_--?m:(_=(1<<(c&3))-1,(m^=3)&3););}  /*- Warp -*/


Post a reply to this message

From: Warp
Subject: Re: Glass Reflections
Date: 11 Jan 2001 06:32:50
Message: <3a5d99e2@news.povray.org>
Chris Huff <chr### [at] maccom> wrote:
: with the interior_texture feature

  Is the bug about this feature, which I reported long ago, already fixed?-)

-- 
char*i="b[7FK@`3NB6>B:b3O6>:B:b3O6><`3:;8:6f733:>::b?7B>:>^B>C73;S1";
main(_,c,m){for(m=32;c=*i++-49;c&m?putchar('\n'):m)for(_
=(c>>2)&7;putchar(m),_--?m:(_=(1<<(c&3))-1,(m^=3)&3););}  /*- Warp -*/


Post a reply to this message

From: Chris Huff
Subject: Re: Glass Reflections
Date: 11 Jan 2001 07:55:50
Message: <chrishuff-3EB52D.07573311012001@news.povray.org>
In article <3a5d99e2@news.povray.org>, Warp <war### [at] tagpovrayorg> 
wrote:

> : with the interior_texture feature
> 
>   Is the bug about this feature, which I reported long ago, already 
>   fixed?-)

Hmm, probably not...I remember looking at the lighting code, but 
couldn't figure it out. It was some problem with filtering textures, 
right?

-- 
Christopher James Huff
Personal: chr### [at] maccom, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tagpovrayorg, http://tag.povray.org/

<><


Post a reply to this message

<<< Previous 9 Messages Goto Initial 10 Messages

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