View Full Version : x264Encoder 1.2.x for QuickTime Thread
MyCometG3
6th April 2010, 00:35
This is support thread for x264Encoder, QuickTime Compressor component for MacOS X 10.5 and QuickTime 7.6 or later.
Get latest version at:
- http://www003.upp.so-net.ne.jp/mycometg3/
/*I am not native speaker (Japanese), so please make simple English in this thread.*/
//
1) Please read README.rtf file
It is inside distributed dmg file. It is helpful to start, or to trouble-shoot.
2) Try MPEG Streamclip
For most casual purpose (i.e.non-productive-personnel), MPEG Streamclip 1.9.2 from Squared 5 (FREE!) is enough solution. It can use many QuickTime components, and support direct output to mp4 container using x264Encoder. QuickTime Player 7 Pro does not yet.
3) YouTube Channel
I have made YouTube channel. It could be your help.
- http://www.youtube.com/user/MyCometG3
4) Please use "log info" checkbox
It will write out SEI information which comes from libx264, into system.log. You can see system.log in /Applications/Utilities/Console.app.
Following shows the sample output of LOGINFO in system.log. You can see the longest line which contains many parameters. It is called SEI information, and requirement for tracking your problem.
[libx264 @ 0x1088800]using SAR=1/1
[libx264 @ 0x1088800]using cpu capabilities: MMX2 SSE2Fast SSSE3 Cache64
[libx264 @ 0x1088800]profile High, level 3.0
[libx264 @ 0x1088800]x264 - core 92 r1510M 33d382a - H.264/MPEG-4 AVC codec - Copyleft 2003-2010 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=3 sliced_threads=0 nr=0 decimate=1 interlaced=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 wpredb=1 wpredp=2 keyint=24 keyint_min=13 scenecut=40 intra_refresh=0 rc_lookahead=24 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=10 qpmax=51 qpstep=4 ip_ratio=1.40 aq=1:1.00
[libx264 @ 0x1088800]frame I:11 Avg QP:23.98 size: 33839
[libx264 @ 0x1088800]frame P:127 Avg QP:26.35 size: 8197
[libx264 @ 0x1088800]frame B:113 Avg QP:27.64 size: 1840
[libx264 @ 0x1088800]consecutive B-frames: 10.4% 75.8% 13.8% 0.0%
[libx264 @ 0x1088800]mb I I16..4: 9.7% 70.8% 19.6%
[libx264 @ 0x1088800]mb P I16..4: 1.2% 4.4% 1.4% P16..4: 45.4% 15.5% 10.6% 0.0% 0.0% skip:21.6%
[libx264 @ 0x1088800]mb B I16..4: 0.5% 0.1% 0.1% B16..8: 48.5% 0.4% 0.9% direct: 2.8% skip:46.8% L0:48.6% L1:48.8% BI: 2.7%
[libx264 @ 0x1088800]8x8 transform intra:65.5% inter:72.1%
[libx264 @ 0x1088800]coded y,uvDC,uvAC intra: 79.4% 68.2% 37.7% inter: 19.5% 17.4% 0.2%
[libx264 @ 0x1088800]i16 v,h,dc,p: 17% 75% 5% 3%
[libx264 @ 0x1088800]i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 18% 14% 32% 4% 6% 6% 8% 6% 7%
[libx264 @ 0x1088800]i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 18% 40% 11% 4% 6% 6% 6% 5% 5%
[libx264 @ 0x1088800]Weighted P-Frames: Y:0.0%
[libx264 @ 0x1088800]ref P L0: 53.2% 25.4% 11.9% 9.5%
[libx264 @ 0x1088800]ref B L0: 74.8% 23.2% 2.0%
[libx264 @ 0x1088800]ref B L1: 99.0% 1.0%
[libx264 @ 0x1088800]kb/s:1548.65
Dark Shikari
6th April 2010, 00:43
I wonder if the "keyint=24" and "bframes=0" are intentional in the example, because all the other settings are default...
Also, since you are Japanese, you should hang out on #x264 on Freenode IRC; there are a lot of Japanese x264 devs and users there (along with a few foreign speakers, including one professional translator).
MyCometG3
6th April 2010, 00:59
I wonder if the "keyint=24" and "bframes=0" are intentional in the example
Woops, updated example now. bframes=3 now.
Note: Keyint=24 is default value of every QuickTime Compressor component, thus it is intentional.
Blue_MiSfit
6th April 2010, 01:19
This is a very handy little tool, though its interface is rather confusing.
Still, you won't hear me complain. The ability to use x264 on a Compressor cluster is pretty durn cool :)
Elementary stream output would be nice, but I guess that's more a Compressor issue.
~MiSfit
MyCometG3
6th April 2010, 02:03
I am sorry that makes you confusing.
Because it is designed to use single gui wrapper for libavcodec, using x264, xvid, libavcodec mpeg4, etc. If someone want, I could make libavcodec-snow encoder... I guess.
use x264 on a Compressor cluster
Unfortunately, I am not rich...
Does Compressor cluster work with other third party's QuickTime Components? Like, Flip4mac, 3ivx, DivX, etc.
(I can not find any developer/technical details in Apple web site, about Compressor compatible requirements.)
//
I have checked out Compressor 3.5 at real apple store. It seems that QuickTime Movie preset would work with x264Encoder, in cluster mode. Did you have tried it?
0028606
6th April 2010, 14:11
This is a great tool, I have use it for some time now so just wanted to say thanks
Blue_MiSfit
6th April 2010, 19:40
@MyCometG3:
I haven't tried clustering, actually. I only have Compressor 2 on my MacPro at work.
I had some issues taking an MOV generated by this encoder in compressor, demuxing it, and remuxing into a TS. I'll see if I can replicate that issue for you.
~MiSfit
MyCometG3
10th April 2010, 01:25
x264Encoder Version 1.2.4 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1523.
MyCometG3
17th April 2010, 09:54
x264Encoder Version 1.2.5 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1542.
creamyhorror
17th April 2010, 11:15
Thanks for the update.
Is there a better place to include the field for CRF value when Single-pass is selected? After all, it would be good to encourage CRF usage by making it more accessible, or even the default. (If I'm not wrong, the CRF value is under the Flags tab at the moment.)
MyCometG3
17th April 2010, 15:48
@creamyhorror
To use CRF, just choose "Data rate : Automatic" instead of specific kbits/sec value. It has same effect as CRF checkbox inside lavcodec settings dialog.
If a user has selected multipass with CRF (or data rate=auto), first pass is just skipped (you can see "log info" how it runs).
or even the default
I would like to, but I can not find how to override default values till now... QuickTime API is, a kind of the CHAOS. :-(
smok3
17th April 2010, 20:07
@creamyhorror
To use CRF, just choose "Data rate : Automatic" instead of specific kbits/sec value. It has same effect as CRF checkbox inside lavcodec settings dialog.
If a user has selected multipass with CRF (or data rate=auto), first pass is just skipped (you can see "log info" how it runs).
I would like to, but I can not find how to override default values till now... QuickTime API is, a kind of the CHAOS. :-(
and CRF scale is that slider in percents?
MyCometG3
17th April 2010, 22:16
Take a look at README-tips.rtf.
Quality Slider
* Quality slider corresponds to ffmpeg -qmin. Center is QP=23, Best is QP=13, Least is QP=33. And qmax is QP=51, fixed value.
* On Constant Rate Factor-CRF Mode, the slider corresponds to ffmpeg -crf. Center is crf=23, Best is crf =13, Least is crf =33.
When you don't move slider as default, QP23 or CRF23 are applied.
Dark Shikari
17th April 2010, 23:24
Why in the world does the quality slider map to qmin?
MyCometG3
18th April 2010, 01:46
It is intended to simulate similar behavior as other compressor component (i.e. codec) like Apple H.264, etc.
QuickTime provides common compressor dialog which has single thumbnail image. And, it should show the result of quality slider in thumbnail image.
To change QP value on single frame, mapping qmin/crf as quality slider, seems to be natural behavior to most part of users.
//
I know x264 binary uses qpmin's default as 10. If someone want to use qpmin value less than 13 (x264Encoder's smallest limit), I could make it.
But in most case, I think placebo+grain can inflate Intra frame's sample size, and more smarter way for most non-geek users.
Dark Shikari
18th April 2010, 01:56
It is intended to simulate similar behavior as other compressor component (i.e. codec) like Apple H.264, etc.
QuickTime provides common compressor dialog which has single thumbnail image. And, it should show the result of quality slider in thumbnail image.
To change QP value on single frame, mapping qmin/crf as quality slider, seems to be natural behavior to most part of users.But CQP or CRF should be "quality", not qmin...
MyCometG3
18th April 2010, 03:20
But CQP or CRF should be "quality", not qmin...
x264Encoder currently works in three mode.
1) ABR mode - which runs same as --qpmin/--qpmax 51/--bitrate combo
2) CRF mode - which runs as --crf
3) lossless - which runs as --qp=0
In case of 1), Quality slider is mapped as --qpmin 13~33. qpmax is 51, fixed. bitrate field is used as target bitrate.
In case of 2), Quality slider works as --crf 13~33. bitrate field is ignored.
In case of 3), Quality slider and bitrate field are ignored.
...Is this so nonsense?
Dark Shikari
18th April 2010, 03:25
I don't think --bitrate mode should have a quality slider... it doesn't make sense.
The user shouldn't be messing with qpmin anyways.
MyCometG3
18th April 2010, 03:49
it doesn't make sense
Humm.
To make single pass + smaller gop size works better, limiting qpmin seems to be one choice, I guess.
Currently QuickTime's default Key frame interval (used as keyint) is 24, it is too smaller value compared to rc_lookahead's default value.
If default keyint is larger value like 120 or so, rc_lookahead perfectly controls each frame's qp. But it is not for now.
Under this restriction (as common QuickTime Component), limiting QP-min value seems to be one of resonable solution.
Well-known user always changes, but novice user may not change. It is easy to overshoot on this case.
Adub
18th April 2010, 04:19
You will have to forgive me, as I do not own a mac yet, but is it possible to use this plugin with something like iMovie, or Final Cut?
Dark Shikari
18th April 2010, 04:36
Humm.
To make single pass + smaller gop size works better, limiting qpmin seems to be one choice, I guess.
Currently QuickTime's default Key frame interval (used as keyint) is 24, it is too smaller value compared to rc_lookahead's default value.
If default keyint is larger value like 120 or so, rc_lookahead perfectly controls each frame's qp. But it is not for now.
Under this restriction (as common QuickTime Component), limiting QP-min value seems to be one of resonable solution.
Well-known user always changes, but novice user may not change. It is easy to overshoot on this case.rc-lookahead doesn't even affect frame QP except in the case of VBV mode... and an rc-lookahead of 24 is quite fine enough for that.
Blue_MiSfit
18th April 2010, 04:36
@Adub:
Yes, it absolutely is. It works almost everywhere that any other QuickTime component would. Strangely it crashes AJA VTRXchange (A simple capturing app for AJA's Kona cards).
@MyCometG3
I think you're a bit misguided in trying to mimic QuickTime. Why optimize around the corner case of short GOPs? I would bet the vast majority of people use the default max keyint of 250, as it's a well chosen number and x264 is highly adaptive in frametype decision.
I would VERY MUCH prefer if the defaults precisely mirrored x264cli, and the slider adjusted the --preset. This would make things a lot more familiar to us daily x264 users, as it's much closer to how other x264 GUIs have done things. Also, adjusting the --preset is basically the only adjustment most folks make (in addition to bitrate) between encode.
Having the slider adjust --qp-min doesn't make sense at all, because this value should almost NEVER be adjusted. Unless you think you're smarter than x264 :p
~MiSfit
MyCometG3
18th April 2010, 04:52
Mapping preset as q-slider seems to be good idea.
But q-slider is analog, and no way to feedback what preset is specified. Also it seems to require re-design dialog, because under crf mode preset is specified in complex dialog.
If user doesnot see common compression dialog, it is easy though.
To achive all of request, user can not use common movie export component... Behaving as quicktime component seems to be not smart.
EDIT - I guess just ignoring slider is simple but best solution for ABR. Planed to implement on next update.
Adub
21st April 2010, 22:50
@Blue_MiSfit
Thanks for the info! Looking forward to getting my Macbook Pro and testing this out.
MyCometG3
27th April 2010, 00:30
x264Encoder Version 1.2.6 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1564.
When abr, q-slider is ignored by default now.
Blue_MiSfit
27th April 2010, 01:02
Excellent!
I've always been confused as to how CRF mode worked in your QuickTime component.
If I set CRF mode in the config page, where do I enter the CRF number I want to use? Based on a previous post of yours, I see that the quality slider adjusts the CRF number - at least it did at one point. Is this still the case? If so, I assume moving the slider to the right will lower the CRF value, correct?
~MiSfit
MyCometG3
27th April 2010, 03:22
I assume moving the slider to the right will lower the CRF value, correct?
Yes.
Datarate:automatic runs as crf.
Datarate:any value runs as abr.
exeption: if you checked lossless, datarate/slider are ignored.
porfitron
27th April 2010, 20:35
Very cool, MyCometG3.
Just tried it out with iMovie on Snow Leopard. Generally, I use auto-leveling, but do you think it would be possible to let users set to level 4.0 (you skipped up to 4.1).
I ask because our DivX Plus HD profile is 4.0: http://developer.divx.com/docs/divx_plus_hd/Creation_with_x264/
Also, is there a way to get it to export in a container other than MOV? It's very simple to mux to MKV with MKVtoolnix or MP4 with Subler, but if it is possible directly from iMovie/Quicktime I would like to know how.
Again, very nice work! Thanks!
MyCometG3
28th April 2010, 14:54
but do you think it would be possible to let users set to level 4.0 (you skipped up to 4.1).
Currently, it is limited to a few levels. I am not sure, but 4.0 seems to have little difference from 4.1. (VCL value only?)
Anyway, I can mod my code to add support 4.0 in addition to 4.1.
Also, is there a way to get it to export in a container other than MOV? It's very simple to mux to MKV with MKVtoolnix or MP4 with Subler, but if it is possible directly from iMovie/Quicktime I would like to know how.
I do not know any export component for mkv.
MPEG Streamclip works with mp4, but no support for mkv.
No plan to mkv exporter in next DivX for Mac?
MyCometG3
5th May 2010, 07:46
x264Encoder Version 1.2.7 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1570.
Support many levels now.
i still need a short guide for dummies:
a. what do i clicky to get crf23 going &
b. what to clicky to get crf21 going (with default profile)?
(readme/docs stuff are totaly useless btw)
thanks for your work!
MyCometG3
5th May 2010, 11:32
CRF value takes analog values. Try log info checkbox.
Console log shows what crf value is specified when slider is changed.
Oh I sooo would have needed this a year and a half ago. Thank Apothis that I will never need to use a Mac again.
creamyhorror
5th May 2010, 18:49
CRF value takes analog values. Try log info checkbox.
Console log shows what crf value is specified when slider is changed.
No instant indicator for CRF value? :(
Keep up the good work!
Mug Funky
6th May 2010, 12:33
hey, mycometg3! love your work - x264encoder has been a bit of a workhorse at my last workplace for about a year - much better for delivering proofs to clients than apple's crap colour-tainted stupid slow bad quality encoder.
perhaps a little textbox in the settings dialog that maps to the quality slider would help relieve the confusion. and if it's possible, the ability to set a crf in the textbox and have it change the position on the slider?
interesting about streamclip having mp4 output... i had been making movs and using applescript and some bash with mp4box to handle the mp4 creation after encoding.
MyCometG3
12th May 2010, 00:24
x264Encoder Version 1.2.8 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1583.
Fix crash issue. Numeric field for crf is now available.
porfitron
12th May 2010, 20:29
Fix crash issue. Numeric field for crf is now available.
You totally fixed the crash issue :)
Encoding some stuff now... I'll let you know what happens.
Blue_MiSfit
12th May 2010, 20:37
Awesome! This keeps getting better and better!!
creamyhorror
13th May 2010, 04:17
MyCometG3, you're a real example to us. Thanks for implementing suggestions, and so quickly.
(Now someone needs to write a blurb about doing CRF encoding for all the QT users out there, so they know there's an alternative to 2-pass...)
MyCometG3
22nd May 2010, 23:21
x264Encoder Version 1.2.9 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1602.
Support fake-interlaced.
Great! Just got my Macbook Pro today and this is the first thing I installed. Keep up the good work!
MyCometG3
29th May 2010, 11:08
x264Encoder Version 1.2.10 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Please stop using 1.2.9.
1.2.9 has the issue of: Reply #4 on: May 26, 2010, 09:39:43 AM (http://doom10.org/index.php?topic=58.0)
Okay! Updating right away!
BTW, are you ever considered hosting this project on Github? You may be able to get a number of developers to help enhance the software by forking it if you were interested.
Looking at the source, it appears that you are compiling x264 using -Os. Is this really such a big deal on gcc 4.2? I haven't yet compiled x264 on my mac yet, but I thought there would be no problems using the default -O4. Am I completely wrong?
Any update for the latest version of x264?
MyCometG3
5th June 2010, 01:51
x264Encoder Version 1.2.11 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1629.
Use -O3 now. 130KB bigger binary, 2% or less speed gain than -Os.
Implement similar fix from git-1616.
Great! Thanks for the update Comet!
You considered using Github?
MyCometG3
12th June 2010, 01:16
x264Encoder Version 1.2.12 is now available at:
- http://www003.upp.so-net.ne.jp/mycometg3/
Based on libx264.a r1643.
github: http://github.com/MyCometG3/x264Encoder
If you anyone want stable branch of libx264, let me know.
Adub
15th June 2010, 23:33
Thanks man! I really appreciate it!
Adub
27th June 2010, 01:44
Hey, MyCometG3, any chance you can update the latest x264? They've added some cool new features that I'd like to take a spin on my Macbook Pro.
Thanks in advance! Thank you so much for providing these awesome hooks for X264!
Blue_MiSfit
27th June 2010, 05:32
Any possibility for MP4 / MKV output inside the encoder?
I'm thinking something similar to how vfw builds of x264 let me configure an output path in the codec configuration. This is very handy!
Derek
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.