POV-Ray : Newsgroups : povray.general : The Alpha Channel : Re: The Alpha Channel Server Time
9 Aug 2024 09:01:50 EDT (-0400)
  Re: The Alpha Channel  
From: Rune
Date: 30 Sep 2000 17:54:30
Message: <39d66116@news.povray.org>
"Peter J. Holzer" wrote:
> > I can't figure out if it is more correct to divide by the
> > Alpha before or after Alpha is converted to grey-scale
>
> After. The alpha value must affect all three channels alike.

After some more experimenting I believe you are right. I also found out that
the method we are talking about is indeed not very good at handling filter
transparency. As the filter value goes towards 1, the colour of the object
in the output-image goes towards black! Of course the not-so-good results
are understandable, since the alpha channel really is not made for filter
transparency.

> If you simply compute every ray twice, you can centralize the change
> at a single point - just before writing the pixel to the file.

But that's a render time increase of 100%!

> If you want to optimize it, you will have to change a few data
> structures and probably lots of code. But then you need to do
> the intersection tests only once per ray, and you may save some
> (or even a lot) of the colour computations, too.

So turning the alpha channel on would maybe not increase render times
considerable when doing it this way...

> The extra data and checks will probably slow down normal
> renders down a bit.

New features such as all the new reflection and refraction options in
MegaPOV don't seem to slow down the rendering at all when not used. Maybe
the new alpha channel feature wouldn't either. But as I said, I don't know
anything about the details here.

Rune
--
\ Include files, tutorials, 3D images, raytracing jokes,
/ The POV Desktop Theme, and The POV-Ray Logo Contest can
\ all be found at http://rsj.mobilixnet.dk (updated September 25)
/ Also visit http://www.povrayusers.org


Post a reply to this message

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