<p>There are a few things to consider. The MP4 spec was not designed for the playback of high frame rate files, because the files are highly compressed, and limited to using a single core for decompression. Even if you had 12 cores, the file would not decompress any faster. </p>

<p>The easiest way to solve your issue is to either encode the MP4 into another codec, or to do your editing and bounce out samples as needed. </p>

<p>As @mivk above said, if this is mostly for slow-mo purposes, you can encode the MP4 into Animation codec, Photo-JPEG, or Cineform. These codecs stand a better chance at playing back the file in closer to real time, but even then, they will still have difficulty. </p>

<p>That might give you enough real-time playback though to be able to move into your editor, to do your slow-mo effects, then export the file to 24/30/60 FPS, which you should have no problem playing on your machine. </p>

CC BY-SA 3.0
2014-02-14T21:41:17.150Z
2014-02-14T21:41:17.150Z
elburzs
<p>If I read this right, you want to watch your 120fps videos at 0.25 their real speed, seeing every single frame but at 30fps. That's what I do (GoPro 3+, 720p, 120fps) but it's a bit involved.</p>

<p>I use Blender video sequence editor. It's not intuitive but a good tutorial can make all the difference in the world, I learned with Mikeycal Meyers' tutorial: <div class="youtube-embed"><div>
                <iframe width="640px" height="395px" src="https://www.youtube.com/embed/UEIkIrYQYYY?start=0"></iframe>
            </div></div></p>

<p>Once you've gone through the basics it's as simple as</p>

<ul>
<li>add your MP4 right out of the GoPro</li>
<li>remove the audio track (useless at this point)</li>
<li>set "Frame Range" to end at the last frame in your video</li>
<li>set "Resolution" to 1280x720</li>
<li>set "Frame Rate" to 30fps or 29.97 fps depending on your camera (mine uses 29.97, no idea why)</li>
<li>set "Output" to // (will write a file like 00000-59829.???)
pick your choice of "Encoding" settings (see tutorial)</li>
<li>hit Animation and wait a while, the output video will be slowmo at 30fps</li>
</ul>

<p>Also, for editing real-life speed, I use HandBrake to resample the videos, because I didn't find how to tell Blender to do it. Here's a script I used to do this to all videos in a directory:</p>

<pre><code>time for f in *.MP4; do HandBrakeCLI -i $f -o ${f}_30.mkv -f mkv -q 4 -r 29.97 --cfr; HandBrakeCLI -i $f -o ${f}_60.mkv -f mkv -q 4 -r 59.940 --cfr; HandBrakeCLI -i $f -o ${f}_120.mkv -f mkv -q 4 -r 119.88 --cfr; done
</code></pre>

<p><strong>EDIT</strong>: found a faster way, using ffmpeg as described in
<a href="https://trac.ffmpeg.org/wiki/How%20to%20speed%20up%20/%20slow%20down%20a%20video" rel="nofollow">https://trac.ffmpeg.org/wiki/How%20to%20speed%20up%20/%20slow%20down%20a%20video</a></p>

<pre><code>ffmpeg -i GOPR0604.MP4_120.mkv -q 4 -filter:v "setpts=4.0*PTS" GOPR0604.MP4_120_slowmo.mkv
</code></pre>

CC BY-SA 3.0
2015-09-10T19:41:43.327Z
2015-09-12T13:10:59.880Z
2015-09-12T13:10:59.880Z
miguev
<p>If you shot at 120fps, it is presumably to get a slow motion effect. So the playback actually needs to be at your normal 24/25/30 fps speed to get the effect.</p>

<p>There is no such thing as 120 fps playback. The maximum I know of would be 60p.</p>

<p>What do ffmpeg or mediainfo report as the frame rate for these videos. If they report 120fps or some other weird value, then you could probably rewrap the videos in a container which would advertise the right fps. Something like <code>ffmpeg -r 30 -i INFILE .... -r 30 OUTFILE</code>.</p>

<p><strong>Update</strong> to clarify after seeing the comments :</p>

<p>There is no transformation or loss when viewing footage in slow motion. (Arguably quite the opposite, since you have a better chance of seeing each and every frame).</p>

<p>A frame is a frame, whatever your playback speed.</p>

<p>Transformations only come into play once you decide to drop frames to achieve a faster (not-so-slow) speed, or to double some frames to increase the slow-motion effect further. Your 120fps footage is intended to either be played at the normal speed of your movie (24p, 60i, ... whatever speed is the right one for your medium), or to be processed by doubling/dropping frames to achieve the exact speed you want.</p>

