Questions tagged [mp4]
MP4 is a multimedia container format standard with the file extension .mp4. It can be used to store digital audio/video streams, in addition to other multimedia.
3,088
questions
984
votes
31
answers
1.0m
views
How to concatenate two MP4 files using FFmpeg? [closed]
I'm trying to concatenate two mp4 files using ffmpeg. I need this to be an automatic process hence why I chose ffmpeg. I'm converting the two files into .ts files and then concatenating them and ...
227
votes
9
answers
320k
views
Use ffmpeg to add text subtitles [closed]
I am trying to add text subtitles to an .mp4 container using ffmpeg:
ffmpeg -i input.mp4 -i input.srt -map 0.0 -map 0.1 -map 1.0 output.mp4
When I am trying to run this line, it gives me an error :
...
104
votes
1
answer
83k
views
Possible Locations for Sequence/Picture Parameter Set(s) for H.264 Stream
I'm working on a H.264 Decoder and I'm wondering where to find the SPS and PPS. My reference literature tells me that those are NAL Units encoded in the H.264-Stream, but when I look into an example-...
93
votes
2
answers
99k
views
What exactly is Fragmented mp4(fMP4)? How is it different from normal mp4?
Media Source Extension (MSE) needs fragmented mp4 for playback in the browser.
79
votes
2
answers
129k
views
Safari <input type="file" accept="video/*"> ignores mp4 files
I am using an HTML file input like this:
<input type="file" accept="video/*">
to allow my users to upload videos to my site. This works as expected in all modern browsers (only permitting ...
62
votes
10
answers
179k
views
Can I have a video with transparent background using HTML5 video tag?
We filmed a spokesperson on a green screen and have the video files ready in multiple formats.
With Flash we could use the wmode transparent within the param and embed tags, but is there something ...
61
votes
1
answer
65k
views
ffmpeg settings for converting to mp4 and ogg for HTML5 video [closed]
Despite all the hype, in reality the HTML5 video tag has a bit of a problem. In order to use it and for it to be cross browser compatible, you have to include more than one format of the video. To ...
59
votes
5
answers
265k
views
Bootstrap 3 - Responsive mp4-video
I tried to find a good solution on the bootstrap site but I didn't get an answer to this yet. I think I can't be the only one struggling with this, but I couldn't find anything that helped me.
I'm ...
59
votes
4
answers
89k
views
How to output fragmented mp4 with ffmpeg?
ffmpeg -i infile.avi out.mp4 outputs non-fragmented MP4.
How do I obtain fragmented mp4?
Update
A fragmented mp4 file is internally divided into several back-to-back chunks or MPEG-4 movie fragments....
55
votes
7
answers
138k
views
How to add a MOOV atom in a mp4 video file [closed]
I am working on live device to server streaming in android. I am able to send data in bytes on server but when I play that file during recording on server VLC say that MOOV atom not found. After a lot ...
54
votes
3
answers
85k
views
MP4 File Format Specification [closed]
I am writing some code to parse MP4 files ...
Is there a free source to get documentation on the MP4 File Format Specification. So far I have only found an ISO document which I would need to purchase ...
53
votes
2
answers
41k
views
Fastest way to extract a specific frame from a video (PHP/ffmpeg/anything)
I have a web page, which (among other things) needs to extract a specific frame from a user-uploaded video. The user seeks to a particular part of a .mp4 in the player, then clicks a button, and an ...
49
votes
3
answers
326k
views
How do I embed a mp4 movie into my html?
I have a blog section on my site that has the TinyMce editor. I want to embed a video when I post a blog and it's just spitting out the code. I have added the <embed> tag on my output script.
...
45
votes
6
answers
138k
views
How to play .mp4 video in videoview in android?
I am working on a video player application, I want to play .mp4 video in the native video view. I am not able to play video using a URL. I am getting the error "Sorry this video cannot be played&...
45
votes
6
answers
25k
views
Unable to host MP4 files on Azure web site
I am hosting a static website on a reserved web site in Azure (It is PaaS, no access to OS/IIS). I am trying to add some .mp4 videos but when I click on the links I get
The resource you are looking ...
41
votes
6
answers
126k
views
what is the codec for mp4 videos in python OpenCV
fourcc = cv2.cv.CV_FOURCC(*'XVID')
The above line is used for avi video. In the same fashion, which codec do we use for mp4 videos in Ubuntu?
40
votes
2
answers
49k
views
Extracting frames from MP4/FLV?
I know it's possible with FFMPEG, but what to do if I have a partial file (like without the beginning and the end). Is is possible to extract some frames from it?
40
votes
14
answers
112k
views
<video> plays in other browsers, but not Safari
We have an MP4 video on our site; it plays fine in IE9+, Firefox, Chrome, and Chrome on mac. However, on Safari, the video doesn't play at all - it does trigger a "stalled" event and then nothing ...
39
votes
9
answers
69k
views
Anyone familiar with mp4 data structure?
Where in the mp4 file structure is the duration of it?
38
votes
3
answers
60k
views
Post processing in ffmpeg to move 'moov atom' in MP4 files (qt-faststart)
Is it possible to run ffmpeg from the command line which will either place the 'moov atom' metadata in the beginning of the MP4 file or run the qt-faststart as a post processing operation in ffmpeg so ...
37
votes
4
answers
46k
views
Live streaming through MP4
I am working on an online TV service. One of the goals is for the video to be played without any additional browser plug-ins (except for Flash).
I decided to use MP4, because it is supported by the ...
33
votes
4
answers
20k
views
Adding watermark bitmap over video in android: 4.3's MediaMuxer or ffmpeg
Here is my scenario:
Download an avi movie from the web
Open a bitmap resource
Overlay this bitmap at the bottom of the movie on all frames in the background
Save the video on extarnal storage
The ...
31
votes
4
answers
68k
views
Using php to output an mp4 video
Ok basically I have a project that requires that videos are hidden from the users while still able to see them (by using php). here's what i got so far:
The video.php file has this:
<?php
$ch = ...
30
votes
2
answers
70k
views
Converting an HLS (m3u8) to MP4 [closed]
Can anyone advise on how to construct an MP4 file from an HLS stream (the reverse of what you usually want)? Say I have the m3u8 - is there a straightforward way of getting a single MP4 using FFMPEG ...
30
votes
3
answers
100k
views
Repairing a Corrupt MP4 Video File [closed]
I have an MP4 video that I took with a Flip camera. The camera froze up while I was stopping the recorder and now the video appears corrupt. I can still download it off the camera, but it won’t play. ...
28
votes
3
answers
38k
views
How to load videos from assets folder? (to play them with VideoView)
I need to open a mp4 video from the assets folder and play it with VideoView.
I tryed with these two options, but none of them works....
mVideoView.setVideoPath("file:///android_asset/videos.mp4");
...
28
votes
10
answers
77k
views
How to get video duration from mp4, wmv, flv, mov videos
Alright. Actually i need mostly the mp4 format. But if it is possible to get for other types as well that would be nice. I just need to read the duration of the file. How can i do that with C# 4.0 ?
...
27
votes
6
answers
100k
views
convert from jpg to mp4 by ffmpeg
I have 320 jpg(320x574) images which I have recorded them with 2004 fps. I want to make a .mp4 video of them. I have run below codes in cmd (win7) and it just make a video of jpg number 320 and if I ...
27
votes
3
answers
50k
views
Another: Force Chrome to fully buffer mp4 video
I've seen a few threads about this, but with no answers, so I thought I'd add another to the grave yard of polluted youtube related pages.
I've got a 100MB mp4 video that needs to be fully downloaded ...
27
votes
2
answers
56k
views
m4a mp4 file format what's the difference or are they the same?
I've looked and can't seem to find a concrete answer.
My client wants to play sound clips on his website, currently he has over 2000 clips which are in m4a format.
A lot of the audio players I have ...
27
votes
3
answers
59k
views
Save continuous RTSP stream to 5-10 minute long mp4 files
How can I keep the flow (protocol rtsp, codec h264) in file (container mp4)? That is, on inputting an endless stream (with CCTV camera), and the output files in mp4 format size of 5-10 minutes of ...
27
votes
4
answers
54k
views
Convert compressed swf to mp4
I'm looking for a batch script to convert swf to mp4, lossless. I tried using both ffmpeg and handbrake, but apparently swf is compressed and I can't convert them this way.
ffmpeg -i input -c:v ...
27
votes
2
answers
16k
views
Is there a downside to putting the MOOV atom at the beginning of an MP4 file?
I see tons of questions about relocating the moov atom from the end of a MP4 video container to the beginning, to make the video "web optimized" or easier to stream. It seems like most tools require ...
26
votes
3
answers
60k
views
what is difference between mp4 and mpegts?
Recently I had a task to convert the file format to mp4 and stream it. I have used ffmpeg as the transcoding tool. The MP4 file doesn't get streamed over the http protocol [have used php cgi wrapper], ...
26
votes
8
answers
52k
views
how play mp4 video in google colab
I have a video.mp4 in content/video.mp4
if I wanted to play the video in google colab without downloading , ¿what code I should use to open a kind of video player in my jupyter notebook?
26
votes
2
answers
36k
views
How do I add a custom thumbnail to a .mp4 file using ffmpeg?
I am trying to find the proper ffmpeg command to add a .png or .jpg image to a .mp4 video as a thumbnail. The command will eventually automatically be executed by a C# program.
This is what I have ...
25
votes
3
answers
35k
views
How to remove or edit Exif from mp4 video?
I recorded a Full HD video with Samsung Galaxy II, when I uploaded it to YouTube I found that it turned to 90 degrees like Portrait layout 1080x1920 NOT 1920x1080.
I found the cause of the problem:
...
25
votes
2
answers
25k
views
converting all the mp4 audio files in a folder to mp3 using ffmpeg [duplicate]
how can I convert all of the mp4 files in a given folder to mp3 using ffmpeg.
Almost all of the links I have seen on google is all about converting mp4 video to mp3.
I can do this via VLC player but I ...
25
votes
1
answer
23k
views
Fastest way to add -movflags +faststart to an MP4 using FFMPEG, leaving everything else as-is
I want to add -movflags +faststart to an mp4 file. Basically that is all I want to do, nothing else should be changed. I am using ffmpeg.
What's the fastest way to do this? Do I have to re-encode the ...
25
votes
3
answers
14k
views
Pre-Load or Pre-Buffer .mp4 video in android app development
I am building an app that is successfully displaying an MP4 video file onButtonClick. I want to pre-buffer or preload the video's URI (remote url) so that it doesn't delay the playing of the video ...
24
votes
2
answers
23k
views
FFMPEG: Transmux mpegts to mp4 gives error: muxer does not support non seekable output
When piping mpegts to ffmpeg, which should convert it to mp4 and pipe to stdout, ffmpeg says: "muxer does not support non seekable output".
After a lot of research I came to the conclusion that mp4 ...
24
votes
2
answers
24k
views
VLC: How to Create a Genuine MP4 (not M4V) File?
At "File -> Convert/Stream" menu item, applying "Video - H.264 + mp3 (mp4)" profile will result in a file in m4v format instead of mp4!
Now, changing the extension from m4v to mp4 will work on some ...
24
votes
1
answer
1k
views
Save real time video recording to sd-card using Local Socket in Android - Video not playable
Trying to capture a video and save it to sd card in Mp4/3gp formats using local socket. Being able to write bytes by bytes to sd card but the video file is not playable.I have gone through many ...
23
votes
7
answers
23k
views
Unable to play MP4 video file from mainBundle
So I'm trying to play a simple intro animation video file that I've dragged into my project in XCode and therefore should be able to play from my mainBundle, right?
With this code:
NSURL *urlString ...
22
votes
2
answers
58k
views
Python OpenCV video.get(cv2.CAP_PROP_FPS) returns 0.0 FPS
This is my video
This is the script to find fps:
import cv2
if __name__ == '__main__' :
video = cv2.VideoCapture("test.mp4");
# Find OpenCV version
(major_ver, minor_ver, subminor_ver) ...
21
votes
3
answers
6k
views
Can MIME types of Github Pages files be configured?
We have an MP4 video file in a Github Pages repository. The file is being served with a MIME type of application/octet-stream, which means Internet Explorer doesn't like it. It should be served as ...
20
votes
5
answers
62k
views
How to get better quality converting MP4 to WMV with ffmpeg?
I am converting MP4 files to WMV with these two rescaling commands:
ffmpeg -i test.mp4 -y -vf scale=-1:360 test1.wmv
ffmpeg -i test.mp4 -y -vf scale=-1:720 test2.wmv
I've also tried:
ffmpeg -g 1 -b ...
20
votes
2
answers
105k
views
Playing MP4 files in Firefox using HTML5 video
I have searched around quite a bit but have not solved my problem.
I have a video tag running as follows:
<video
class="ne"
src="{{ page | video_url }}"
muted="true"
volume="0"
...
19
votes
1
answer
45k
views
How To Convert MP4 Video File into FLV Format Using FFMPEG
i have to Convert MP4 Video File into FLV Format Using FFMPEG which i received from different mobile device. i found most of the stuff to convert flv video into mp4 and all.
can any body help me out ...
19
votes
3
answers
16k
views
Parsing H264 in mdat MP4
I have a file that only contains the mdat atom in a MP4 container. The data in the mdat contains AVC data. I know the encoding parameters for the data. The format does not appear to be in the Annex B ...