# SDL2 Android, AdMob support

**URL:** <https://discourse.libsdl.org/t/sdl2-android-admob-support/19237>\
**Category:** SDL Development\
**Created:** [November 15, 2012, 10:52am UTC](https://discourse.libsdl.org/t/sdl2-android-admob-support/19237 "2012-11-15T10:52:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Giorgos\_Sarris](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/g/f0a364/32.png) [@Giorgos\_Sarris](https://discourse.libsdl.org/u/Giorgos_Sarris)\
**Post date:** [November 15, 2012, 10:52am UTC](https://discourse.libsdl.org/t/sdl2-android-admob-support/19237/1 "2012-11-15T10:52:00Z")

</div>

Hi,

Is AdMob (google ads) support integrated in SDL2?  
I cannot find it on my latest clone but I see some references on the net.  
SDL\_android.h should have these functions:

extern DECLSPEC int SDLCALL SDL\_ANDROID\_GetAdvertisementParams(int \*  
visible, SDL\_Rect \* position);  
extern DECLSPEC int SDLCALL SDL\_ANDROID\_SetAdvertisementParams(int  
visible, int left, int top);

If its not official yet, can you please check/integrate it, it would help  
a lot of us.

thanks,  
Giorgos

---

<div class="post-metadata">

**Author:** ![Sik\_the\_hedgehog](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/s/db5fbb/32.png) [@Sik\_the\_hedgehog](https://discourse.libsdl.org/u/Sik_the_hedgehog)\
**Post date:** [November 15, 2012, 4:11pm UTC](https://discourse.libsdl.org/t/sdl2-android-admob-support/19237/2 "2012-11-15T16:11:59Z")

</div>

Huh, is that really within the scope of SDL? Shouldn’t it be handled separately?

What I don’t know though is if SDL allows external Android functions  
like that to be linked in. If not, then SDL should probably provide  
some support for such a thing (which would be useful for way more than  
just this, of course).

2012/11/15 Giorgos Sarris :\> Hi,

> Is AdMob (google ads) support integrated in SDL2?  
> I cannot find it on my latest clone but I see some references on the net.  
> SDL\_android.h should have these functions:
> 
> extern DECLSPEC int SDLCALL SDL\_ANDROID\_GetAdvertisementParams(int \*  
> visible, SDL\_Rect \* position);  
> extern DECLSPEC int SDLCALL SDL\_ANDROID\_SetAdvertisementParams(int visible,  
> int left, int top);
> 
> If its not official yet, can you please check/integrate it, it would help a  
> lot of us.
> 
> thanks,  
> Giorgos
> 
> * * *
> 
> SDL mailing list  
> SDL at [lists.libsdl.org](http://lists.libsdl.org)  
> [http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org](http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org)

---

<div class="post-metadata">

**Author:** ![Vittorio\_Giovara](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/v/57b2e6/32.png) [@Vittorio\_Giovara](https://discourse.libsdl.org/u/Vittorio_Giovara)\
**Post date:** [November 16, 2012, 9:11am UTC](https://discourse.libsdl.org/t/sdl2-android-admob-support/19237/3 "2012-11-16T09:11:13Z")

</div>

Um, patches welcome I guess?  
Oh don’t forget iAd integration too…

ok seriously, I find it quite outside the scope of SDL  
VittorioOn Thu, Nov 15, 2012 at 11:52 AM, Giorgos Sarris wrote:

> Hi,
> 
> Is AdMob (google ads) support integrated in SDL2?  
> I cannot find it on my latest clone but I see some references on the net.  
> \*  
> SDL\_android.h\* should have these functions:
> 
> _extern DECLSPEC int SDLCALL SDL\_ANDROID\_GetAdvertisementParams(int \*  
> visible, SDL\_Rect \* position);_\*  
> \*_extern DECLSPEC int SDLCALL SDL\_ANDROID\_SetAdvertisementParams(int  
> visible, int left, int top);_
> 
> If its not official yet, can you please check/integrate it, it would help  
> a lot of us.
> 
> thanks,  
> Giorgos
> 
> * * *
> 
> SDL mailing list  
> SDL at [lists.libsdl.org](http://lists.libsdl.org)  
> [http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org](http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org)
