get TextureName from loaded 3ds

Started by hika00, August 03, 2012, 10:11:01 AM

Previous topic - Next topic

hika00

Object3D[] temp = Loader.load3DS( is , 1.0f );
for( int i = 0, j = temp.length ; i < j ; i++ ){
   log( temp.getName() + ":"+ _textureManager.getNameByID( temp.getPolygonManager().getPolygonTexture(0) ) );
}
--------------------------------------------------------
box1:--dummy--
box2:--dummy--
box3:--dummy--
....

How can I get the right Texture names?

hika00

and...

log( temp.getName() + ":"+ temp.getTranslation().toString() );
-----------------------------------------------------
box1:[0.0, 0.0, 0.0]
box2:[0.0, 0.0, 0.0]
box3:[0.0, 0.0, 0.0]
...

How can I get th right position?

hika00

log( temp.getName() + ":"+ temp.getTransformedCenter().toString() ); :)

EgonOlsen

Quote from: hika00 on August 03, 2012, 10:11:01 AM
log( temp.getName() + ":"+ _textureManager.getNameByID( temp.getPolygonManager().getPolygonTexture(0) ) );
Looks fine at first glance unless the object has no proper textures. Can you post the log output from loading the object?