html5-video

Safari not loading HTML5 video in Rails app

江枫思渺然 提交于 2019-12-10 02:36:58
问题 I have a Rails app I'm trying to play an HTML5 video from using the following markup: Doesn't work: <video controls poster="http://lvh.me:3000/assets/videos/myvideo.png"> <source src="http://lvh.me:3000/assets/images/videos/myvideo.mp4" type="video/mp4"> <source src="http://lvh.me:3000/assets/images/videos/myvideo.webm" type="video/webm"> <source src="http://lvh.me:3000/assets/images/videos/myvideo.ogv" type="video/ogg"> </video> On Safari, the video says "Loading..." but never plays,

Styling HTML5 Video Controls

给你一囗甜甜゛ 提交于 2019-12-10 02:00:59
问题 I can't seem to get the styling correct on the video player controls as nothing seems to align correctly. I've tried wrapping the items in divs, and lis but things just don't seem to move or align correctly. Any suggestions? What i have so far: http://jsfiddle.net/pp6Wn/ var vid, playbtn, seekslider, curtimetext, durtimetext, mutebtn, volumeslider, fullscreenbtn; function intializePlayer() { // Set object references vid = document.getElementById("my_video"); playbtn = document.getElementById(

InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable

对着背影说爱祢 提交于 2019-12-10 01:26:42
问题 The following works in Chrome but not Firefox: var myVideo = document.getElementById('myVideo') myVideo.currentTime = 570 <video id="myVideo" controls> <source src="myVideo.mp4" type="video/mp4"> </video> In Firefox it says InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable for line 2. 回答1: That error occurs when the object, in this case the video, hasn't loaded enough to be able to set the currentTime and skip forward. You'd have to wait until the

How to perfectly sync two or more html5 video tags?

两盒软妹~` 提交于 2019-12-10 01:21:18
问题 Is there any way to have two or more (preferably three) html5 < video > tags playing simultaneously and to be in perfect sync. If I have let's say three tiles of one video and I want them to appear in browser as one big video. They need to be perfectly synchronized. Without even smallest visual/vertical hint that they are tiled. Unfortunately I cannot use MediaController because it is not supported well enough. I've tried some workouts, including canvases, but I still get visual

Is there a way to add support for HLS in desktop Chrome/HTML5 player?

孤人 提交于 2019-12-10 00:52:14
问题 Desktop Chrome and FF do not support HLS. I know there is a plugin available to add HLS support to flash. Is there such plugin or technique available to enhance HTML5 on browsers which dont have HLS support yet? 回答1: Not only it is possible, but it's been done numerous times. There are several open and closed source solutions available. A quick github search gave me this one. https://github.com/RReverser/mpegts EDIT: New/better option just released http://engineering.dailymotion.com

Transparent webm video displays solid background color on Chrome for Android 68 on android 9.0

风流意气都作罢 提交于 2019-12-09 23:51:57
问题 I have simple page with a webm video with transparent background. It works well on desktop. It works well on Chrome for Android version 66 on my android phone running android 9.0 too. But after upgrading to Chrome for Android version 68, the video displays solid background color. I checked the console and no error or warning found. Chrome 66: ]2]2 Chrome 68: I tested on Chrome for Android version 68 on other phones which running Android 7 and it works well. Does anyone know why this happens

autoplay muted video iOS 11.2

非 Y 不嫁゛ 提交于 2019-12-09 19:39:19
问题 I am currently working on a page with videos on it. Since iOS 11.2, it seems they disabled autoplay muted inlineplaying completely without a user gesture. Has anyone experienced this issue too? This all wouldn't be such a mess if there would be a possibilty to check whether it is possible to playinline or not. But like this it results in a new hack by UA sniffing. Edit: I have seen that i am have missed something. Autoplay is working, but trying to video.play() a muted inline video is not

PHP HTML5 compatible MP4 video using FFMPEG

徘徊边缘 提交于 2019-12-09 18:31:46
问题 Hi I am using FFMPEG to convert the uploaded video with PHP. echo "conversion exercise started...<br/><br/>"; /* looping through all files in the directory */ if ($handle = opendir('assets/uploaded_videos')) { while (false !== ($entry = readdir($handle))) { /* filtering the desired extensions */ if ($entry != "." && $entry != ".." && in_array(substr($entry, strrpos($entry, '.')), array(".wmv", ".mpg", ".mpeg", ".flv", ".ogg", ".mp4"))) { $filename = substr($entry, 0, strrpos($entry, '.')); //

Space after html5's video tag

落爺英雄遲暮 提交于 2019-12-09 16:06:35
问题 I have a html5's video tag, it seems that there is a 5px space between video and its container div element. If I put font-size: 0 in the container element ( #video-container ), the space disappears. I know this is a problem of display: inline-block , but I have no elements with that. Also, trying the solutions of opening tags next the previous closing, didn't delete the space. http://jsfiddle.net/g9t71mg6/ html, body { margin: 0; padding: 0; width: 100%; height: 100%; } #wrapper { width: 100%

Calculate .m4s segment file suffix in HTML5 video streaming when user seeks to another time

随声附和 提交于 2019-12-09 14:51:46
问题 I have created fixed length segments for a long MP4 video using Mp4Box. Mp4Box creates a meta info file mv_init.mp4 and segments like mv_1.m4s , mv_2.m4s , … I stream the video using HTML5 Media Source Extensions and the streaming is working properly. The problem is that I am unable to utilize time seeking feature of my HTML5 player . When a user uses the seekbar to seek to another time point, I need to fetch the correct segment file ( mv_{number}.m4s ) for that currentTime . For example: