xamarin.ios - MonoTouch: proper way to handle ReceiveMemoryWarning -
i have monotouch app out in wild dies mprotect errno 12 (out of memory), , seems @ least 1 receivememorywarning notification beforehand.
i'm wondering right way respond is. there 2 types of things app free: opengl textures , managed memory.
my questions are:
opengl textures: deleting opengl textures help?
managed memory: can't free directly, can null out references it. enough?
gc.collect: should call gc.collect() @ end of handler? gc.collect immediately, or schedule collection future?
anything else can/should in response this?
i ran while in app using opengl. me, memory leak.
[dllimport("/system/library/frameworks/coregraphics.framework/coregraphics")] public static extern void cgdataproviderrelease(intptr provider);
and after call gl.teximage2d.....
you need call cgdataproviderrelease(data.handle);
now being said, might want @ this:
Comments
Post a Comment