POV-Ray : Newsgroups : povray.general : Transparent Textures Server Time
5 Nov 2024 01:23:07 EST (-0500)
  Transparent Textures (Message 1 to 6 of 6)  
From: Philip Bartol
Subject: Transparent Textures
Date: 17 Aug 1999 01:21:56
Message: <37b8f174@news.povray.org>
I had an idea for a cheat for doing a section of metal decking with holes in 
it using the marble pattern.

I used a marble pattern for a pigment, did a color_map starting with a rgbt of 
1 at 0, ended with "DarkSlateGray" at 1 and had a tight transition at around 
8 so I would get a hard edge between the metal and the open space.

The problem is that I found that while the texture had open spaces, the solid 
parts of the texture only where on the surface of my test object. I figured 
that since the pigment goes through the object if you cut it, that using a 
transparent color would show the solid portions thorugh the object.

My metal floor that this is going to be used on is very thin, so I could still 
use it as is, just make the thickness of the cylinder I'm using very thin so 
that none of the light would pass between the upper and lower surface of the 
object, but I was wondering if I the results that I got where the correct 
ones.

PHIL

---------------------------------------------------


Post a reply to this message

From: Ken
Subject: Re: Transparent Textures
Date: 17 Aug 1999 01:46:03
Message: <37B8F70A.6FC5E11B@pacbell.net>
Philip Bartol wrote:
> 
> I had an idea for a cheat for doing a section of metal decking with holes in
> it using the marble pattern.
> 
> I used a marble pattern for a pigment, did a color_map starting with a rgbt of
> 1 at 0, ended with "DarkSlateGray" at 1 and had a tight transition at around
> 8 so I would get a hard edge between the metal and the open space.
> 
> The problem is that I found that while the texture had open spaces, the solid
> parts of the texture only where on the surface of my test object. I figured
> that since the pigment goes through the object if you cut it, that using a
> transparent color would show the solid portions thorugh the object.
> 
> My metal floor that this is going to be used on is very thin, so I could still
> use it as is, just make the thickness of the cylinder I'm using very thin so
> that none of the light would pass between the upper and lower surface of the
> object, but I was wondering if I the results that I got where the correct
> ones.
> 
> PHIL
> 
> ---------------------------------------------------

 Your results are correct because the marble pattern exists in 3d. If you
want to have your open areas travel through any thickness of material try
instead the gradient pattern. With enough turbulence added in i.e. <0.3,0,0>
you can come close to the marble pattern and still have the clear areas below
the surface too.

  You can get more info on the "perlin noise" function which is used for the
marble pattern and others used in Pov at:

 http://freespace.virgin.net/hugo.elias/

-- 
Ken Tyler

See my 700+ Povray and 3D Rendering and Raytracing Links at:
http://home.pacbell.net/tylereng/index.html


Post a reply to this message

From: Nieminen Mika
Subject: Re: Transparent Textures
Date: 17 Aug 1999 02:28:59
Message: <37b9012b@news.povray.org>
Philip Bartol <phi### [at] concentricnet> wrote:
: The problem is that I found that while the texture had open spaces, the solid 
: parts of the texture only where on the surface of my test object. I figured 
: that since the pigment goes through the object if you cut it, that using a 
: transparent color would show the solid portions thorugh the object.

  This is a common misunderstanding among beginners.
  Povray doesn't handle solid objects, only surfaces. (The keyword 'hollow'
has _nothing_ to do with this.) Povray handles mathematical surfaces, which
are infinitely thin.
  Think about it: Povray calculates the intersection between the viewing ray
and the object (eg. a sphere). Ok, now it has the coordinates in space for
the intersection point. Now what? It calculates the color of that point for
that specific object. It finds that it's transparent. What should it do?
It traces another ray from there. This ray hits the sphere again at the
other side. The result is that we see a hollow sphere.
  Calculating the intersection between the viewing ray and a texture pattern
in space is quite difficult. Media does this, and you can try doing something
with it, but expect _slow_ rendering times and not-so-good results.

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Philip Bartol
Subject: Re: Transparent Textures
Date: 17 Aug 1999 03:36:27
Message: <37b910fb@news.povray.org>
In article <37b9012b@news.povray.org>, Nieminen Mika <war### [at] cctutfi> wrote:
>Philip Bartol <phi### [at] concentricnet> wrote:
>: The problem is that I found that while the texture had open spaces, the solid
> 
>: parts of the texture only where on the surface of my test object. I figured 
>: that since the pigment goes through the object if you cut it, that using a 
>: transparent color would show the solid portions thorugh the object.
>
>  This is a common misunderstanding among beginners.
>  Povray doesn't handle solid objects, only surfaces. (The keyword 'hollow'
>has _nothing_ to do with this.) Povray handles mathematical surfaces, which
>are infinitely thin.
>  Think about it: Povray calculates the intersection between the viewing ray
>and the object (eg. a sphere). Ok, now it has the coordinates in space for
>the intersection point. Now what? It calculates the color of that point for
>that specific object. It finds that it's transparent. What should it do?
>It traces another ray from there. This ray hits the sphere again at the
>other side. The result is that we see a hollow sphere.
>  Calculating the intersection between the viewing ray and a texture pattern
>in space is quite difficult. Media does this, and you can try doing something
>with it, but expect _slow_ rendering times and not-so-good results.

I'll macro out a union of boxes and clip them to the shape I want before 
messing with Media for a solid grill...

I just didn't figure that the pigment (which the manual describes as solid 
through the object) is only calculated on the surfaces, but it does make 
sence. Someone should re-phrase that portion of the documentation.

For my purposes I can go with a very thin object, as I had said, so that it 
appears solid through. I don't plan on rendering any scenes so close to that 
surface that the detail will be needed...

Thanks

PHIL

---------------------------------------------------


Post a reply to this message

From: Nieminen Mika
Subject: Re: Transparent Textures
Date: 17 Aug 1999 10:47:04
Message: <37b975e8@news.povray.org>
Philip Bartol <phi### [at] concentricnet> wrote:
: I just didn't figure that the pigment (which the manual describes as solid 
: through the object) is only calculated on the surfaces, but it does make 
: sence. Someone should re-phrase that portion of the documentation.

  The sentence is right: The pigment is truely 3D.
  The problem is not that the pigment is calculated on the surface. The
problem is that you only have the surface, nothing else. You can't calculate
the pigment inside the object because you only have the surface.

  If you make many nested objects, be careful with your max_trace_level

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Chris Huff
Subject: Re: Transparent Textures
Date: 17 Aug 1999 19:48:01
Message: <37B9F4DB.3CEFF02B@compuserve.com>
Actually, there is no difference between gradient x and marble, other
than the fact that marble has a different default waveform, and will
only give stripes along one axis.


Post a reply to this message

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