[Native Ad Video] Can I control the native ad always show video?

213 views
Skip to first unread message

wanm...@gmail.com

unread,
Oct 4, 2022, 7:31:59 PM10/4/22
to Google Mobile Ads SDK Developers
Hi,

    Now I implement the native ads with MediaView in my app.

    I found that the ad show the main image even nativeAd.getMediaContent().hasVideoContent() return true.

   What can I do to show the video in the native ads when nativeAd.getMediaContent().hasVideoContent() return true?

  Thanks very much

Mobile Ads SDK Forum Advisor

unread,
Oct 5, 2022, 2:42:34 PM10/5/22
to wanm...@gmail.com, google-adm...@googlegroups.com
Hello,

Thank you for reaching out to us. Let me do the best I can to assist you in this.

With regard to your concern, please note that when the MediaView mediaContent property is set with a MediaContent instance:
  • If a video asset is available, it's buffered and starts playing inside the MediaView. You can tell if a video asset is available by checking hasVideoContent().
  • If the ad does not contain a video asset, the mainImage asset is downloaded and placed inside the MediaView instead.
As per always showing native video ad, you may do this directly on your Ad unit ID itself through AdMob UI. You will just need to check the Video under Media type settings. You may want to check this HC article for creating your native ad unit.

Regards,
Google Logo
Teejay Wennie
Mobile Ads SDK Team
 

 

ref:_00D1U1174p._5004Q2exRpV:ref
Reply all
Reply to author
Forward
0 new messages