Code example for Bitmap

Methods: getHeightgetPixelsgetWidth

0
    public int getWidth(Bitmap bmp) { return bmp.getWidth(); }
    public int getHeight(Bitmap bmp) { return bmp.getHeight(); }
 
    public void getPixels(Bitmap bmp, int[] pixels)
    { 
        int w = bmp.getWidth();
        int h = bmp.getHeight();
        bmp.getPixels(pixels, 0, w, 0, 0, w, h);
    } 
 
    public void close(Bitmap bmp)
    { 
        bmp.recycle();
    } 
} 
Experience pair programming with AI  Get Codota for Java