Android Question JPCT-AE Load3DS on transparent background

peacemaker

Expert
Licensed User
Longtime User
Is it possible to show .3DS model transparently ?
Over my panel with picture.
 

DonManfred

Expert
Licensed User
Longtime User
Is it possible to load .3ds at all? I don´t know a way. Even don´t know this Extension....
 
Upvote 0

peacemaker

Expert
Licensed User
Longtime User
Yes, this JPCT-AE lib has a sample "load3ds" that load .3ds file (of 3D-Max editor software) with .jpg texture file and rotating on the screen. But over the blue color.
 
Upvote 0

peacemaker

Expert
Licensed User
Longtime User
For the background color is used
B4X:
Dim SkyColor As JpctRGBColor
SkyColor.Initialize3(153, 217, 234, 0)
It can be initialized with only exact R, G, B components.
But how to make it transparent ?
 
Upvote 0

wonder

Expert
Licensed User
Longtime User
End result:
upload_2017-11-8_19-19-12.png



Manifest:
B4X:
SetActivityAttribute(main, android:theme, @android:style/Theme.Translucent.NoTitleBar)


Activity_Create:
B4X:
'Makes Activity transparent
Activity.Color = Colors.Transparent


jPCT Initialization:
B4X:
'Makes the view transparent
JpctView.Initialize1("Jpct", 1, True, Jpct.RENDER_CONTINUOUSLY, False, Jpct.TRANSLUCENT)

'Makes the sky transparent
SkyColor.Initialize3(0, 0, 0, 0)

'Solves the problem of black being displayed as transparent (see below)
MyTexture.Initialize2(File.OpenInput(File.DirAssets, "my_texture.png"), True)


Black as transparent problem:
http://www.jpct.net/forum2/index.php?topic=4766.01
http://www.jpct.net/forum2/index.php?topic=4710.0
 
Last edited:
Upvote 0
Top