图片合成

private Bitmap onCompositeImages(){   
        Bitmap bmp = null;   
        
        bmp = Bitmap.createBitmap(srcBitmap.getWidth(), 
		srcBitmap.getHeight(), srcBitmap.getConfig());   
        final Paint paint = new Paint();   
        final Canvas canvas = new Canvas(bmp);   
        canvas.drawBitmap(srcBitmap, 0, 0, paint);         
            
        paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.MULTIPLY));   
        canvas.drawBitmap(dstBitmap, 0, 0, paint);   
           
        return bmp;   
}   

你可能感兴趣的:(图片合成)