如何在android 2.2及更低版本中使用BitmapRegionDecoder

时间:2012-07-09 06:32:53

标签: android bitmap

我想在我的应用程序中使用BitmapRegionDecoder类来处理非常大的图像。我的应用程序是在Android 2.2(API-8)下开发的,但是BitmapRegionDecoder在Android 2.2及更低版本中不可用,我无法将android 2.2更改为2.3或更高版本,它必须只是android 2.2。那么有没有其他方法可以在我的应用程序中使用BitmapRegionDecoder或任何用于BitmapRegionDecoder的jar文件或者执行BitmapRegionDecoder相同任务的替代jar到BitmapRegionDecoder。

2 个答案:

答案 0 :(得分:0)

我已经在this project的描述中读到,重新创建用于API的BitmapRegionDecoder< 10需要大量使用JNI:

  关于SO,Dianne Hackborn说这不重要。

所以你可以尝试一下,但我担心把它移回到较低版本会太复杂了:(

编辑:我刚刚找到this question on SO,也许这会有所帮助。

答案 1 :(得分:0)

请参阅my other (detailed) answer关于 BitmapRegionDecoderCompat (API 8 +)。

相关问题