Code example for BitmapDrawable

Methods: drawsetBounds

0
    } 
 
    public static Bitmap resizeBitmap(Bitmap bmp,int w,int h) {
        Bitmap result=Bitmap.createBitmap(w,h,Bitmap.Config.RGB_565);
        Canvas canvas=new Canvas(result);
        BitmapDrawable drawable=new BitmapDrawable(bmp);
        drawable.setBounds(0,0,w,h);
        drawable.draw(canvas);
        return result;
    }  
 
    public float[] getEyeDistance(){ 
        return mEyesDistance;
    } 
    public PointF[] getEyePoint(){
        return mEyesMidPts;
    } 
 
    public static final void drawImageToCanvas(Canvas canvas, Drawable mask, 
            FaceCatcher face){
Experience pair programming with AI  Get Codota for Java