Page 3 of 236 FirstFirst 123451353103 ... LastLast
Results 21 to 30 of 2357

Thread: HOWTO: Install and use the latest FFmpeg and x264

  1. #21
    Join Date
    Sep 2006
    Beans
    3,529

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by Leefmc View Post
    Note that i did aptitude hold, but that didnt stop apt-get apparently.. what does it stop? Aptitude?
    I haven't used apt-get for a few years so I'm unsure if it has an equivalent of aptitude's "hold". I should have mentioned that hold probably would not stop apt-get and Synaptic.
    Quote Originally Posted by Leefmc View Post
    With all that said, now my new compile is not working right. Im getting errors when using ffmpeg:
    Code:
    *** glibc detected *** ffmpeg: free(): invalid pointer: 0x08757158 ***
    ======= Backtrace: =========
    /lib/tls/i686/cmov/libc.so.6[0xb7b5fa85]
    /lib/tls/i686/cmov/libc.so.6(cfree+0x90)[0xb7b634f0]
    ffmpeg(av_set_string2+0x8fb)[0x80eff9b]
    ======= Memory map: ========
    08048000-08509000 r-xp 00000000 08:02 108607     /usr/local/bin/ffmpeg
    08509000-08513000 rw-p 004c0000 08:02 108607     /usr/local/bin/ffmpeg
    What is the ffmpeg command that you are using to get this error? I've never encountered this error, but I would like to try to reproduce it. My guess is that there may be a mess of several ffmpeg/x264 installs (or residual files) screwing each other up. Use you package manager to completely remove all installed yasm, x264, and ffmpeg. Now you can either:
    Code:
    cd ~/yasm
    make distclean
    ./configure, make, checkinstall
    cd ~/x264
    make distclean
    git pull
    ./configure, make, checkinstall
    sudo ldconfig
    cd ~/ffmpeg
    make distclean
    svn update
    ./configure, etc
    or delete the yasm, ffmpeg and x264 directories and start the tutorial over.
    Last edited by FakeOutdoorsman; July 11th, 2008 at 07:06 AM.

  2. #22
    Join Date
    May 2008
    Beans
    31

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by FakeOutdoorsman View Post
    or delete the yasm, ffmpeg and x264 directories and start the tutorial over.
    I actually have, many times. I tried custom names, same error. Note that when i used custom names, upon removal, i made sure to sudo aptitude purge the names i gave them (and even the normal names, x264 && ffmpeg)

    Last night i tried compiling it 4 to 6 different ways, each time i fully purged, and deleted, all of the installs.

    I am out of ideas. Thoughts?

    (Note i'll post the command i tried when i get home, but also note that the command worked great on my previous compile.)

  3. #23
    Join Date
    Aug 2007
    Location
    Waimanalo, HI
    Beans
    8

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    If you have an AMD 64-bit system, here is something I just stumbled on that might be useful. In compiling x264, the linker told me I should use "-fPIC" and recompile common/x86/cabac-a.o. But that .o file is assembled rather than compiled. So, hoping that the assembler (yasm) would understand, I started over and configured with:
    Code:
    ./configure --prefix=/usr --libdir=/usr/lib64  \
      --enable-gtk --enable-pthread --enable-visualize --enable-pic --enable-shared  \
      --enable-mp4-output  \
      --extra-asflags="-fPIC"  \
      --extra-cflags="-O4 -march=k8 -mtune=k8 -pipe -ffast-math -fomit-frame-pointer"
    That seems to have worked.

  4. #24
    Join Date
    Sep 2006
    Beans
    3,529

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by Leefmc View Post
    I am out of ideas. Thoughts?
    I suggest posting this problem to the ffmpeg-user mailing list. They are much more knowledgeable than I am with ffmpeg, but be sure to read the posting guidelines (first paragraph) or they may ignore or flame you if you don't follow their strict protocol. Also, this is unstated in their rules, but if you subscribe to the digest mode and reply to it with a non-mime digest compatible mail client then they will flame you. Make sure to include both your full ffmpeg command and the ffmpeg output or they will flame you.
    Last edited by FakeOutdoorsman; July 11th, 2008 at 12:30 AM.

  5. #25
    Join Date
    Sep 2006
    Beans
    3,529

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by PGLGreg View Post
    If you have an AMD 64-bit system, here is something I just stumbled on that might be useful. In compiling x264, the linker told me I should use "-fPIC" and recompile common/x86/cabac-a.o. But that .o file is assembled rather than compiled. So, hoping that the assembler (yasm) would understand, I started over and configured with:
    Code:
    ./configure --prefix=/usr --libdir=/usr/lib64  \
      --enable-gtk --enable-pthread --enable-visualize --enable-pic --enable-shared  \
      --enable-mp4-output  \
      --extra-asflags="-fPIC"  \
      --extra-cflags="-O4 -march=k8 -mtune=k8 -pipe -ffast-math -fomit-frame-pointer"
    That seems to have worked.
    Thanks, PGLGreg. I'll add a note to the tutorial.

  6. #26
    Join Date
    May 2008
    Beans
    31

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Ok, just got home. Seems this is my code:

    Code:
    ffmpeg -y -i $1 -pass 1 -threads 4 -s 1170x728 -vcodec libx264 -b 384k -bt 192k -f mp4 -flags +loop -cmp +chroma -partitions 0 -me_method epzs -subq 1 -trellis 0 -refs 1 -coder 0 -me_range 16 -g 300 -keyint_min 30 -sc_threshold 40 -i_qfactor 0.71 -maxrate 10M -bufsize 10M -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level 30 -an -r ntsc /dev/null
    ffmpeg -y -i $1 -pass 2 -threads 4 -s 1170x728 -vcodec libx264 -b 384k -bt 192k -f mp4 -flags +loop -cmp +chroma -partitions +parti4x4+partp4x4+partp8x8+partb8x8 -me_method umh -subq 7 -trellis 2 -refs 1 -coder 0 -me_range 16 -g 300 -keyint_min 30 -sc_threshold 40 -i_qfactor 0.71 -maxrate 10M -bufsize 10M -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level 30 -acodec libfaac -ab 96k -ac 1 -r ntsc $2_temp.mp4
    I forget where i got it from, but most of it is not by me. I tested a bunch, and eventually went with that one after tweaking it some to my liking. It produced good output, good filesize, and most of all it worked for QuickTime.

    *edit*
    Note that at the moment im taking random arguments from the commands and trying to make something work, to hopefully pinpoint the problem.

    *edit2*
    Best i can find, it seems this is the problem:
    Code:
    -rc_eq 'blurCplx^(1-qComp)'
    If i remove that from the 2 commands, it runs. Im searching the ffmpeg docs to find out what rc_eq is.

    *edit3*
    Yea, seems it is a rate control equation. Not knowing encoding at all, how important is this? If i use the command "ffmpeg -rc_eq" i get the same error, so im guessing that specific command is corrupted or something? I compared an older videos size to the newly "no rc_eq" encoded one, and they seem to be the same size and quality, though i have not tested on quicktime yet (thats a bit of a pain when you dont have windows heh).

    Thoughts?
    Last edited by Leefmc; July 11th, 2008 at 02:21 AM.

  7. #27
    Join Date
    Aug 2007
    Location
    Waimanalo, HI
    Beans
    8

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by FakeOutdoorsman View Post
    Code:
    cd ~/x264
    git pull
    make distclean
    Generally, you should clean up before doing the pull, because the pull might change the configuration in a way that confuses make and prevents it from doing the distclean correctly.
    Code:
    cd ~/x264
    make distclean
    git pull

  8. #28
    Join Date
    Sep 2007
    Location
    /dev/null/
    Beans
    1,589

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by PGLGreg View Post
    If you have an AMD 64-bit system, here is something I just stumbled on that might be useful. In compiling x264, the linker told me I should use "-fPIC" and recompile common/x86/cabac-a.o. But that .o file is assembled rather than compiled. So, hoping that the assembler (yasm) would understand, I started over and configured with:
    Code:
    ./configure --prefix=/usr --libdir=/usr/lib64  \
      --enable-gtk --enable-pthread --enable-visualize --enable-pic --enable-shared  \
      --enable-mp4-output  \
      --extra-asflags="-fPIC"  \
      --extra-cflags="-O4 -march=k8 -mtune=k8 -pipe -ffast-math -fomit-frame-pointer"
    That seems to have worked.
    My understanding is that anything over -O3 in GCC just results in the compiler using 3.

    I'm using -march=native on Intrepid, which is running well. I think native is a better setting.
    He that will not reason is a bigot; he that cannot reason is a fool; he that dares not reason is a slave.

  9. #29
    Join Date
    Aug 2007
    Location
    Waimanalo, HI
    Beans
    8

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by Nullack View Post
    My understanding is that anything over -O3 in GCC just results in the compiler using 3.

    I'm using -march=native on Intrepid, which is running well. I think native is a better setting.
    Yes, that's my understanding, also. So, one may as well use "-O4".

    I use those compiler flags not because I think they're good, but because mplayer thinks they're good. That is, when I configured mplayer, it took a look at my system and decided those are the flags I should use. Me -- I dunno.

    What's good about "-march=native"? What does it even mean?

  10. #30
    Join Date
    Sep 2006
    Beans
    3,529

    Re: HOWTO: Compile the latest ffmpeg and x264 from source

    Quote Originally Posted by Leefmc View Post
    *edit3*
    Yea, seems it is a rate control equation.
    I can confirm this error. I'm getting the same error but haven't found a reason or solution yet.

Page 3 of 236 FirstFirst 123451353103 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •