www.jpct.net

jPCT-AE - a 3d engine for Android => Bugs => Topic started by: rainfalls on June 01, 2012, 01:01:04 am

Title: Object3D.mergeObjects and setTransparency
Post by: rainfalls on June 01, 2012, 01:01:04 am
I'm not sure if this is a bug or intended. With this code:

Code: [Select]
mesh_0.setTransparency(255);
mesh_0.setTexture("tex_with_alpha");
mesh_1.setTexture("tex_solid");
Object3D mesh = Object3D.mergeObjects(mesh_0, mesh_1);

Then the mesh_0 part loses the alpha setting (100% transparency --> black).

Sorry if this has been discussed before.
(Tested on Sony Ericsson Xperia Play.)
Title: Re: Object3D.mergeObjects and setTransparency
Post by: zammbi on June 01, 2012, 01:19:08 am
I believe you need to call "setTransparency;" again on the merged object to say to use the alpha channel.
If you don't want the whole object transparent then you will need to keep them separate.
Title: Re: Object3D.mergeObjects and setTransparency
Post by: EgonOlsen on June 01, 2012, 08:53:45 am
Transparency is per Object. It's intended and not a bug.