x264 - H.264(MPEG-4 AVC) кодировщик (x86/x64) - это свободная библиотека программных компонентов для кодирования видеопотоков H.264/MPEG-4 AVC.
x264 - H.264(MPEG-4 AVC) Encoder (x86/x64) is a free library for encoding H.264/MPEG-4 AVC video streams.
Изменения / Changes (2164-2183):
-
Fix regression in r2141. Broke register preservation in x264_cpu_cpuid and x264_cpu_xgetbv. Did not cause any problems.;
-
Fix interlaced + extremal slice-max-size. Broke if the first macroblock in the slice exceeded the set slice-max-size.;
-
Fix RGB colorspace input. BGR/BGRA input was correct;
-
Add error handling for out-of-tree build;
-
ICL: fix out of tree building and resource file usage on Windows;
-
Fix rare overflow in 10-bit intra_satd_x3_16x16 asm;
-
Fix possible alignment crash when linking from MSVC. x264_cavlc_init needs to be stack-aligned now;
-
Fix incorrect zero-extension assumptions in x86_64 asm. Some x264 asm assumed that the high 32 bits of registers containing "int" values would be zero. This is almost always the case, and it seems to work with gcc, but it is *not* guaranteed by the ABI. As a result, it breaks with some other compilers, like Clang, that take advantage of this in optimizations. Accordingly, fix all x86 code by using intptr_t instead of int or using movsxd where neccessary. Also add checkasm hack to detect when assembly functions incorrectly assumes that 32-bit integers are zero-extended to 64-bit.;
-
x86inc: support yasm -f win64. Not necessary for x264, as -m amd64 already does the right thing, but used by external users of x86inc.;
-
Export PSNR/SSIM in x264 API;
-
Remove explicit run calculation from coeff_level_run. Not necessary with the CAVLC lookup table for zero run codes.;
-
Add an small per-MB cost penalty for lowres. Helps avoid VBV predictors going nuts with very low-cost MBs. One particular case this fixes is zero-cost MBs: adaptive quantization decreases the QP a lot, but (before this patch), no cost penalty gets factored in for this, because anything times zero is zero.;
-
Abstract bitstream backup/restore functions. Required for row re-encoding;
-
Add row-reencoding support to VBV for improved accuracy. Extremely accurate, possibly 100% so (I can't get it to fail even with difficult VBVs). Does not yet support rows split on slice boundaries (occurs often with slice-max-size/mbs). Still inaccurate with sliced threads, but better than before.;
-
Minor asm changes;
-
BMI1 decimate functions. Intel was nice enough to make tzcnt equal to "rep bsf", which is backwards-compatible. This means we don't actually have to add new functions to make it work;
-
x86inc: switch to amdnops. Recent AMD CPUs' instruction decoders choke horribly on extremely long nops (i.e. with 4 prefixes). Won't affect much, since we don't use ALIGN much;
-
Add full-recon API option. Fully reconstruct frames even without dump-yuv;
-
Sliced-threads: do hpel and deblock after returning. Lowers encoding latency around 14% in sliced threads mode with preset superfast. Additionally, even if there is no waiting time between frames, this improves parallelism, because hpel+deblock are done during the (singlethreaded) lookahead. For ease of debugging, dump-yuv forces all of the threads to wait and finish instead of setting b_full_recon
Encoder features :
-
CAVLC/CABAC
-
Multi-references
-
Intra: all macroblock types (16x16, 8x8, and 4x4 with all predictions)
-
Inter P: all partitions (from 16x16 down to 4x4)
-
Inter B: partitions from 16x16 down to 8x8 (including skip/direct)
-
Ratecontrol: constant quantizer, single or multipass ABR, optional VBV
-
Scene cut detection
-
Adaptive B-frame placement
-
B-frames as references / arbitrary frame order
-
8x8 and 4x4 adaptive spatial transform
-
Lossless mode
-
Custom quantization matrices
-
Parallel encoding of multiple slices
Advanced settings :
-
Enabling Cabac: approximately 10% bitrate reduction without loss in quality, but is slow.
-
Enabling De-blocking Filter: smooths out visible blocks during an encode (rather than by using post processing to smooth out blocks while decoding). Is a good idea to enable for low bitrate encodes.
Возможности кодека x264:
-
Контекстнозависимое Адаптивное Бинарное Арифметическое кодирование (CABAC) и Контекстнозависимое Адаптивное Кодирование с Переменной Длиной Кодового Слова (CAVLC)
-
Поддержка нескольких ссылочных кадров
-
Все intra типы макроблоков (16x16, 8x8 и 4x4 — 8x8 это часть AVC HP)
-
Все inter типы макроблоков P фрейма
-
B-Inter типы макроблоков от 16x16 до 8x8
-
Оптимизация отношения вносимых искажений к скорости потока
-
Несколько режимов работы управления скоростью потока: постоянный квантователь, постоянное качество, одно- или многопроходный ABR с режимом VBV
-
Обнаружение смены сцены
-
Адаптивная расстановка B-кадров, с возможностью использования B кадров как ссылочных кадров
-
8x8 и 4x4 адаптивное пространственное преобразование (High Profile)
-
Режим сжатия без потерь (отклоненный High Profile 4:4:4)
-
Произвольные матрицы квантования (High Profile)
-
Параллельное кодирование на нескольких CPU
-
Поддержка компрессии кадров с чересстрочной разверткой (неадаптивный MBAFF — все макроблоки кодируются в режиме чересстрочных)
Доступные настройки кодека для профессионалов:
-
Кодирование Cabac: приблизительно 10%-ое снижение битрэйта без потери качества.
-
Фильтр деблокирования: показывает видимые блоки во время кодирования (гораздо лучший метод по сравнению с пост-процессингом). Отличный метод для кодирования с использованием низкого битрэйта.
Unpatched, fprofiled, GCC 4.7.0: (svn rev. 185189, Pre-Release , 2012.02.11); (avs input, lavf input, ffms input, mp4 output.); (ffmpeg git-4272dc3, ffms2 svn.658, pthreads 2.9.0.0 CVS-20110710, gpac svn.3955, all static).:
|