Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

depth testing/alpha blending/draw order




On 14 Jul 2007, at 00:45, Pierre-Olivier Latour wrote:

The wrong assumption people make is that since alpha is 0, then the pixel doesn't exist: that's not correct, the pixel exists, is depth- tested _before_ being drawn, independently of its alpha value. Then if it passes the test, it's drawn but since its alpha is 0, it's just not visible in the color buffer, but this still updates the depth buffer.

That's normal GL behavior, not QC specific.

Thanks very much to everyone for the info. It seems that a common way of getting around this in some other engines is a "alpha_nibble" or discard process which actually disables rendering pixels whose alpha is zero before they get depth_tested.


Is this possible (maybe with a custom CI_filter) inside Quartz Composer? Although this only gives you "on/off" alpha it would
work for what I'm trying to achieve in this exact case.


If I have to sort instead, then can anyone point me to an algorithm that will work with an upstream camera transform? eg I need
a 3d environment node to be able to rotate the iterators which will draw the sprites in any axis. So the drawing order will need to
take into account camera position. I realise this is probably CG101 stuff but I'm really a compositor who only knows enough to annoy proper CG people :)


How do most other 3d engines handle this? Do they have a "sort all objects in this environment by order" function which runs automatically?

Roger
CoreMelt


_______________________________________________ Do not post admin requests to the list. They will be ignored. Quartzcomposer-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/quartzcomposer-dev/email@hidden

This email sent to email@hidden
References: 
 >depth testing: none of them seems to be correct? (From: Roger Bolton <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Karan Lyons <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Roger Bolton <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Karan Lyons <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Roger Bolton <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Roger Bolton <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Karan Lyons <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Roger Bolton <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Allan Schaffer <email@hidden>)
 >Re: depth testing: none of them seems to be correct? (From: Pierre-Olivier Latour <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.