I am using the answer to help me get out of the memory problem. I resolve all the drawables to the Asset folder Insert IOException (Reference Reference, String Filename), Public Assignment - GetResources () getAssets () .; InputStream buffer = new BufferedInputStream ((asset.open ("DOSUABLE /" + + FILENAME + ".PNG"))); Bitmap bitmap = bitmapfinder Aodestream (buffer); Return a new bitmap drawer (reference .greatresource (), bitmap); }
My question is how do I use this function under my operation? Is there an example of this work?
How do I use this function under my activity?
OK, as is the function public static
bus:
className.getAssetImage (this, yourDrawableName);
ex:
Where mDrawable
is drawable
return the image.
No comments:
Post a Comment