I have an application with an embedded drawable 48x48 pixel at 71,12 pixels/inch
I load the same image via a stream to a webserver, then load that stream
Get the current density of the screen and set the drawable to that density
DisplayMetrics metrics = new DisplayMetrics();
getWindowManager().getDefaultDisplay().getMetrics(metrics);
int density = metrics.densityDpi
myDrawable.setDensity(densityDpi);