Android Question VideoView functionality

RJB

Active Member
Licensed User
Longtime User
I am trying to play video in a repeating loop. Code as follows:
Code: Copy
Sub Globals
    Dim vv As VideoView
End Sub
 
Sub Activity_Create(FirstTime As Boolean)
 
    vv.Initialize("vv")
    vv.MediaControllerEnabled = False
    Activity.AddView(vv, 10dip, 10dip, 250dip, 250dip)
    vv.LoadVideo(File.DirRootExternal & "/Movies", "IMAG0018.MOV")
    vv.play
 
End Sub
    
Sub vv_Complete
'        vv.LoadVideo(File.DirRootExternal & "/Movies", "IMAG0018.MOV")
        vv.Play
End Sub

I get the following results

Android 2: Plays and repeats but with no audio on the repeats. There is also a short break between the end and restarting. The audio is OK if the file is re-loaded in vv_complete.

Android 4 on 10inch tablet: Plays audio and sometimes plays video after several seconds of a blank screen. Does not repeat unless the file is re-loaded in vv_complete. There is a short break between repeats

Android 4 on an MK802 on TV screen: Plays video and audio. Repeats only if the file is reloaded in vv_complete. There is a short break between repeats.

Any ideas on 1) whether the file should have to be re-loaded each time
2) what's happening with the audio on Android 2
3) what's happening with the video on the 10inch tablet
4) how to make a seamless repeat, without the break between repeats
Thanks
 
Have you tried to set the position to 0 (first pause the playback)?
Hi,
Yes. And 'bringtofront', 'enabled', 'invalidate', 'requestfocus', etc. in fact anything that I though might have even the remotest chance of affecting it!
I really am at a loss as to what to try next.
I've even added hardware acceleration to the manifest, just in case that had any effect but it doesn't.
Any other ideas?
Thanks
 
Upvote 0
Seems like you will need to reload the file. VideoView type is a wrapper over the native VideoView object though there isn't much that can be done.
Regarding the non-display of video on the 10inch Android 4 tablet:
Touching the back button on screen briefly displays the video before the window closes. Then restarting it from the menu item on the tablet displays the video straight away.
Also when the mediacontrollerenabled is set to true, touching the image area brings up the video and the controls.
Does any of that help?
 
Upvote 0
Regarding the non-display of video on the 10inch Android 4 tablet:
Touching the back button on screen briefly displays the video before the window closes. Then restarting it from the menu item on the tablet displays the video straight away.
Also when the mediacontrollerenabled is set to true, touching the image area brings up the video and the controls.
Does any of that help?
Any help anyone?
 
Upvote 0
Back
Top