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.
Bitmap2つのインスタンス間でオブジェクトを渡す方法はActivity?
Bitmap
Activity
BitmapはParcelableを実装しているため、いつでもインテントで渡すことができます。
Intent intent = new Intent(this, YourNewActivity.class); intent.putExtra("BitmapImage", bitmap);
もう一方の端でそれを取得します
Bitmap bitmap = (Bitmap) intent.getParcelableExtra("BitmapImage");