Author Topic: get TextureName from loaded 3ds  (Read 2142 times)

Offline hika00

  • byte
  • *
  • Posts: 7
    • View Profile
get TextureName from loaded 3ds
« on: August 03, 2012, 10:11:01 am »
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?

Offline hika00

  • byte
  • *
  • Posts: 7
    • View Profile
Re: get TextureName from loaded 3ds
« Reply #1 on: August 03, 2012, 10:27:01 am »
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?

Offline hika00

  • byte
  • *
  • Posts: 7
    • View Profile
Re: get TextureName from loaded 3ds
« Reply #2 on: August 03, 2012, 10:37:52 am »
log( temp.getName() + ":"+ temp.getTransformedCenter().toString() ); :)

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: get TextureName from loaded 3ds
« Reply #3 on: August 03, 2012, 02:39:06 pm »
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?