Hi Thomas,

Thomas Weberndorfer wrote:
> 
> Hello,
> 
> Yes, the problem still exists. I want to change the transparency of a 
> loaded model. For testing, I use the tie.wrl file. This is the method 
> for changing the transparency:
> 
> void setTransparency ( float alpha )
> {
>    MakeTransparentGraphOp *op = new MakeTransparentGraphOp;
>    std::ostringstream str;
>    str << "transparency=" << alpha;
>    op->setParams ( str.str() );
>    // the root node contains a Group-core and has the model attached
>    op->traverse ( root );
>    delete op;
> }
> 
> But this method seems to ignore the alpha-parameter, because the result 
> is always the same. (Even alpha = 0 and alpha = 1 produces the same 
> result. I attached the results.)

Fixed. Well, sort of. It's not totally general for Chunk Materials and will 
override transparency coming from the material, but I hope it's more useful the 
way it is than it was.

Hope it helps

        Dirk

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to