문제

When loading in device only white image display,When loading emulator the images are broken

sample Code:

// this.mCamera = new Camera(0, 0, 480,320);

    final Engine engine = new Engine(new EngineOptions(true, 

ScreenOrientation.LANDSCAPE, new FillResolutionPolicy(), this.mCamera));

this.mCamera = new Camera(0, 0, CAMERA_WIDTH, CAMERA_HEIGHT);

    final Engine engine = new Engine(new EngineOptions(true, 

ScreenOrientation.LANDSCAPE, new FillResolutionPolicy(), this.mCamera));

//----

this.mTexture = new Texture(2048, 512, TextureOptions.BILINEAR_PREMULTIPLYALPHA); this.mbgTextureRegion = TextureRegionFactory.createFromAsset(this.mTexture, this, "gfx/bg.png", 0, 0);

        this.mEngine.getTextureManager().loadTexture(this.mTexture);

whats maximum Texture size will use in andengine. I used 2048 , its make problem, Plz help ?

도움이 되었습니까?

해결책

The maximum texture size depends on the device. Only newer devices support 2048x2048. In my experience 1024x1024 are better supported as of today.

It is also possible to find max size at runtime: How can I find the maximum texture size for different phones?

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top