Zookeeper
Bytes
Http://code.google.com/p/webm/downloads/list
Download ffmpeg-0.6.1
Mount the patch file mv to the ffmpeg-0.6.1 directory
Patch
Patch-p1 <ffmpeg-0.6.1_libvpx-v0.9.5-135-gc28b10a.diff
First, compile and install libvpx
The configuration file is./configure -- prefix =/usr/local/libvpx -- enable-shared -- enable-vp8
Cross-compilation Configuration
./Configure -- target = armv6-linux-gcc -- prefix =/usr/local/libvpx-arm -- enable-shared -- enable-vp8
Error message: yasm
Solution: sudo apt-get install yasm
Make
Sudo make install
Compile and install ffmpeg
The configuration file is
. /Configure -- prefix =/usr/local/ffmpeg-vp8-x86 -- enable-libvpx -- enable-shared -- cc = gcc -- extra-cflags =-I/usr/local/libvpx/include -- extra -ldflags =-L/usr/local/libvpx/lib
Error Message
Libavcodec/libvpxenc. c: 111: error: 'vp8e _ SET_CQ_LEVEL 'undeclared here (not in a function)
Libavcodec/libvpxenc. c: 111: error: array index in initializer not of integer type
Libavcodec/libvpxenc. c: 111: error: (near initialization for 'ct1_str ')
Libavcodec/libvpxenc. c: In function 'vp8 _ init ':
Libavcodec/libvpxenc. c: 284: error: 'vpx _ CQ 'undeclared (first use in this function)
Libavcodec/libvpxenc. c: 284: error: (Each undeclared identifier is reported only once
Libavcodec/libvpxenc. c: 284: error: for each function it appears in .)
Libavcodec/libvpxenc. c: At top level:
Libavcodec/libvpxenc. c: 567: warning: initialization discards qualifiers from pointer target type
Solution: Open/usr/local/libvpx/include/vp8cx. h
Enum vp8e_enc_control_id
{
VP8E_UPD_ENTROPY = 5,/** <control function to set mode of entropy update in encoder */
VP8E_UPD_REFERENCE,/** <control function to set reference update mode in encoder */
VP8E_USE_REFERENCE,/** <control function to set which reference frame encoder can use */
VP8E_SET_ROI_MAP,/** <control function to pass an ROI map to encoder */
VP8E_SET_ACTIVEMAP,/** <control function to pass an Active map to encoder */
VP8E_SET_SCALEMODE = 11,/** <control function to set encoder scaling mode */
VP8E_SET_CPUUSED = 13,/** <control function to set vp8 encoder cpuused */
VP8E_SET_ENABLEAUTOALTREF,/** <control function to enable vp8 to automatic IC set and use altref frame */
Vp8e_set_noise_sensiti.pdf,/** <control function to set noise sensiti.pdf */
VP8E_SET_SHARPNESS,/** <control function to set sharpness */
VP8E_SET_STATIC_THRESHOLD,/** <control function to set the threshold for macroblocks treated static */
VP8E_SET_TOKEN_PARTITIONS,/** <control function to set the number of token partitions */
VP8E_GET_LAST_QUANTIZER,/** <return the quantizer chosen by
Encoder for the last frame using the internal
Scale */
VP8E_GET_LAST_QUANTIZER_64,/** <return the quantizer chosen by
Encoder for the last frame, using the 0 .. 63
Scale as used by the rc _ * _ quantizer config
Parameters */
VP8E_SET_ARNR_MAXFRAMES,/** <control function to set the max number of frames blurred creating Arn */
VP8E_SET_ARNR_STRENGTH,/** <control function to set the filter strength for the arns */
VP8E_SET_ARNR_TYPE,/** <control function to set the type of filter to use for the arns */
VP8E_SET_CQ_LEVEL,
};
VPX_CTRL_USE_TYPE_DEPRECATED (VP8E_UPD_ENTROPY, int)
VPX_CTRL_USE_TYPE_DEPRECATED (VP8E_UPD_REFERENCE, int)
VPX_CTRL_USE_TYPE_DEPRECATED (VP8E_USE_REFERENCE, int)
VPX_CTRL_USE_TYPE (VP8E_SET_ROI_MAP, vpx_roi_map_t *)
VPX_CTRL_USE_TYPE (VP8E_SET_ACTIVEMAP, vpx_active_map_t *)
VPX_CTRL_USE_TYPE (VP8E_SET_SCALEMODE, vpx_scaling_mode_t *)
VPX_CTRL_USE_TYPE (VP8E_SET_CPUUSED, int)
VPX_CTRL_USE_TYPE (VP8E_SET_ENABLEAUTOALTREF, unsigned int)
VPX_CTRL_USE_TYPE (vp8e_set_noise_sensiti.pdf, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_SHARPNESS, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_STATIC_THRESHOLD, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_TOKEN_PARTITIONS, vp8e_token_partitions)
VPX_CTRL_USE_TYPE (VP8E_SET_ARNR_MAXFRAMES, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_ARNR_STRENGTH, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_ARNR_TYPE, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_SET_CQ_LEVEL, unsigned int)
VPX_CTRL_USE_TYPE (VP8E_GET_LAST_QUANTIZER, int *)
VPX_CTRL_USE_TYPE (VP8E_GET_LAST_QUANTIZER_64, int *)
Add two red parts to the code
Edit libavcodec/libvpxenc. c: 284
Change VPX_CQ to VPX_VBR