<p>You did the right thing by shooting at a very high speed to achieve a slow-motion effect, while having enough frames to tweak the final speed more exactly if needed.</p>

<p>Your player does the right thing in showing you the slow-motion effect you shot, exactly as you shot it.</p>

<p>For a very long time (since the late 1920s), there used to be only 1 possible playback speed: <a href="http://en.wikipedia.org/wiki/24p" rel="nofollow">24 fps</a> and nothing else. Later, with television, a few more speeds were added for engineering convenience: 25/50i and 30/60i (for 50Hz and 60Hz countries). Now, that has been extended to 48p, 50p and 60p, but that's it. There is no such thing as 120 fps playback.</p>

CC BY-SA 3.0
2013-12-16T21:01:56.467Z
I think it's "normal" that a video recorder ad 120fps is trying to play at 120fps. It's not very useful (as often screens refresh 60 times per second), but that's not the point. It would be strange if a video recorded at a certain framerate would try to playback at another. If the OP wants slow-motion he needs to put the 120fps through some editing program where it is interpreted as 30fps. That's material for another question though.
Saaru Lindestøkke
CC BY-SA 3.0
2014-02-28T03:41:29.800Z
@Bart & all, exactly. I thought that is what I explained in my original post. The whole purpose is to edit the raw footage for slomo effects or downsample. But to choose which I need to be able to view it first without transformations so I don't loose any quality.
asoundmove
CC BY-SA 3.0
2013-11-16T18:33:38.347Z
2014-02-28T20:30:53.670Z
2014-02-28T20:30:53.670Z
mivk
<p>While it is true that 720p video only has about half the data of a 1080p feed, the other thing you have to realize is that when you push the system beyond it's limit, it may spend a lot of time trying to process frames that it doesn't finish in time.  Depending on how the player is configured, it may give up and try to catch up rather than finish rendering the frame and get further behind.</p>

<p>Because of this, as soon as you get behind, you may now end up finding it is much harder for it to catch up.  You also run in to problems with keeping the data flowing quickly enough since the level of compression sounds like it may be higher (harder to decode) and the CPU is so busy that it can't be working on moving data up to be ready to read.</p>

<p>You probably should do a transcode of the video to a lower framerate and work with the transcoded copy to make editing decisions and then swap in the high framerate video only at the end.  After all, the only difference 120fps video will make on final output is anywhere that you end up doing a slow motion effect since you aren't going to have any display (including your computer screen) that can actually load 120 frames per second in to the image buffer.  Even 240hz screens are not displaying that many frames from a source.</p>

CC BY-SA 3.0
2014-02-28T21:33:25.810Z
2014-02-28T21:33:25.810Z
AJ Henderson
<p>I have a laptop with an i7 CPU, 1.73 GHz, 8GB RAM, Ubuntu 10.04 with an "ATI Mobility Radeon HD 5800 Series" graphics card. I have compiz enabled (which may be one of the culprits with the problem below).</p>

<p>I have recorded a few short videos in 720p resolution at 120fps (GoPro Hero 3), stored on my local HD. The mp4 videos range from 30MB to 500MB, so quite small.</p>

