realbasic-games
[Top] [All Lists]

Re: trimesh particles demo, version 2

To: REALbasic Games <realbasic-games at lists dot realsoftware dot com>
Subject: Re: trimesh particles demo, version 2
From: Frank Condello <developer at chaoticbox dot com>
Date: Fri, 3 Nov 2006 18:17:48 -0500
Delivered-to: listarchive at realsoftware dot com
Delivered-to: realbasic-games at lists dot realsoftware dot com
References: <20061103180030 dot C198C160F8EC at lists dot realsoftware dot com> <7c5830a4e0f061f0b69ad13723343003 at 98115 dot net>
On 3-Nov-06, at 5:42 PM, Craig Macomber wrote:

Translucent parts and fog don't interact very well; we had a similar
problem in Renegades, though it was far less noticeable and wasn't a
serious problem.

The fog does not seem to be a large problem, but it is noticeable. The sky color is a large problem tho.

However, another possibility is that you haven't correctly defined the
alpha channel...  are you sure your texture mask is mostly black (and
entirely black where you want the particles to be fully transparent)?

I'm just using the same images from the original demo and I think they are correct. I think I can get it to work ok by having a black sky and a skybox of the correct color.

It's the fog and/or specular highlights causing these artifacts. The sky has nothing to do with it (well, other than it also controls the fog colour). The fact that things work with black fog/sky is just a quirk of the colour math: 0 + 0 = 0.

As Joe mentioned, alpha channels need to be premultiplied to work properly in Quesa. I'll hand out Jeff's standard link: <http:// www.geocities.com/jeffq_cnet/Meshwork/alphamask.html>. A search of the mailing list archives will reveal more information.

*BUT* even properly premultiplied textures won't work in fog (unless it's black) or when a specular highlight is applied (as they are by default). This is an artifact of Quesa's monolithic transparent texture blending, which is a legacy of QuickDraw 3D. There is no fix other than hacking the Quesa library itself to use more reasonable blend modes for your situation.

Frank.
<http://developer.chaoticbox.com/>
<http://macgameblog.com/>


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


From  Fri 3 Nov 2006 21:48:15 -0600
Return-Path: <realbasic-games-bounces at lists dot realsoftware dot com>
X-Original-To: listarchive at realsoftware dot com
Delivered-To: listarchive at realsoftware dot com
Received: by xmail.realsoftware.com (Postfix, from userid 1037)
        id 225A3FDA314; Fri,  3 Nov 2006 20:48:26 -0800 (PST)
X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on realxserve.local
X-Spam-Level: X-Spam-Status: No, score=-1.6 required=4.5 tests=AWL,BAYES_00,NO_REAL_NAME autolearn=no version=3.1.1
Received: from lists.realsoftware.com (lists.realsoftware.com [209.198.132.125])
        by xmail.realsoftware.com (Postfix) with ESMTP id 2E3D2FDA30E;
        Fri,  3 Nov 2006 20:48:23 -0800 (PST)
Received: from lists.realsoftware.com (localhost [127.0.0.1])
        by lists.realsoftware.com (Postfix) with ESMTP
        id F1AE616125A5; Fri,  3 Nov 2006 22:47:53 -0600 (CST)
X-Original-To: realbasic-games at lists dot realsoftware dot com
Delivered-To: realbasic-games at lists dot realsoftware dot com
Received: from mail.verex.com (mail.verex.com [66.116.103.197])
        by lists.realsoftware.com (Postfix) with ESMTP id 55D8C1612592
        for <realbasic-games at lists dot realsoftware dot com>;
        Fri,  3 Nov 2006 22:47:51 -0600 (CST)
Received: from [66.116.103.197] (localhost [127.0.0.1])
        by mail.verex.com (Postfix) with SMTP id D937068B80C
        for <realbasic-games at lists dot realsoftware dot com>;
        Fri,  3 Nov 2006 21:48:15 -0700 (MST)
Date: Fri, 3 Nov 2006 21:48:15 -0600
From: joe at strout dot net
To: realbasic-games at lists dot realsoftware dot com
In-Reply-To: <F8FB6243-3A4C-4855-983C-583ACEE242A6 at chaoticbox dot com>
X-Mailer: VerEx Email Gateway
Content-type: text/plain;
Content-transfer-encoding: 7bit
Message-Id: <20061104044815 dot D937068B80C at mail dot verex dot com>
Subject: Re: trimesh particles demo, version 2
X-BeenThere: realbasic-games at lists dot realsoftware dot com
X-Mailman-Version: 2.1.2
Precedence: list
Reply-To: REALbasic Games <realbasic-games at lists dot realsoftware dot com>
Sender: realbasic-games-bounces at lists dot realsoftware dot com
Errors-To: realbasic-games-bounces at lists dot realsoftware dot com

On Nov 03, 2006, at 23:17 UTC, Frank Condello wrote:

*BUT* even properly premultiplied textures won't work in fog (unless it's black) or when a specular highlight is applied (as they are by default). This is an artifact of Quesa's monolithic transparent texture blending, which is a legacy of QuickDraw 3D.

But note that the specular highlight problem is easily fixed by setting
NullShader = True on your particles, which is what you'd normally want
for particles anyway.

Best,
- Joe


--
Joe Strout -- joe at strout dot net
Verified Express, LLC     "Making the Internet a Better Place"
http://www.verex.com/

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>