get Bitmap Default Original Options - Android Graphics

Android examples for Graphics:Bitmap Option

Description

get Bitmap Default Original Options

Demo Code


//package com.java2s;

import android.graphics.Bitmap;

import android.graphics.BitmapFactory;
import android.graphics.BitmapFactory.Options;

public class Main {
    @SuppressWarnings("deprecation")
    public static Options getDefaultOriginalOptions() {
        BitmapFactory.Options options = new BitmapFactory.Options();

        options.inSampleSize = 1;/*from ww w. j av a 2 s  .  c om*/
        options.inJustDecodeBounds = false;
        options.inPreferredConfig = Bitmap.Config.RGB_565;
        options.inPurgeable = true;
        options.inInputShareable = true;

        return options;
    }
}

Related Tutorials