Note that there are some explanatory texts on larger screens.

plurals
  1. POX264 & ARM encoding on Android
    primarykey
    data
    text
    <p>I recently built a Video encoding class that runs on Android using ffmpeg and native code. I am surprised by the time it takes to encode a video, about 1 frame / second at best. I have tried with x264 and settings optimised for speed and with mpeg as well - no real difference.</p> <p>The x264 library now has support for ARM architecture and is meant to be quite efficient on these boasting over 20fps encoding speed. I am not sure I am using it correctly. Here the script I use for compiling:</p> <pre><code>./configure --prefix=$PREFIX \ --enable-shared \ --enable-static \ --disable-gpac \ --enable-debug \ --extra-cflags=" -I$ARM_INC -fPIC -DANDROID -fpic -mthumb-interwork -ffunction-sections -funwind-tables -fno-short-enums -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -Wno-psabi -march=armv5te -msoft-float -mthumb -O3 -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,/usr/lib/libz.so -Wl,-rpath-link=$ARM_LIB,-dynamic-linker=/system/bin/linker -L$ARM_LIB -lc -lm -ldl -lgcc" \ --cross-prefix=${ARM_PRE}- \ --disable-asm \ --host=arm-linux \ </code></pre> <p>I believe the last line should so what I am after ie enable ARM optimisations. Maybe I am missing something.</p> <p>For info I am encoding a 640x480 video on a Nexus 7 tablet. Here are my encoder settings (x264)</p> <pre><code>c-&gt;gop_size = 12; c-&gt;pix_fmt = PIX_FMT_YUV420P; c-&gt;max_b_frames = 0; c-&gt;scenechange_threshold = 0; c-&gt;rc_buffer_size = 0; </code></pre> <p>Thanks</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload