如何在 Android 的 Firefox 上为视频创建缩略图
How to create thumbnail for video on Firefox for Android
我正在寻找一种在 Firefox 中为 Android 生成缩略图的方法。我找到了一些关于这个主题的资源:Create thumbnail from video file via file input。但是 Android 的 Firefox 在调用 drawImage(HTMLVideoElement, int, int, int, int)
.
时总是抛出 NS_ERROR_NOT_AVAILABLE
SOpost中附的例子可以重现这个问题:https://codepen.io/aertmann/pen/mAVaPx. The example throws on Firefox for Android while it works on Mac and iOS (afaik it is a downgraded version of Safari). According to https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/drawImage, NS_ERROR_NOT_AVAILABLE
is thrown when resource is not loaded. However, even when I try to do it after loadedmetadata
and loadeddata
or follow another similar question on SO (Firefox: drawImage(video) fails with NS_ERROR_NOT_AVAILABLE: Component is not available)重试直到成功,还是不行
在 Bugzilla 上打开了一个问题:https://bugzilla.mozilla.org/show_bug.cgi?id=1526207
很可能是 firefox 问题
我正在寻找一种在 Firefox 中为 Android 生成缩略图的方法。我找到了一些关于这个主题的资源:Create thumbnail from video file via file input。但是 Android 的 Firefox 在调用 drawImage(HTMLVideoElement, int, int, int, int)
.
NS_ERROR_NOT_AVAILABLE
SOpost中附的例子可以重现这个问题:https://codepen.io/aertmann/pen/mAVaPx. The example throws on Firefox for Android while it works on Mac and iOS (afaik it is a downgraded version of Safari). According to https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/drawImage, NS_ERROR_NOT_AVAILABLE
is thrown when resource is not loaded. However, even when I try to do it after loadedmetadata
and loadeddata
or follow another similar question on SO (Firefox: drawImage(video) fails with NS_ERROR_NOT_AVAILABLE: Component is not available)重试直到成功,还是不行
在 Bugzilla 上打开了一个问题:https://bugzilla.mozilla.org/show_bug.cgi?id=1526207 很可能是 firefox 问题