2

I have problem with drawing a Pixmap on a texture with Samsung GT-N5100.

public class PixmapHelper{

    static Pixmap mapHelper;
    static Pixmap miniObject;


    public static void Initialize()
    {
       mapHelper=AssetLoader.GetPixmap(Settings.TEX_MAP_OBJECTS);
       miniObject=new PixMap(4,4,Pixmap.Format.RGB888);
       mapHelper.setBlending(Pixmap.Blending.None);
       miniObject.setBlending(Pixmap.Blending.None);
    }

    public static void Draw(TextureRegion textureRegion,Texture dstTexture,int dstX,int dstY)
    {
        miniObject.drawPixmap(mapHelper,0,0,textureRegion.getRegionX(),textureRegion.getRegionY(),
        textureRegion.getRegionWidth (),textureRegion.getRegionHeight());
        dstTexture.draw(miniObject,dstX,dstY);
    }
}

When I start the project on desktop or Samsung N-GT8000 all worked(draw) correctly. If I start it on GT-N5100, nothing is drawn on dstTexture. dstTexture have Height=800 Width=600.

Can you help me to resolve this problem please?

Balder
  • 8,623
  • 4
  • 39
  • 61
Rinnion
  • 89
  • 1
  • 9
  • Do you ever draw your texture to the screen? Does the problematic device support OpenGL 2.0 and textures that aren't powers of 2? – Kevin Workman Mar 25 '14 at 13:36
  • Thanks i resolved this. I used OpenGL 2.0 texture gets from FrameBuffer(FrameBuffer not powerd 2) it's need me to avoid redraw maps all time. – Rinnion Mar 26 '14 at 07:01

1 Answers1

0

Problem be at this "miniObject=new PixMap(4,4,Pixmap.Format.RGB888);" my dstTexture has format RGBA8888 but PixMap RGB888 when i changed it to RBA8888 all work.

Rinnion
  • 89
  • 1
  • 9