Preview and Transcoding

Okay so while I have some video editing experience I am more or less a newb and what I am trying to do is very simple. So that being said hopefully there is a simple solution.

I am trying to edit some stream sections of 2-3hrs long into shorter videos for you-tube. So basically 99% of it is jump cuts etc.

I am using OBS to record to MP4 here are the fine details:
Resolution 1920x1080
Datarate 2999kbps
Bitrate 3031kbps
FPS 30fps


I am having basically 2 problems. (So far)
The first is that the audio is... from my guess... buffering into Hitfilm 3 which causes it to playback very choppy unless I wait a long time 10min+

The Second Problem:
I have cropped out a section and applied a speed effect to it to make a mini-time-lapse. Currently its sitting in video 1 with the rest of the footage. Is there any way to preview this? It has yet while writing this post to shorten to an appropriate time on the timeline.... Should I move it into a separate track? Or just make the timelapse section alone in another project and import the finished product?

Some general questions:
Would some kind of trans-coding make the editor work better in general? I would think my low data rate stuff is fine but apparently not...

I intend to timelapse a bunch of sections so if I have to do them all as separate projects that would really suck :/

Let me know what you guys think! It could be as simple as changing the audio format to 48k or something the editor like idk you tell me! :D


  • Naveronasis
    Naveronasis Posts: 3
    edited March 2016


    This computer is a 12 core x99 5860x i7 with 32gb of ddr4 and solid state system drive with lots of space running Windows 10pro 64bit.

    The video is being loaded off a 2tb standard 7200rpm drive. And the video cards are Evga 970GTX SSC x2 running in SLI.

    So I have ram and processing power to spare.... Its water cooled and not even overclocked on a Asus Sabertooth board... for ultra stability. 

    All that being said hitfilm seems to use very low cpu and ram (less ram than even the total size of the imported video clip!) So perhaps its a resource management issue? Can I tell hitfilm to use more ram or cpu or something to help?

    I started a test encode and its only using my cpu at like... 50% :/ even Windows Movie Maker can utilize 100% and encodes way faster :(

  • Aladdin4d
    Aladdin4d Posts: 2,481 Enthusiast

    Ok first thing is OBS records using H.264 and Hitfilm's decoding of H.264 isn't always as smooth as it should be, Second thing is OBS might be recording with a variable frame rate and no NLE likes variable frame rate clips. All kinds of issues can pop up like audio sync problems and dropped frames. OBS can record with a constant frame rate but you'll have to double check the advanced settings to make sure that's the case. Third the speed effect won't shorten (or lengthen) a clip on the timeline you have to do that manually and there's a couple of ways to go about doing that. Check this thread for the options and explanations.

    And my post in this thread goes over how to fix your clips if they are recorded with a variable frame rate using Handbrake and links to another post covering Handbrake settings that'll give you a much nicer editing experience


  • tons of great info thanks! it is set to variable, ill have to see if I even can turn it off and still do this the way I am (streaming and capturing the stream) twitch gets really upset when you don't do variable but my data rate indicator is always green so I feel like I should be fine to do a constant bitrate.

    I am not as worried about the timeline as I am about being able to preview the speedup, however I have not read the other threads yet so I will do that now and do some tests with constant bitrate and let you know what if any problems remain.

  • tack
    tack Posts: 22

    Also you'll want to set the video thumbnails to be at the start/end of the timeline only, otherwise you will wait an agony worth of time whenever you change your zoom level.

    (Click the tiny triangle at the bottom of the timeline for the popup menu to set that.)

    Unfortunately, HitFilm is unacceptably slow with h.264.  You'll either want to generate a proxy (which bafflingly will take some hours for average sized clips) or transcode to a different format.  There is a wealth of information here and elsewhere about intermediate codecs.

  • Triem23
    Triem23 Posts: 20,581 Ambassador

    To continue on with the excellent information you've already gotten, you've given your record settings as having a data rate of about 3mbps. Believe it or not, that low bitrate actually hurts you!

    Mp4 is a PLAYBACK format, which means it's designed to cram data into the smallest package possible. For playback only (windows media, VLC, a phone), this isn't a big deal, since a viewer is usually ONLY watching the video--freeing computer resources for decode. However, Mp4 is terrible for editing. Remember, the mp4 compressed footage has to decompressed to full-bandwidth for the editor to deal with (roughly 6 MB per frame for 1920x1080. This means each frame, uncompressed, is 15 times larger than a second of your compressed source video). Mp4 is also a "Long-GOP" (Group of Pictures) format. In general this means that your OBS software might be making a "keyframe/I-frame" (a frame storing the complete image) somewhere between every 30-120 frames, depending on how recording is set up.  Every other frame is interpolated, bi-directionally, from the keyframes. Let's assume an I-frame every 30 frames. Now let's put our playhead on frame 42.... This means that Hitfilm has to look at frames 29 and 59, then interpolate by running through the delta compression for every other frame between 29-41 and 43-59 just to show frame 42.

    So ANY NLE will slow down with Mp4 footage--although, as noted, Hitfilm slows down with Mp4 more than most.

    More techie information on Playback vs Editing codecs can be found here:

    @NormanPCN has developed some custom mp4 setting that increase performance in Hitfilm. @Aladdin4d seems to have already linked you to that thread.

    Another option is MOV files using a DNxHD (Windows) or ProRes (Mac) codec. These codecs are free and can be found with a 5-second Google search. MPEG Streamclip is a good, free utility for transcoding to DNxHD/ProRes, and can do batch encodes, so you can set up a bunch of file just before bed and let the comp work as you sleep. Handbrake is a good, free software to batch render to Mp4 (if you try Norman's settings and they work for you).

    A general rule for video codecs is this--the more you compress the footage the bigger a load you put on your CPU and the more slowdown you may have. Lower compression ratios are easier for the software to deal with. However, things like DNxHD are vastly larger files at higher bitrates, thus can cause a bottleneck from the storage drive. Since you're using OBS, I'll assume you're recording game footage--for this DNxHD has a "proxy" profile, which is about 30mbps. This is the lowest bitrate DNxHD (but still 10 times the file size you're getting from OBS), but should be the same visual quality of your source file, and much faster in Hitfilm. Higher bitrate DNxHD settings will be diminishing returns with your system.

    For the SPEED effect, I'm assuming you're in Hitfilm 3 Express. The following applies to all versions of Hitfilm: Hitfilm's SPEED effect is a little strange--basically, you should put the footage to be transformed into it's own Composite Shot and set the Composite Shot to what you want the new duration to be (the step is important if you are SLOWING DOWN footage. if you're speeding it up, skip this), then embed the comp in your main comp and add the Speed effect. You'll still have to manually move the end of the datablock to end on the correct frame--Hitfilm doesn't do this automatically. The Speed effect is most useful if you need to keyframe Speed ramping from fast to  slow or slow to fast. if you just need a clip to be a different speed without a ramp, then read on--you have other options!

    Ok, second way to change speed in Hitfilm--right click a clip in the Media Pool, select Properties and change the FPS of the clip! This will change all instances of the clip across the entire project, but... If you right-click media in the pool and Duplicate it, you can set up one of the versions as, say, fast motion and leave the other as regular motion. Rename the fast motion version in the media pool so you know which is which. If you want a "normal, fast, normal" speed change, but you want the changes to "cut" in and not "ramp" in, this is better than the Speed effect.

    If you're in Hitfilm 4 Pro there's a new "Rate Stretch" tool. Select the Rate Stretch tool and drag the right edge of you media clip on the timeline... the clip will automatically speed up or slow down to fit the new duration you drag out.

    A couple of technical notes: Hitfilm isn't taking advantage of your dual-Gpu. Actually, no NLE or compositor really takes advantage of dual-SLI card yet, except After Effects, and AE only uses both cards for final renders--it doesn't help at all for the editing screens. Hitfilm renders its frames with the GPU. In general the CPU is mostly doing video decompression or particle calculation before passing things off to the GPU. You won't often see anything like max processor load in Hitfilm.... For reference, Movie Maker doesn't take advantage of GPUs, doing everything in CPU.

    Depending on how many video streams you're running the HDD is probably a bottleneck. 7200RPM was considered the minimum for SD work 15 years ago, and HD can stream a lot more data. That said, you have an aggressive compression, but, as discussed above, that has it's own issues.

    @tack you'll want to read this paragraph, too: Hitfilm's proxies are a lossless custom format, and they are also rendered at "Everything On" settings--to contrast, even when viewing something at "Full" in the view panel while editing, that's full-resolution, no anti-aliasing. (One can turn on AA in the viewer settings, but, don't) 4xMSAA means... Hitfilm basically has to render each frame four times! Additionally, proxy renders are a background process, not taking over all available resources like an Export render. The lossless compression encodes at about a 2:1 ratio, so proxy files are flipping huge, then being a low-priority process (leaving resources to keep editing while the proxy renders), but rendering at full-resolution with MSAA does make them slow....

    Ok, I think that covered everything?

  • tack
    tack Posts: 22

    @Triem23 epic post, thanks for taking the time.

    For me, I think the perplexing thing about the proxy rendering is indeed just how throttled it is.  I come from a unix background, and  honestly I wouldn't think twice about letting loose a niced encoder process go to town on the video.  It will peg the CPU when available but because it's niced (lower priority) you won't notice it while editing.  (One caveat is if the background task is IO bound, that can be much more disruptive, but in this case it is CPU bound.)

    Now, I understand and appreciate what you're saying about h.264, as with all long GOP formats, being optimized for playback, not for editing.  But there is just no escaping the fact that HitFilm is unusually slow with h.264.  It truly doesn't need to be this slow.  Decoding two 1080p streams and alpha blending a cross fade is a walk in the park for a modern CPU, let alone being able to offload parts to the GPU, and yet without proxies I get about 1fps in this most basic editing use-case.

    It would be nice to be able to work directly on h.264 files (as I can with Premiere, for example) without the need to generate proxies or transcode to other formats.  I consider this to be the price I pay for some of HF's very nice features and its sensible price, but there is always that latent frustration because I know the performance issues are quite solvable by the software.