Skip to main content
zulin
Participating Frequently
Sep 5, 2012 11:21 AM UTC
Question

How can I play video on Android using native player?

Is there a way to tell android to open my mp4 (either in assets or on external sd)  with it's native video player?

Just like if I tap this (mp4) file in any android file manager.

reasons:

1 - I don't want to write my own player (especially when I have one built in)

2 - I assume playback experience may be better when playing large file NOT through the AIR.

So, can I  make something like "NativeApplication.execute(pathToMp4)"?

This topic is closed to new replies. Start a new post to keep the conversation going.

16 replies

sinious
Legend
Sep 5, 2012 4:06 PM UTC

Have you tried a StageWebView? I haven't touched Android much lately but I do a lot of iOS apps and iOS gives standard (quicktime/html5-esque) controls to any mp4 played directly in a StageWebView, with a fullscreen button. Just note on Android after AIR 3.0 device acceleration must be enabled.

Translate
zulin
zulinAuthor
Participating Frequently
Sep 6, 2012 9:35 AM UTC

Yes I tried. Maybe in iOS it is handled better but on Asus tablet I only got video controls displayed and sound was playing (while there was no video). This is not codec problem because I used mp4 recorded by device and its native player played it correctly. Same results (sound played, no video though) I got when tried to open same html in native browser (so maybe this has something to do with it).

It's sad I have to dance with playback and controls in flash rather than using native ...

Translate
Colin Holgate
Inspiring
Sep 6, 2012 11:22 AM UTC

If you are using Flex, make sure you have set the stage background to be transparent.

Translate