Newest 'libx264' Questions - Stack Overflow
Articles published on the website
-
h264 global header
23 September 2012, by user1558688I need to process an incoming h264 stream from an external server.
This stream is composed by h264 frames with sps / pps information.
I need to "strip" this information out and pass the data along to the receiver.
How can I do this ?
-
flv file (with 264 video stream) cannot be decoded.
5 September 2012, by HongI have generate an flv file using libx264. It only contains video tags and some meta data. It can be played by ffmpeg, however, most commercial players cannot decode it.
The file is at, http://www.kuaipan.cn/file/id_3690055512098762.htm, the livestream_test.flv.
Very thanks if you know any possible errors in the file, I'm really confused now.
-
libx264 2 pass encoding with mbtree option, first pass fails
25 August 2012, by lightdeeI'm working on an application which uses libx264. When doing 2-pass encodes, if the mbtree option is enabled, the 1st pass doesn't seem to put anything into the stats files:
x264_1345845358591.L.mbtree.temp (size of 0) x264_1345845358591.L.temp $ cat x264_1345845358591.L.temp #options: 288x162 fps=2997/100 timebase=100/2997 bitdepth=8 cabac=0 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=48 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=210 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00**
When I do x264_encoder_open() for the 2nd pass, I get the failure message:
x264 [error]: ratecontrol_init: can't open stats file x264 [error]: x264_encoder_open failed
So it seems to be failing in the first pass. 2pass works fine if I turn off mbtree. I can run it with presets or tune parameters as long as mbtree is turned off. What parameter (see above list) might make mbtree fail in the first pass?
-
no c compiler found libx264 build [closed]
24 August 2012, by kerim yucelI have been trying to build ffmpeg for Android and I have managed to do so by using roman10's tutorial.
However, I needed x264 and I enabled libx264 in the configurations but it wasn't able to find the library. A quick internet search led me to the answer that I have to build x264 seperately and include it to ffmpeg config by editing ExternalLibs flags.
Currently I am using this script to build x264. Everything is fine except the fact that the error saying "No working C compiler is found" pops up. I have updated and installed build-essential and my gcc version is up to date.
Any help will be appreciated. Thanks a lot.
P.S. I am using ndk 4 just to make everything compatible with the tutorial link given above. I am running Ubuntu with VirtualBox from Windows 7.
Edit: I have been trying this tutorial as well, I am getting the same error along with unknown options error for each configuration options.
Another edit: I have tried this code and obtained the following.
echo 'int main() { return 0;}' > main.c && arm-eabi-gcc main.c || echo $?
/home/mehmet/Android_NDK_r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/../lib/gcc/arm-eabi/4.4.0/../../../../arm-eabi/bin/ld: crt0.o: No such file: No such file or directory collect2: ld returned 1 exit status 1
I have checked the flags as well, flags seem ok or I can't see the faulty line. Above you may find the build script I am using.
export ARM_ROOT=/home/mehmet/Android_NDK_r4 export ARM_INC=$ARM_ROOT/build/platforms/android-8/arch-arm/usr/include/ export ARM_LIB=$ARM_ROOT/build/platforms/android-8/arch-arm/usr/lib/ export ARM_TOOL=$ARM_ROOT/build/prebuilt/linux-x86/arm-eabi-4.4.0 export ARM_LIBO=$ARM_TOOL/lib/gcc/arm-eabi/4.4.0 export PATH=$ARM_TOOL/bin:$PATH export PATH=$ARM_TOOL/arm-eabi/bin:$PATH export ARM_PRE=arm-eabi ./configure --prefix=/sdcard/arm_and \ --disable-gpac \ --extra-cflags=" -I$ARM_INC -fPIC -DANDROID -fpic -mthumb-interwork -ffunction-sections -funwind-tables -fstack-prote ctor -fno-short-enums -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -Wno-psabi -march=armv5te -mtu ne=xscale -msoft-float -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64 -DANDROID -Wa,--noexecstack - MMD -MP " \ --extra-ldflags=" -nostdlib -Bdynamic -Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,nocopyreloc -Wl,-soname,/system /lib/libz.so -Wl,-rpath-link=$ARM_LIB,-dynamic-linker=/system/bin/linker -L$ARM_LIB -nostdlib $ARM_LIB/crtbegin_dynamic.o $ARM_LIB/crtend_android.o -lc -lm -ldl -lgcc " \ --cross-prefix=${ARM_PRE}- \ --disable-asm\ --host=arm-linux \
Third edit:
Config.log gives the following.
x264 configure script Command line options: "--prefix=/sdcard/arm_and" "--disable-gpac" "--extra-cflags=" "-I/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/include/" "-fPIC" "-DANDROID" "-fpic" "-mthumb-interwork" "-ffunction-sections" "-funwind-tables" "-fstack-prote" "ctor" "-fno-short-enums" "-D__ARM_ARCH_5__" "-D__ARM_ARCH_5T__" "-D__ARM_ARCH_5E__" "-D__ARM_ARCH_5TE__" "-Wno-psabi" "-march=armv5te" "-mtu" "ne=xscale" "-msoft-float" "-mthumb" "-Os" "-fomit-frame-pointer" "-fno-strict-aliasing" "-finline-limit=64" "-DANDROID" "-Wa,--noexecstack" "-" "MMD" "-MP" "--extra-ldflags=" "-nostdlib" "-Bdynamic" "-Wl,--no-undefined" "-Wl,-z,noexecstack" "-Wl,-z,nocopyreloc" "-Wl,-soname,/system" "/lib/libz.so" "-Wl,-rpath-link=/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib/,-dynamic-linker=/system/bin/linker" "-L/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib/" "-nostdlib" "/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib//crtbegin_dynamic.o" "/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib//crtend_android.o" "-lc" "-lm" "-ldl" "-lgcc" "--cross-prefix=arm-eabi-" "--disable-asm" "--host=arm-linux" checking whether arm-eabi-gcc works... no Failed commandline was: -------------------------------------------------- arm-eabi-gcc conftest.c -Wall -I. -I$(SRCPATH) -I/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/include/ -fPIC -DANDROID -fpic -mthumb-interwork -ffunction-sections -funwind-tables -fstack-prote ctor -fno-short-enums -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -Wno-psabi -march=armv5te -mtu ne=xscale -msoft-float -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64 -DANDROID -Wa,--noexecstack - MMD -MP -nostdlib -Bdynamic -Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,nocopyreloc -Wl,-soname,/system /lib/libz.so -Wl,-rpath-link=/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib/,-dynamic-linker=/system/bin/linker -L/home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib/ -nostdlib /home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib//crtbegin_dynamic.o /home/mehmet/Android_NDK_r4/build/platforms/android-8/arch-arm/usr/lib//crtend_android.o -lc -lm -ldl -lgcc -lm -o conftest arm-eabi-gcc: ctor: No such file or directory arm-eabi-gcc: ne=xscale: No such file or directory arm-eabi-gcc: MMD: No such file or directory arm-eabi-gcc: /lib/libz.so: No such file or directory cc1: error: unrecognized command line option "-mtu" cc1: error: unrecognized command line option "-fstack-prote" cc1: error: to generate dependencies you must specify either -M or -MM arm-eabi-gcc: -E or -x required when input is from standard input -------------------------------------------------- Failed program was: -------------------------------------------------- int main () { return 0; } -------------------------------------------------- DIED: No working C compiler found.
Last edit Problem solved. It was just a mistake related to typos. It works well now.
-
What, if any, guarantees are there for when `nalu_process` will be called?
1 August 2012, by gsprIn particular, can a call to
x264_encoder_encode
return before everynalu_process
callback associated to it has returned? Someone in #x264 suggested it's settings-dependent; I'm talking here about the "zerolatency" preset.If the answer to the above question is yes, then how common is it, empirically?