I have a png file that is transparent outside which is used as an icon image somewhere in my UI; I'd like for the user to be able to specify a different color for it at runtime (as in the image on the left below, assuming I have the android icon); or a different "background" image (Image on the right below, suppose the icon is a shape combining a circle and a triangle). I read this post which used ColorFilter to set all the white color pixels to another color in code; but it doesn't allow me to change the "background" of the icon. I guess I probably can do this with a ClipDrawable but I can't figure out how.