<p>I tried a variety of players, none of which seem to respond in real time  . In fact the response time is so bad that I get a few frames quite fast at the start but then only the odd frame every second to 5 seconds and the sound seems spliced! One of my 8 cores runs into the ground (100%), the others are essentially unused, with the video player process running at 98%. So obviously this is my limiting factor (can't multi-thread?).</p>

<p>(mplayer, xine both try to play in real time but drop many frames; vlc plays the sound, but shows impressionist rendering and then gets stuck on one frame quite early on; avidemux plays every frame but about 1/6th of real-time speed; cinelerra plays some of the frames only and quite slowly; kdenlive does not allow me to create a 120fps project; Kino converts and down-samples; Lives can't follow; OpenShot plays the sound Ok, but gets stuck on the first frame)</p>

<p>Playing standard 1080p 30fps footage uses about 65% of one core. I did expect that playing 120fps would drop frames, but not to the extent that I only see one every few seconds. In fact I thought that it would play about 1 in 4, which would be great for my purpose.</p>

<p>So I'd really appreciate if any of you had any hint as to how I should configure my video card, system or whatever to get better playback ability, i.e. real-time playback with my raw footage (without conversion or down-sampling prior to viewing).</p>

<p>This also affects my ability to edit the videos as I can't tell what I'm looking at in real time, which is very inconvenient when editing. I do not want to down-sample for the first stage of editing as I want to get a feel for the full video first and choose which sections to slow down for slow-motion and which sections to down-sample for normal real-time play.</p>

CC BY-SA 3.0
2013-02-13T08:19:53.340Z
Have you had a look at what your machine is doing, eg run top to see load. You need to find out where the bottleneck is- is it IO, CPU or something else.
Dr Mayhem
<video><editing><playback><linux><slowmotion>
120fps 720p footage with real time playback on Ubuntu? + editing?
asoundmove
# 120fps 720p footage with real time playback on Ubuntu? + editing?

(Asked by: username_0 on 2013-02-13)

I have a laptop with an i7 CPU, 1.73 GHz, 8GB RAM, Ubuntu 10.04 with an "ATI Mobility Radeon HD 5800 Series" graphics card. I have compiz enabled (which may be one of the culprits with the problem below).

I have recorded a few short videos in 720p resolution at 120fps (GoPro Hero 3), stored on my local HD. The mp4 videos range from 30MB to 500MB, so quite small.

I tried a variety of players, none of which seem to respond in real time . In fact the response time is so bad that I get a few frames quite fast at the start but then only the odd frame every second to 5 seconds and the sound seems spliced! One of my 8 cores runs into the ground (100%), the others are essentially unused, with the video player process running at 98%. So obviously this is my limiting factor (can't multi-thread?).

(mplayer, xine both try to play in real time but drop many frames; vlc plays the sound, but shows impressionist rendering and then gets stuck on one frame quite early on; avidemux plays every frame but about 1/6th of real-time speed; cinelerra plays some of the frames only and quite slowly; kdenlive does not allow me to create a 120fps project; Kino converts and down-samples; Lives can't follow; OpenShot plays the sound Ok, but gets stuck on the first frame)

Playing standard 1080p 30fps footage uses about 65% of one core. I did expect that playing 120fps would drop frames, but not to the extent that I only see one every few seconds. In fact I thought that it would play about 1 in 4, which would be great for my purpose.

So I'd really appreciate if any of you had any hint as to how I should configure my video card, system or whatever to get better playback ability, i.e. real-time playback with my raw footage (without conversion or down-sampling prior to viewing).

This also affects my ability to edit the videos as I can't tell what I'm looking at in real time, which is very inconvenient when editing. I do not want to down-sample for the first stage of editing as I want to get a feel for the full video first and choose which sections to slow down for slow-motion and which sections to down-sample for normal real-time play.

**Tags:** video, editing, playback, linux, slowmotion

> **Comments:**
> **username_1**: Have you had a look at what your machine is doing, eg run top to see load. You need to find out where the bottleneck is- is it IO, CPU or something else.  

---

## 4 answers

### Answer by username_6 on 2014-02-28. Score: 4 | Accepted answer

While it is true that 720p video only has about half the data of a 1080p feed, the other thing you have to realize is that when you push the system beyond it's limit, it may spend a lot of time trying to process frames that it doesn't finish in time. Depending on how the player is configured, it may give up and try to catch up rather than finish rendering the frame and get further behind.

Because of this, as soon as you get behind, you may now end up finding it is much harder for it to catch up. You also run in to problems with keeping the data flowing quickly enough since the level of compression sounds like it may be higher (harder to decode) and the CPU is so busy that it can't be working on moving data up to be ready to read.

You probably should do a transcode of the video to a lower framerate and work with the transcoded copy to make editing decisions and then swap in the high framerate video only at the end. After all, the only difference 120fps video will make on final output is anywhere that you end up doing a slow motion effect since you aren't going to have any display (including your computer screen) that can actually load 120 frames per second in to the image buffer. Even 240hz screens are not displaying that many frames from a source.


---

### Answer by username_2 on 2014-02-14. Score: 3

There are a few things to consider. The MP4 spec was not designed for the playback of high frame rate files, because the files are highly compressed, and limited to using a single core for decompression. Even if you had 12 cores, the file would not decompress any faster.

The easiest way to solve your issue is to either encode the MP4 into another codec, or to do your editing and bounce out samples as needed.

As @username_4 above said, if this is mostly for slow-mo purposes, you can encode the MP4 into Animation codec, Photo-JPEG, or Cineform. These codecs stand a better chance at playing back the file in closer to real time, but even then, they will still have difficulty.

That might give you enough real-time playback though to be able to move into your editor, to do your slow-mo effects, then export the file to 24/30/60 FPS, which you should have no problem playing on your machine.


---

### Answer by username_3 on 2015-09-10. Score: 2

If I read this right, you want to watch your 120fps videos at 0.25 their real speed, seeing every single frame but at 30fps. That's what I do (GoPro 3+, 720p, 120fps) but it's a bit involved.
I use Blender video sequence editor. It's not intuitive but a good tutorial can make all the difference in the world, I learned with Mikeycal Meyers' tutorial: 


Once you've gone through the basics it's as simple as

add your MP4 right out of the GoPro
remove the audio track (useless at this point)
set "Frame Range" to end at the last frame in your video
set "Resolution" to 1280x720
set "Frame Rate" to 30fps or 29.97 fps depending on your camera (mine uses 29.97, no idea why)
set "Output" to // (will write a file like 00000-59829.???)
pick your choice of "Encoding" settings (see tutorial)
hit Animation and wait a while, the output video will be slowmo at 30fps

Also, for editing real-life speed, I use HandBrake to resample the videos, because I didn't find how to tell Blender to do it. Here's a script I used to do this to all videos in a directory:
time for f in *.MP4; do HandBrakeCLI -i $f -o ${f}_30.mkv -f mkv -q 4 -r 29.97 --cfr; HandBrakeCLI -i $f -o ${f}_60.mkv -f mkv -q 4 -r 59.940 --cfr; HandBrakeCLI -i $f -o ${f}_120.mkv -f mkv -q 4 -r 119.88 --cfr; done

EDIT: found a faster way, using ffmpeg as described in
https://trac.ffmpeg.org/wiki/How%20to%20speed%20up%20/%20slow%20down%20a%20video
ffmpeg -i GOPR0604.MP4_120.mkv -q 4 -filter:v "setpts=4.0*PTS" GOPR0604.MP4_120_slowmo.mkv


---

### Answer by username_4 on 2013-11-16. Score: 2

If you shot at 120fps, it is presumably to get a slow motion effect. So the playback actually needs to be at your normal 24/25/30 fps speed to get the effect.

There is no such thing as 120 fps playback. The maximum I know of would be 60p.

What do ffmpeg or mediainfo report as the frame rate for these videos. If they report 120fps or some other weird value, then you could probably rewrap the videos in a container which would advertise the right fps. Something like `ffmpeg -r 30 -i INFILE .... -r 30 OUTFILE`.

**Update** to clarify after seeing the comments :

There is no transformation or loss when viewing footage in slow motion. (Arguably quite the opposite, since you have a better chance of seeing each and every frame).

A frame is a frame, whatever your playback speed.

Transformations only come into play once you decide to drop frames to achieve a faster (not-so-slow) speed, or to double some frames to increase the slow-motion effect further. Your 120fps footage is intended to either be played at the normal speed of your movie (24p, 60i, ... whatever speed is the right one for your medium), or to be processed by doubling/dropping frames to achieve the exact speed you want.

You did the right thing by shooting at a very high speed to achieve a slow-motion effect, while having enough frames to tweak the final speed more exactly if needed.

Your player does the right thing in showing you the slow-motion effect you shot, exactly as you shot it.

For a very long time (since the late 1920s), there used to be only 1 possible playback speed: [24 fps](http://en.wikipedia.org/wiki/24p) and nothing else. Later, with television, a few more speeds were added for engineering convenience: 25/50i and 30/60i (for 50Hz and 60Hz countries). Now, that has been extended to 48p, 50p and 60p, but that's it. There is no such thing as 120 fps playback.

> **Comments:**
> **username_5**: I think it's "normal" that a video recorder ad 120fps is trying to play at 120fps. It's not very useful (as often screens refresh 60 times per second), but that's not the point. It would be strange if a video recorded at a certain framerate would try to playback at another. If the OP wants slow-motion he needs to put the 120fps through some editing program where it is interpreted as 30fps. That's material for another question though.  
> **username_0**: @Bart & all, exactly. I thought that is what I explained in my original post. The whole purpose is to edit the raw footage for slomo effects or downsample. But to choose which I need to be able to view it first without transformations so I don't loose any quality.  

---

