www.jpct.net

jPCT-AE - a 3d engine for Android => Support => Topic started by: Irony on May 17, 2014, 08:55:17 pm

Title: Image not visible
Post by: Irony on May 17, 2014, 08:55:17 pm
Hey Egon,
do you have any idea why I don't see the title image?

This in ondrawFrame()

      if (man.state==SM.STATE_TITLE) {
         if (!tm.containsTexture("title1")) {
            Log.d("draw", "load title");
            tm.addTexture("title1", new Texture(am.open("title1.png"), true));
            tm.preWarm(fb);
         }
         fb.blit(tm.getTexture("title1"), 0, 0, 100, 100, 512, 512, 200, 200, 100, false);
      }



Log:
05-17 20:52:56.903: D/draw(9336): load title
05-17 20:52:59.456: D/draw(9336): draw title
05-17 20:52:59.476: D/draw(9336): draw title
05-17 20:52:59.496: D/draw(9336): draw title
...


Title: Re: Image not visible
Post by: EgonOlsen on May 18, 2014, 02:28:02 pm
Blitting along won't help, because the blitting will be delayed until the next "real" render, which never happens in this case. Just create an empty dummy world and insert the usual renderScene/draw/display sequence after the blitting.
Title: Re: Image not visible
Post by: Irony on May 18, 2014, 06:17:15 pm
Damnit. Should have figured this out before, would have saved me a lot of head scratching... ... Thanks!