Androidcoder
Androidcoder

Reputation: 4679

Do video interstitial ads use significant heap space, possibly causing heap crashes

I haven't been able to find anything addressing heap space used by interstitial ads.

I use high-res graphics in my game which brings my heap space requirement close to 256M, and I'm concerned that video interstitials may overrun that on the player end. The 'test ad' you get for an interstitial ad is static, but real interstitial ads can be a video segment.

I don't want to screw up my admob stats testing a lot with live ads that won't get clicked in hopes of getting some video interstitials to study heap changes, and google recommends testing only with the test ads anyway (by flagging your particular device for testing). Do interstitials share the app heap space and is it significant? How much does a video interstitial use?

Upvotes: 1

Views: 58

Answers (1)

Jim
Jim

Reputation: 10278

Interstitial ads should take over the screen. I expect the ad provider to ensure it does not exceed the heap (and if it does, if you have good crash reports you will know - you will see crashes from ad displays).

Since your app is not on the screen, it should dealloc memory just as it would when switching to any other screen. Admob and other providers have callbacks and controllers to handling this appropriately.

From the "test first" perspective, consider that even if you test one or a few of their ads, they are always seeking new advertisers and switching out ads. If you don't trust them to handle that properly without you testing it now, then you should not trust them in general.

EDIT:

And I assume you mean "OutOfMemoryError" by "heap crash"

Upvotes: 1

Related Questions