html5-video

Get audio from an html5 video

旧城冷巷雨未停 提交于 2019-12-02 17:46:54
Is it possible to get the audio from an mp4 or webm video element in HTML5? I'm trying to use https://github.com/corbanbrook/dsp.js to calculate FFTs for audio, however, I only have the mp4 and webm videos. Not sure if this answers your question but you can run the audio of the video through the Web Audio API node graph. The code below can be demonstrated by changing the gain and filter parameters. I only tested this on Chrome. <!DOCTYPE html> <meta charset="UTF-8"> <title></title> <body> </body> <script> var video = document.createElement("video"); video.setAttribute("src", "ourMovie.mov");

Screenshot of video element using phantomjs

為{幸葍}努か 提交于 2019-12-02 17:17:43
问题 I am trying to take a screenshot of page with a video element using phantomjs. Currently, i set the time of the video ahead to some desired seconds (i.e. 60). Then I use page.render(output). However, the screenshot created is always black. Can anyone see the problem or verify if what Im trying to do is possible? 回答1: Running the features.js example (using modernizr.js), you will see >phantomjs.exe examples\features.js Detected features (using Modernizr 2.0.6): Supported: touch

Correct mime type for .mp4

Deadly 提交于 2019-12-02 16:32:26
I have two applications as mentioned below: Admin application through which I am able to upload a .mp4 file to the server. I am trying to download the .mp4 using mobile application in iPad. The Admin application is made by using asp.net 4.0 and SQL Server, IIS7. The Mobile application is made of asp.net mvc3, jquerymobile, HTML5. As of now I have added mime type video/mp4 for .mp4 in IIS7 mime types section. When I am trying to download the .mp4 file in iPad I am seeing a dark black screen with cross arrow on it. Can anyone please help me to resolve the issue. Please tell me whether the mime

Video stream through Websocket to <video> tag

允我心安 提交于 2019-12-02 16:25:55
I use Node.js to stream via Websocket a realtime webm video to a webpage which will play it in a tag. The following is the code from both the server and the client: SERVER: var io = require('./libs/socket.io').listen(8080, {log:false}); var fs = require('fs'); io.sockets.on('connection', function (socket) { console.log('sono entrato in connection'); var readStream = fs.createReadStream("video.webm"); socket.on('VIDEO_STREAM_REQ', function (req) { console.log(req); readStream.addListener('data', function(data) { socket.emit('VS',data); }); }); }); CLIENT: <html> <body> <video id="v" autoplay> <

Html5 video recording and upload?

☆樱花仙子☆ 提交于 2019-12-02 16:24:46
I need to create an app that can record video using a webcam or mobile camera (it needs to be cross platform). So far I have written a small proof of concept using webrtc getusermedia. It can record the video and playback but I am not sure how to get the file to upload back to the server. Here is a link to this sample http://jsfiddle.net/3FfUP/ And the javascript code: (function ($) { window.URL = window.URL || window.webkitURL; navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.msGetUserMedia; var video = document

HTML5 solution to upload a webcam/camera video stream to server

给你一囗甜甜゛ 提交于 2019-12-02 16:23:35
Using getUserMedia I can capture video stream from client's webcam/camera. And using video tag I can show it on client's browser. Code: <video autoplay></video> <script type="text/javascript"> window.URL = window.URL || window.webkitURL; navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.msGetUserMedia; var video = $('video')[0]; var failed = function(e) { console.log('Denied!', e); }; if( navigator.getUserMedia ) { navigator.getUserMedia( {video: true, audio: true}, function( stream ) { video.src = window.URL

Pause the stream returned by getUserMedia

青春壹個敷衍的年華 提交于 2019-12-02 16:11:30
问题 I have channelled the stream returned by getUserMedia to <video> element in html page, video now can be seen in that element. The problem is that if I pause the video from the controls of video element, and then resume after x seconds, then the timer being shown in video element will jump to pauseTime + x seconds. I guess this is because the stream is not getting paused as we pause the playback in video element. If so can we pause the stream too. 回答1: That is the very thing of Streams, you

How can I play a local video in my IPython notebook?

我只是一个虾纸丫 提交于 2019-12-02 15:51:06
I've got a local video file (an .avi, but could be converted) that I would like to show a client (ie it is private and can't be published to the web), but I can't figure out how to play it in IPython notebook. After a little Googling it seems that maybe the HTML5 video tag is the way to go, but I don't know any html and can't get it to play. Any thoughts on how I can embed this? Viktor Kerkez ( updated 2019, removed unnecessarily costly method ) Just do: from IPython.display import Video Video("test.mp4") Or if you want to use the HTML element: from IPython.display import HTML HTML(""" <video

iPad html5 video with NO controls?

冷暖自知 提交于 2019-12-02 15:37:33
This has been killing me all day, but I am not sure how to get a html5 video player working without the native controls. I want no controls what-so-ever but if I don't include them, the video does not seem to want to play, even if I add some javascript below trying to force it to play, it works on iPhone and multiple browsers, but not iPad which is strange, any idea? Here's some markup if it helps! <video src="video.mp4" id="video" poster="image.jpg" onclick="this.play();"/></video> $('#video').click(function(){ document.getElementById('video').play(); }); net.uk.sweet iOS does not support the

How to stop playing a <video> element and return it back to its original state?

流过昼夜 提交于 2019-12-02 15:06:54
问题 I was wondering how I could go about resetting a video that was playing or paused to its original state where it isn't playing? I know you can pause the video, but what I really want is for the video to return to it's initial state. This means it would show the poster image if specified and would start from the beginning if the user hit play again. I looked at all the documentation and I can only find ways to pause. 回答1: The easiest way I have been able to find is to reset the source of the