On May 15, 2:59 am, String <sterling.ud...@googlemail.com> wrote: > On May 14, 6:12 pm, Mark Murphy <mmur...@commonsware.com> wrote: > > >http://idunnolol.com/android/drawables.html > > Thanks for this link. Hadn't seen that one before. > > > Your syntax may work just as is. > > Unfortunately, it doesn't. I thought it looked plausible too, but > naturally I tried it (along with a host of other variations) before > posting here. A call to BitmapFactory.decodeResource(resources, > R.drawable.name2) returns null with every XML syntax I've tried, > including the one from my original post. > > So, has anyone gotten this to work? > >
<bitmap> tag defines BitmapDrawable so you can call: BitmapDrawable bd = (BitmapDrawable) res.getDrawable(R.drawable.name2) and then: bd.getBitmap() IIRC pskink -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en