Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
かなり大きい (10 MB) のフルスクリーンの背景ビットマップをトリミングする必要がありますが、別のビットマップを割り当てる余裕がない場合があります。
プロセスで別のビットマップを作成せずに、ビットマップ自体をトリミングする方法があるのだろうか。
Bitmap cropped = Bitmap.createBitmap(sourceBitmap, x, y, w, h)
この関数は完璧ですが、問題はメモリを割り当てることです。
高さを 25% トリミングするだけです。