How do I use Video plugin on mobile devices

  • > Thanks for the info. That's pretty unfortunate. The reason I'm using video is because it would take a lot of sprites to create every single animation I have. Video is the only logical choice to make it less of a memory hog. When I play it on mobile via LAN or export out to it, it'll play the audio after touching the screen. I would think that if it's set to autoplay or having the system start it, it should just play.

    >

    > I really don't get it. Maybe a dev can answer this? I know I'm new and all, but I was really hoping to take full advantage of the feature-set and getting the video plugin to handle the task.

    >

    i just noticed in the r222 release they fixed the video bug with capitals! i'll test this later today.

    not really the "fix" we're looking for, but at least the video names will look cleaner with capitals back in them

    and as far as i know, you always need that first touch on mobile, i also managed to get audio but no video with a first touch (the video is in a seperate layout with autostart and events making sure it autostarts, and they work fine on the desktop or web versions.)

    i also used buttons to move the video to another layer, set it's size to max screen size, or original size, visibility, global, loading from another layout, went all over google.. oh, and different mp4 / webm converts, wth or without streaming option, different bitrate (1000-2500 tested) (VP9 converts crash on my end, so i can't try that yet) and i bet i missed a few more things, but basicly, no video at all. sometimes audio.

    i need the video's myself for pre-rendered animations, basicly any fullscreen animation that's too detailed or too heavy for C2 to handle.

    png sequences work fantastic but eat a lot of data. and they're all story-based, so i can't rely on the player to always have a stable connection.

    i'm not completely sure what the filesize limit are, what's IntelXDk's limit? Google / ios seem to have 2gb now? with the ability to download additional data.

    png sequences would still easily fit it these numbers are true.

    help? Ashley ?

    Right, I have the same experience. I hate that the video has to be touched in order to play. My game is an audio visualizer that needs to play to introduce the game, and then play different videos based on a random event. If the player has to touch the video first, it ruins the entire experience. When I test on mobile over Wi-FI or export, it doesn't even show the video at all.

    There has to be some way to call video to auto play regardless. My video is only 1,8mb, whereas a sprite sheet of the same animation is 120 frames long and is 27mb....and I have multiple animations that need to be played. No way to decrease the frames because it won't sync perfectly with the audio. Maybe I'll just have to redesign the entire thing.

    help? Ashley ? indeed

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I'm not aware of any bugs in the video plugin right now (other than the one we just fixed in the latest beta), so if you find any please report them as usual following all the guidelines. However video is a bit tricky due to the browser support situation:

    • generally Chrome can play any format, but Chromium (NW.js, Crosswalk) cannot play H.264 (because it's a patented format and Google only have a license for Chrome). VP8 should work. You have to encode these videos yourself, so make sure you get the encoder settings right.
    • iOS can only play H.264, not VP8, VP9 or Theora. You can add multiple sources to the video plugin and it will fall back as appropriate. So to guarantee playback on all platforms you need VP8 and H.264.
    • on mobile (both Chrome for Android and iOS Safari) you can only start media playback in a touch event. This applies to music as well. Construct 2 uses the same workaround for video as it does for music: if you try to play when you're not allowed to, it queues it up to be played in the next touch event when it will be allowed. However this means you must touch the screen at least once for there to be any chance that video can play. If you're just starting up the app and watching it, it won't be able to play until you touch it.
  • I'm not aware of any bugs in the video plugin right now (other than the one we just fixed in the latest beta), so if you find any please report them as usual following all the guidelines. However video is a bit tricky due to the browser support situation:

    - generally Chrome can play any format, but Chromium (NW.js, Crosswalk) cannot play H.264 (because it's a patented format and Google only have a license for Chrome). VP8 should work. You have to encode these videos yourself, so make sure you get the encoder settings right.

    - iOS can only play H.264, not VP8, VP9 or Theora. You can add multiple sources to the video plugin and it will fall back as appropriate. So to guarantee playback on all platforms you need VP8 and H.264.

    - on mobile (both Chrome for Android and iOS Safari) you can only start media playback in a touch event. This applies to music as well. Construct 2 uses the same workaround for video as it does for music: if you try to play when you're not allowed to, it queues it up to be played in the next touch event when it will be allowed. However this means you must touch the screen at least once for there to be any chance that video can play. If you're just starting up the app and watching it, it won't be able to play until you touch it.

    Thanks, Ashley for the info. I have three encoded files that I bring in: mp4, webm, ogv. Even in the case of the encoded VP8 webm file, the audio from the video plays, not the video itself. There's a little black box of the video that pops up, but the actual visuals in it don't play when I test over LAN. You can only hear the audio and see a black box.

    I don't know how to attach a .capx file but I can leave this link to DL from my Drive account for someone to test and see if they get the same result as me. https://drive.google.com/file/d/0B9UIax ... sp=sharing I just saved the file as a capx.. not sure if it keeps the video in it when I share it..

  • > I'm not aware of any bugs in the video plugin right now (other than the one we just fixed in the latest beta), so if you find any please report them as usual following all the guidelines. However video is a bit tricky due to the browser support situation:

    >

    > - generally Chrome can play any format, but Chromium (NW.js, Crosswalk) cannot play H.264 (because it's a patented format and Google only have a license for Chrome). VP8 should work. You have to encode these videos yourself, so make sure you get the encoder settings right.

    > - iOS can only play H.264, not VP8, VP9 or Theora. You can add multiple sources to the video plugin and it will fall back as appropriate. So to guarantee playback on all platforms you need VP8 and H.264.

    > - on mobile (both Chrome for Android and iOS Safari) you can only start media playback in a touch event. This applies to music as well. Construct 2 uses the same workaround for video as it does for music: if you try to play when you're not allowed to, it queues it up to be played in the next touch event when it will be allowed. However this means you must touch the screen at least once for there to be any chance that video can play. If you're just starting up the app and watching it, it won't be able to play until you touch it.

    >

    Thanks, Ashley for the info. I have three encoded files that I bring in: mp4, webm, ogv. Even in the case of the encoded VP8 webm file, the audio from the video plays, not the video itself. There's a little black box of the video that pops up, but the actual visuals in it don't play when I test over LAN. You can only hear the audio and see a black box.

    I don't know how to attach a .capx file but I can leave this link to DL from my Drive account for someone to test and see if they get the same result as me. https://drive.google.com/file/d/0B9UIax ... sp=sharing I just saved the file as a capx.. not sure if it keeps the video in it when I share it..

    I GOT THEM PLAYING, YES!

    i simply deleted the .mp4 and Theora sources from the project (and make sure when you export to the same folder, old files -with older names- are still there)

    next, i loaded up a Webm vp8, resolution set to 1280x720 (in my 640x360 game!) variable bitrate of 1200 and Vorbis audio.

    the video plays perfectly fine after touching "new game" from the layout before that. so it basicly plays just fine without the need for another touch in this particular layout, so i bet you could find a way sorting your problem out as well <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    thanks again Ashley !, you guys already provide so much with C2 in general plus all the effort on your community.

    really amazing job you guys doing! <3

  • >

    > > I'm not aware of any bugs in the video plugin right now (other than the one we just fixed in the latest beta), so if you find any please report them as usual following all the guidelines. However video is a bit tricky due to the browser support situation:

    > >

    > > - generally Chrome can play any format, but Chromium (NW.js, Crosswalk) cannot play H.264 (because it's a patented format and Google only have a license for Chrome). VP8 should work. You have to encode these videos yourself, so make sure you get the encoder settings right.

    > > - iOS can only play H.264, not VP8, VP9 or Theora. You can add multiple sources to the video plugin and it will fall back as appropriate. So to guarantee playback on all platforms you need VP8 and H.264.

    > > - on mobile (both Chrome for Android and iOS Safari) you can only start media playback in a touch event. This applies to music as well. Construct 2 uses the same workaround for video as it does for music: if you try to play when you're not allowed to, it queues it up to be played in the next touch event when it will be allowed. However this means you must touch the screen at least once for there to be any chance that video can play. If you're just starting up the app and watching it, it won't be able to play until you touch it.

    > >

    >

    > Thanks, Ashley for the info. I have three encoded files that I bring in: mp4, webm, ogv. Even in the case of the encoded VP8 webm file, the audio from the video plays, not the video itself. There's a little black box of the video that pops up, but the actual visuals in it don't play when I test over LAN. You can only hear the audio and see a black box.

    >

    > I don't know how to attach a .capx file but I can leave this link to DL from my Drive account for someone to test and see if they get the same result as me. https://drive.google.com/file/d/0B9UIax ... sp=sharing I just saved the file as a capx.. not sure if it keeps the video in it when I share it..

    >

    I GOT THEM PLAYING, YES!

    i simply deleted the .mp4 and Theora sources from the project (and make sure when you export to the same folder, old files -with older names- are still there)

    next, i loaded up a Webm vp8, resolution set to 1280x720 (in my 640x360 game!) variable bitrate of 1200 and Vorbis audio.

    the video plays perfectly fine after touching "new game" from the layout before that. so it basicly plays just fine without the need for another touch in this particular layout, so i bet you could find a way sorting your problem out as well <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    thanks again Ashley !, you guys already provide so much with C2 in general plus all the effort on your community.

    really amazing job you guys doing! <3

    I'm glad you got it to work! Unfortunately, I've done the same thing and can't get the video to show over LAN or on export. I've basically given up on it. I just see no way of making it work.

  • Does each video clip need a touch event to begin on mobile?

    Can the user tap a button to begin the first video then have another video automatically play after the first video ends without a touch event?

  • Yes, every video play needs a touch to start.

  • Yes, every video play needs a touch to start.

    Ashley ... is there any way that this could ever be changed in the future and have the video auto play when called? Or is it something that will never work on mobile?

  • Bleenx

    > Yes, every video play needs a touch to start.

    >

    Ashley ... is there any way that this could ever be changed in the future and have the video auto play when called? Or is it something that will never work on mobile?

    AFAIAA this is a mobile limitation.

    Maybe the following link will help:

    https://developer.apple.com/library/safari/documentation/AudioVideo/Conceptual/Using_HTML5_Audio_Video/Device-SpecificConsiderations/Device-SpecificConsiderations.html

  • This has been necessary on all mobile browsers for several years now, so I doubt it will change.

  • Thanks zenox98 and The way I have this game set up is reliant on the video to play without touch; otherwise, it doesn't make sense. I'll just have to find another way to do things, such as using sprites and different graphics altogether. Oh well...no biggie.

  • Hello all,

    I am facing the same issues with my project. Though after a extensive search i found this link here:

    github.com/gomobile/sample-html5-web-video-playback

    I haven't tested it yet, as i don't have enough knowledge to work in java script or HTML5. If anyone knows gets the video to work with this, please reply.

    I hope this will help.

  • Hi there!

    I got a feedback from my client telling me that the videos of an app I developed for them are not working specifically on their tablets.

    Videos play normally on Windows (NW.js), mobile phones, but won't play in their tablet devices.

    They sent me the specs:

    Multilaser M7S

    CPU: Dual Core 2x 1.2 GHz

    RAM: 512 MB DDR III

    Android: 4.4

    Screen resolution: 800 x 480

    There are two videos in the app and both are encoded in the three formats required.

    Any idea of what's happening?

  • any help on this ?

  • Cok? still not help?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)