View Full Version : mac-build next time?
peteag
16th April 2006, 23:15
because of rev.500 are there any usable mac-builds out there?
If you know how to use x264 without a GUI, building it yourself should not be too hard: make sure you have the development tools (Xcode might be enough) installed and run "./configure; make; make install" in the x264 source code tree.
On the other hand, most users probably want some sort of a native GUI like HandBrake, ffmpegX or VLC, which have their own binaries and include x264 one way or another. Those binaries won't take you to the bleeding edge, so you'll need to build your own if you need to get there.
peteag
17th April 2006, 12:41
ok, i've compiled it so far.
in the folder /usr/local/bin the file x264 is stored. so i open the terminal, jump to the folder and type in x264 --pass 2 --bitrate 700 --stats ".stats" --ref 5 --bframes 1 --b-rdo --subme 7 --trellis 1 --analyse p8x8,b8x8,i4x4,p4x4 --direct auto --me umh --merange 64 --sar 1:1 --progress --no-psnr --o "/Users/Pete/Desktop/mh_klein_x264.mp4" "/Volumes/Pete/mh_klein.avi" but when i hit the enter-button he calls me, that the command -sh: x264 wasn't found. What can I do?
Seems that /usr/local/bin is not in your PATH environment variable. The way of changing it (http://www.peachpit.com/articles/article.asp?p=31442&seqNum=4&rl=1) depends on your shell. However, you can as well use the whole path to the executable file: just type /usr/local/bin/x264 instead of x264. That way you don't need to go to /usr/local/bin. If you already are there, use ./x264 to point to the executable in the current directory. I'd recommend adding /usr/local/bin to your PATH variable or using the full path. There is no need to cd /usr/local/bin.
EDIT: By the way, does your input AVI contain uncompressed YV12 video? Otherwise x264 won't be able to read it. Also MP4 output is not available unless you compiled x264 with gpac (./configure --enable-mp4-output). That could be a bit difficult though. Matroska output should work directly. If your input is anything else than YV12, you'll either need to convert it before feeding it to x264, or you can use some frontend that does the conversion for you. Personally I use Mencoder, which supports the same x264 encoding parameters that are exposed by the x264 CLI.
peteag
17th April 2006, 16:41
I was watching for a converter that does my avi (uncompressed) to yv12. I've got an error-warning because of the yv12-thing. Could I use .264 extension when output in x264? is there any good mac-converter for this yv12-stuff?
UPDATE: Found one (yv12-codec for Quicktime) ... just rendering. Waiting for final x264-procedure!
UPDATE2: Movie's looking okay in yv12 so I've put it into my x264-encoder - no errors - no warning - a 0KB output file - not more!
what did I wrong?
UPDATE3: Used a widthxheight devidable by 16 so it's 592x240 now. only error-message now: stats-file not found! clear, it has to created in the first pass *lough*
here's my cl-text again: /usr/local/bin/x264 --pass 2 --bitrate 700 --ref 5 --bframes 1 --b-rdo --subme 7 --trellis 1 --analyse p8x8,b8x8,i4x4,p4x4 --direct auto --me umh --merange 64 --progress --stats "/Users/Pete/Desktop/x264.stats" --no-psnr --output "/Users/Pete/Desktop/mh_klein_x264.264" "/Users/Pete/Desktop/mh_klein.yuv" 592x240
peteag
18th April 2006, 08:34
why can't it find my stats-file?
UPDATE: Found mistake! Pass must be set to 1 in order to create the stats-file first. shame on me, i'm enbarressed! the mac is still encoding, what a release! thank you
peteag
22nd April 2006, 20:57
hey, wonderful encode - super fast and *smell* ...
next problem. the cli uses raw-yv12-files for input. so what about to backup a dvd, which is in vob/m2v or mpg??? how to encode it over the cli?
You'll need to convert to uncompressed video with some external tools or use a frontend. As I said, I use x264 through Mencoder (http://www.mplayerhq.hu/design7/news.html). It needs to be compiled from CVS with the following configure parameters for x264 support:
./configure --with-x264libdir=/path/to/x264/source/ --with-x264incdir=/path/to/x264/source/
To encode a DVD track (in Linux, not sure about Mencoder's DVD support in OS X):
mencoder dvd://1 -noskip -nosound -ovc x264 -x264encopts pass=1:turbo=2:bitrate=700:bframes=1:brdo:subq=7:trellis=1:direct_pred=3:me=3 -of rawvideo -o video.264
mencoder dvd://1 -noskip -nosound -ovc x264 -x264encopts pass=2:bitrate=700:bframes=1:brdo:subq=7:trellis=1:direct_pred=3:me=3 -of rawvideo -o video.264
dvd://1 specifies title 1 in the DVD disc currently in the DVD drive. If this doesn't work on OS X, you could try ripping the DVD to an ISO image and use "-dvd-device dvd.iso dvd://1".
The x264encopts I used here reflect the ones you used previously. I also used turbo=2 to speed up the first pass. As you see, it can be specified together with the same parameters used for pass 2, and it will simply change subq, me and others to lower values for faster first pass encoding. This can be useful if you are going to write an encoding script for yourself. The parameter names and values differ a bit from x264 CLI, but the same functionality should be available. See MPlayer/Mencoder manual (man mplayer) for detailed parameter descriptions. Oh, and Mencoder will use divx2pass.log(.temp) as a pass log file by default. That can be changed with parameter -passlogfile.
Mencoder could handle audio too, but not at the same time with raw H.264 output. Mencoder is originally designed to output AVI, and as far as I know, encoding directly to other containers like MP4 and MKV still doesn't work very well. That's why I used raw output in the example. Personally I'm fine with AVI for my own purposes :)
If you don't have other tools to handle audio ripping, you could use MPlayer to rip the soundtrack and run it through some CLI audio encoder; probably faac when using MP4 as a container. Ripping an AC3 track is easy in any case:
mplayer dvd://1 -dumpaudio -dumpfile audio.ac3
If you want to convert directly to AAC-LC, here seems to be one way of doing it (haven't tried this myself): http://forum.doom9.org/showthread.php?t=75222
You can find a lot of information about these command line tools by searching solutions for Linux, not OS X. Usually the same methods can be directly applied to OS X builds of the tools.
YayKitties
26th April 2006, 08:06
hey, wonderful encode - super fast and *smell*
I'm glad you like it. More speed to come!
starg4ze
28th April 2006, 18:56
Does anyone knows if there's a guide or howto or walkthrough to compile, configure and run all the software needed to make a DVD-backup with x264 on a Mac, and preferrable a Mactel(got a MBP 2.0)
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.