问题
I'm trying to draw a video frame on canvas. It works well on desktops, but there are issues on Chrome on Android devices.
Please see the example: http://buildar.com/static/drawimage/minimal.html
I've tested it on various Android devices and the only that's working on is Android 5 with Crosswalk (Cordova app).
After removing the Crosswalk or trying on other Android version, the drawImage function doesn't work.
I've found several related Chromium bug reports, but according to them, the issue seems to be fixed https://code.google.com/p/chromium/issues/detail?id=501208
What can be the reason for it to work only on Android 5 + Crosswalk - if Crosswalk fully replaces the device Webview, wouldn't it work on older Android versions as well?
Is there any other way of capturing the video frame? I'm currently researching converting the video to <img>
, alternative video plugin, using Webgl, taking video screenshot, but haven't discovered anything so far that could possibly work.
来源:https://stackoverflow.com/questions/34580825/html5-video-and-canvas-drawimage-function-on-android-and-crosswalk