1

I'm developing a 2D game for Android and i'm using the framework which has been told in the book which named Beginning Android Games by Mario Zechner.So my framework is well designed and using OpenGL 1.1.It's similar to libgdx.

When i put my textures adjacent each other in my 2d surface,there are some spaces size as 1 px.But this problem only occur on my tablet.There aren't a problem like this on my phone.It's like in this picture:

my problem

What can be the problem?I can't fix it from one week.

UPDATE:

      batcher.beginBatch(Assets.ground);
      konum =(int) (dunya.myMan.position.x/500);
      for(int i=konum;i<8+konum;i++)
      batcher.drawSprite(500*i, 61, 500, 122, Assets.groundRegion);

      batcher.endBatch();
4

1 に答える 1

0

クワッドを非整数値で変換している可能性があります。これにより、テクスチャが中心から外れてサンプリングされ、そのようなアーティファクトが発生する可能性があります。

すべての 2D 変換がスクリーン ピクセルと一致していることを確認すれば、もう問題は発生しないと思います。

于 2012-06-03T20:58:32.137 に答える