|
From: James W. W. <ja...@wr...> - 2005-01-21 19:10:48
|
Keith Wiley <kw...@cs...> wrote: >On Fri, 21 Jan 2005, Frank Condello wrote: > >> First ensure the alpha in your art is not pre-multiplied (likely >>the case already) then put the sun shape in a display group under a >>fog object with its visibility set to false. This will ensure no >>fog is drawn on the sun, which is typically a desired effect on all >>celestial bodies. Also place a Lambert shader before the sun >>geometry to turn off any potential specular highlights, since they >>may display a similar artifact as fog. > >I have a question on this approach. Is there something inherant >about the display group that is supposed to make this alpha-with-fog >thing work properly, or is that just the way you suggested to make >sure the fog is submitted prior to the sun object? A display group restricts the effect of a style. The idea was to turn off fog for the sun, but not for everything. >I ask because before trying to group the fog with the sun, I quickly >tried submiting a fog turned off just prior to submitting the sun >and then submitting the fog turned on again just after the sun...but >the alpha-fog error is still present. Is that what you would have >expected? Is the display group required? I would not have expected that. I don't know what's going on there. >My problem with the display group is that I can't create it because >I don't have a TQ3Object to add to it. My sun (and all the objects >in my program) are TQ3TriMeshData, not TQ3Object. It won't compile >passing that to Q3Group_AddObject. Same is true for passing a >TQ3FogStyleData to the group. When I do this, Q3Group_AddObject >returns NULL, which is supposed to mean there was an error with >creating the group. You're doing everything in immediate mode? Is there some reason you don't create a TriMesh object from your TQ3TriMeshData? -- James W. Walker, ScriptPerfection Enterprises, Inc. <http://www.write-brain.com/> |