0
我有麻煩顯示到Android的大圖像。我試圖通過這個custom- scrollable-image-view來完成這項工作。7165X786大尺寸圖像無法在實際設備中顯示(平板電腦)
我已經在我的課程中使用了完整視圖,並使用了7165 * 786大小的圖像。它只有1.11MB的圖像。我能夠在bluestack中運行此代碼並查看其中的圖像,但無法在實際設備中加載。
bmLargeImage = BitmapFactory.decodeResource(getResources(),
R.drawable.imagewithout);
bmlotusImage1 = BitmapFactory.decodeResource(getResources(),
R.drawable.lotus);
我在onDraw方法中使用了同樣的畫布,如下所示。
canvas.drawBitmap(bmLargeImage, scrollRect, displayRect, paint);
canvas.drawBitmap(bmlotusImage1, 45 - newScrollRectX,
255 - newScrollRectY, paint);
我能不能在我的實際設備顯示bmlargeImage我可以看到設備的蓮花圖像,但不是大的。
我應該不得不解碼或縮放圖像或其他任何東西才能讓它在真實設備中顯示?