Hi Frederic,
On Mon, 2004-11-22 at 04:34, Frederic Devillers wrote:
> Hello.
>
> I am trying to change the GL state (backface culling, blending,...) ,
> for a whole sub-graph.
>
> (I found the ChunkMaterial / MaterialChunk names a bit confusing, but I
> think that I now understand the chunks. quite.)
>
> I made a first version, with a traversal, to test backface culling
> activation. It works, but I have to add a PolygonChunk to all the
> Material instances in the sub-graph.
>
> So I tried another version, with a MaterialGroup as a main node for the
> sub-graph, and it fails. Isn't a MaterialGroup a GL state modificator
> for all his childs ?
it is, but not in the way you expect it to be. ;)
The MaterialGroup totally replaces the Materials of the Geometries below
it. So if you set a ChunkMaterial that only contains a PolygonChunk, the
Geometries will be rendered without materials, textures, etc., only with
the PolygonChunk.
Currently you can't override only part of the state from within the
graph, that's part of my scheduled rewrite of the RenderAction, you will
have to use the traversal strategy.
Yours
Dirk
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users