Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
9th July 2012, 14:43 | #1 | Link |
Registered User
Join Date: Nov 2007
Posts: 114
|
FRAPS to x264 to Youtube
I've recently started to do video captures with FRAPS. I will also be going to upload a few of them to Youtube. I'd gladly accept some tips regarding the process.
This is how I've currently planned it: 1. Record with FRAPS 1080p in RGB lossless mode. I understand there are problems with YV12 capture? 2. Avisynth script simply: AviSource("file.avi", pixel_type="RGB32") ConvertToYV12(matrix="rec709") 3. x264 settings: High Profile 5.1 Preset medium Tune film CRF 22 4. Upload to Youtube. Regarding the avisynth script, will this automatically make the video in 16-235 levels? Or do I have to enter another line for this conversion? Also, the profiles in x264, any point to encode in 5.1 or is 4.1 ok? Will 5.1 encode more efficiently? Ps. I did find a few threads on this on search but it was hard to get any good or conclusive facts on this issue, other than YV12 encoding in FRAPS seems to be dodgy. |
10th July 2012, 07:19 | #4 | Link |
Registered User
Join Date: Nov 2007
Posts: 114
|
Thanks for the tips so far! I've found CRF21 to be a kind of sweet spot with quality at a reasonable file size.
Anyway, it seems that my comp isn't capable of capturing lossless RGB at 1080p after all, the frame rate can sometimes go under 30, but at YV12 capture it never dips under this. From what I understand there is no way to preserve the YV12 color space? At least with Avisource the output is always in RGB. With ffvideosource, it does output YV12, but it is in PC levels. Is there any way to convert to TV levels without converting color space? As a curiosity, using Avisource and reconverting to YV12 doesn't look that bad, honestly I can't see any loss in image quality. But of course it would be best to avoid the double conversion. |
10th July 2012, 09:26 | #5 | Link | |||
Registered User
Join Date: Apr 2010
Location: Sain-Petersburg, Russia
Posts: 139
|
1) There are no major problems, just unnecessary colorspace conversions: full range RGB(screen)->full range YUV 4:4:4(fraps encode)->full range RGB(vfw fraps decode)->tv range YV12(avisynth).
In case of RGB lossless you'll have RGB values preserved exactly as they were. Fortunately, fraps has no issues with chroma shifts etc. as it processes YUV<->RGB naturally inside codec. Outside fraps always looks like RGB. 2) You did it right. Quote:
3) Level is not really needed. Youtube eats default (unrestricted) settings just fine. Quote:
In my eyes best bet (sorry, can't avoid this word) is 25.0 or 29.97 fps in fraps without v-sync, then only preserve fps in processing line. You may use more fps for video effects like slowing down some moments, but it's not needed in your case. So don't waste disk space and processor power - set up fps suitable for youtube from very beginning. Quote:
Last edited by Warperus; 10th July 2012 at 10:26. |
|||
10th July 2012, 09:35 | #6 | Link |
Registered User
Join Date: Nov 2007
Posts: 114
|
I just found out about another capture program called Dxtory. It seems to be faster and much more configurable than Fraps, you can select any codec of your choice for capture. Capturing in Lagarith YV12 would be quite an optimal solution!
I can't try it out at the moment, but it seems that it would be the cure for all the headaches that Fraps causes. |
10th July 2012, 09:58 | #7 | Link | |
RipBot264 author
Join Date: May 2006
Location: Poland
Posts: 7,812
|
Quote:
__________________
Windows 7 Image Updater - SkyLake\KabyLake\CoffeLake\Ryzen Threadripper |
|
10th July 2012, 11:11 | #9 | Link | ||
Registered User
Join Date: Nov 2007
Posts: 114
|
Quote:
My processor should be fairly fast, it's an Intel i7 930 @ 4.2GHz. Quote:
Is it better to use Levels("PC->TV") or Smoothlevels(preset="pc2tv") for luma conversion in YV12? Edit: Also, is it better to capture in 29.97 fps or 30? Does it make a difference to Youtube? Last edited by kutjong; 10th July 2012 at 11:25. |
||
10th July 2012, 11:39 | #10 | Link |
Registered User
Join Date: Dec 2007
Location: Germany
Posts: 632
|
To YouTube it does not make a difference whether you use 30.000 fps or 29.97.
SmoothLevels() will give visually nicer results than Levels() but whether or not you can see it depends on the video. If there are lots of fine dark shadings, Levels will most likely give visibly inferior results compared to SmoothLevels. I'd go for SmoothLevels, I hardly ever use Levels anymore. Legarith is indeed not very fast. Much faster is Ut Video Codec. By the way, if you capture in non-RGB mode in Fraps the Fraps codec will convert and downsample to (fullrange) YV12 while recording, therefore the resulting video decoded by Fraps to RGB has only a quarter the chroma resolution. There are ways to get the raw YV12 out of a Fraps video but the major problem is Fraps uses some weird custom coefficients to convert between YUV and RGB, giving slightly wrong colors if you do not use the Fraps decoder which always decodes to RGB. Capturing in RGB avoids all that. Last edited by TheSkiller; 10th July 2012 at 14:20. |
10th July 2012, 12:02 | #11 | Link | ||||
Registered User
Join Date: Nov 2007
Posts: 114
|
Quote:
Quote:
Quote:
As a sidenote, it would be good have a Wikipedia article about the Ut codec, that's where I was looking for info on different lossless codecs. Quote:
Edit: Doing some checkup on Lagarith, it does seem that the codec has had development not too long ago, back in last december. Reading the changelog, there seems to have been major optimizations, such as multithreading and SSE2. So it might not be so slow after all? Anyway, probably best to do some testing and compare both Lagarith and Ut. Last edited by kutjong; 10th July 2012 at 12:20. |
||||
10th July 2012, 14:07 | #12 | Link | |
The speed of stupid
Join Date: Sep 2011
Posts: 317
|
Quote:
If I was to present a stupid case I wouldn't have anyways, Lagarith YV12 runs at 35 fps @ 1280x960, UT barely runs at 20. |
|
10th July 2012, 14:12 | #13 | Link |
Registered User
Join Date: Dec 2007
Location: Germany
Posts: 632
|
Maybe you are forcing Ut Video to convert the color space?
For example, if you have a YUY2 video, you should select "Ut Video (...) 4:2:2" to compress the video and nothing else. For a YV12 video it's the one with "4:2:0" at the end. Same with RGB sources, only the two RGB choices would be adequate in that case (RGB with or without alpha). It is true that Legarith does compress a tad better than Ut though but the difference is small. Edit: The speed figures you present are odd, it should be a lot faster even for Legarith. I have a E8500 and I easily get >100 fps with Ut. Last edited by TheSkiller; 10th July 2012 at 14:18. |
10th July 2012, 15:13 | #14 | Link |
The speed of stupid
Join Date: Sep 2011
Posts: 317
|
I have no idea why it's so slow, either.
Hm, it's not all that much faster for 480p (100/120 fps Lag/Ut, you go judge.) - For 800x600 (AT THE APPROPRIATE COLORSPACE) Ut Is faster. (45 vs. 57 fps) It's better for those that have enough storage speed, but for those that don't - Lagarith shines bright. Because just now I've done a little test (the temporal part of this post is amazingly unstable) and Ut is 9 fps slower than Lagarith @ 800x600 at inappropriate colorspaces. (RGB->YV12) And since I would imagine your GPU outputs RGB, you'd have to pick RGB for Ut. Now - the problem with that is that it's twice as big as Lagarith RGB->YV12. All while being mighty 10 fps faster than Lagarith doing RGB->YV12. (And if you don't want it to be twice as big, it'll be 9 fps slower.) So yeah, for those who don't have storage speed problems, Ut is probably best. But for those that do, Lagarith is a very good candidate. |
10th July 2012, 15:36 | #15 | Link |
Registered User
Join Date: Dec 2007
Location: Germany
Posts: 632
|
To me that still doesn't make sense. In my tests Ut Video Codec results in roughly 5-20% larger files compared to Legarith. Probably depends a lot on the complexibility of the picture.
I'm also always saving the new lossless AVI to a different physical hard disk drive, not the one the source video is being read from for obvious reasons. |
10th July 2012, 15:53 | #16 | Link |
Registered User
Join Date: Aug 2007
Posts: 1,430
|
Not really. In the end the video will be stored as/converted to 4:2:0 so greens/reds won't be sharp regardless of whether you recorded as RGB or YV12. Levels should be fine regardless.
Why don't you let x264 do the conversion from PC to TV levels, skipping the AviSynth step entirely? Simply add --range tv to your x264 command line. If you're interested, here's how I go from the files Fraps outputs to H.264+AAC in MKV (then MKV->MP4 for when I want them to work with progressive downloading using JW Player). Last edited by Snowknight26; 10th July 2012 at 16:03. |
10th July 2012, 16:06 | #17 | Link | |
The speed of stupid
Join Date: Sep 2011
Posts: 317
|
Quote:
Which it only is in "my" tests when it encodes in the appropriate colorspace (No RGB->YV12, unlike Lagarith - that is). And thus in "my" tests, Ut would only be faster than Lagarith in RGB mode. And in RGB mode, it's twice as big as YV12 Lagarith. (oh so surprising) And (triple "And"!) if we decide to go along with Lagarith and do RGB->YV12 as to not be twice as big, Ut will end up being 9 fps slower than Lagarith. "Oops." |
|
10th July 2012, 16:40 | #18 | Link | |
Registered User
Join Date: Dec 2007
Location: Germany
Posts: 632
|
Quote:
Bloax, so what is this fuss all about? It has been metioned here and elsewhere that Legarith compresses best but at the same time it is one of the slowest lossless codecs out there. I just think that Ut Video Codec is a good option if you consider that, for many people at least, it is more than twice as fast especially for decoding while the file sizes are not that much bigger... That's the whole point. If you're after the smallest file sizes then yes, Legarith gives somewhat smaller files. I myself have used Legarith extensively until I came across Ut and found it vastly superiour for it's speed. If you have enough space to deal with lossless videos an increase of a few percent in file size is not dramatic I suppose. Last edited by TheSkiller; 10th July 2012 at 16:43. |
|
10th July 2012, 16:44 | #19 | Link | |||
Registered User
Join Date: Sep 2007
Posts: 5,374
|
Quote:
It can and does with newer builds Quote:
Quote:
|
|||
10th July 2012, 18:43 | #20 | Link | |
Registered User
Join Date: Nov 2007
Posts: 114
|
Quote:
Edit: Nevermind, it seems to be working now. I think I might go for this option, your custom preset works great too, thanks! Last edited by kutjong; 10th July 2012 at 18:49. |
|
Tags |
avisynth, encoding, fraps, x264, youtube |
Thread Tools | Search this Thread |
Display Modes | |
|
|