Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Object failed to be textured in Android?

Author
Message
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 4th Mar 2016 18:05 Edited at: 4th Mar 2016 18:13
Hello everybody.

I tried to texture an object in Android.
But somehow the objects still appears untextured.
But it was textured correctly when run on Windows.

i did convert all the textures so that they are square images. But the texture still doesn't show.

Or is it a problem with LoadObjectWithChildren( ) command?

Anybody know what is going on?
Here's the attached model, and the code I used to load it.

Attachments

Login to view attachments
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 4th Mar 2016 18:46
You don't load the image used to texture the object, nor do you have a SetObjectTexture command, so of course the object will be untextured.

AGK isn't like DBPro, where the texture is automatically applied, you have to do it yourself.
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 4th Mar 2016 18:52 Edited at: 4th Mar 2016 18:56
But I did load the images, see these lines above:

LoadImage(6,"Causeweneedmorehotelstages/t007.bmp")
LoadImage(7,"Causeweneedmorehotelstages/t004.bmp")
LoadImage(8,"Causeweneedmorehotelstages/t010.bmp")
LoadImage(9,"Causeweneedmorehotelstages/t004.bmp")
LoadImage(10,"Causeweneedmorehotelstages/t005.bmp")
LoadImage(11,"Causeweneedmorehotelstages/t006.bmp")
LoadImage(12,"Causeweneedmorehotelstages/t008.bmp")
LoadImage(13,"Causeweneedmorehotelstages/t009.bmp")
LoadImage(14,"Causeweneedmorehotelstages/t010.bmp")

The object was textured using SetObjectMeshImage to texture each mesh contained in the model with different images.

It appears correct on WIndows, but untextured on Android.
hakimfullmetal
9
Years of Service
User Offline
Joined: 17th Feb 2015
Location:
Posted: 4th Mar 2016 19:13
Hey I got it fixed.

Actually AppGameKit can't texture 3D object using .bmp image formats.

Converting them to .png solves the problem.

Thanks guys.
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 4th Mar 2016 20:17
!) I don't know how I missed ALL those image commands! i feel silly!
2) Glad you got it working with PNG's!

Login to post a reply

Server time is: 2024-09-29 11:31:44
Your offset time is: 2024-09-29 11:31:44