Update VP8 binaries for iOS

This commit is contained in:
bossiel 2012-05-13 22:35:50 +00:00
parent 222b86ea67
commit 0c79519f06
9 changed files with 120 additions and 37 deletions

View File

@ -46,7 +46,7 @@ enum vp8_com_control_id
VP8_SET_DBG_COLOR_B_MODES = 6, /**< set which blocks modes to color */
VP8_SET_DBG_DISPLAY_MV = 7, /**< set which motion vector modes to draw */
VP8_COMMON_CTRL_ID_MAX,
VP8_DECODER_CTRL_ID_START = 256,
VP8_DECODER_CTRL_ID_START = 256
};
/*!\brief post process flags
@ -63,6 +63,7 @@ enum vp8_postproc_level
VP8_DEBUG_TXT_MBLK_MODES = 1<<4, /**< print macro block modes over each macro block */
VP8_DEBUG_TXT_DC_DIFF = 1<<5, /**< print dc diff for each macro block */
VP8_DEBUG_TXT_RATE_INFO = 1<<6, /**< print video rate info (encoder only) */
VP8_MFQE = 1<<10
};
/*!\brief post process flags
@ -118,13 +119,5 @@ VPX_CTRL_USE_TYPE(VP8_SET_DBG_DISPLAY_MV, int)
/*! @} - end defgroup vp8 */
#if !defined(VPX_CODEC_DISABLE_COMPAT) || !VPX_CODEC_DISABLE_COMPAT
/* The following definitions are provided for backward compatibility with
* the VP8 1.0.x SDK. USE IN PRODUCTION CODE IS NOT RECOMMENDED.
*/
DECLSPEC_DEPRECATED extern vpx_codec_iface_t vpx_codec_vp8_algo DEPRECATED;
#endif
#include "vpx_codec_impl_bottom.h"
#endif

View File

@ -177,7 +177,7 @@ enum vp8e_enc_control_id
* to a keyframe, set this to 450.
*
*/
VP8E_SET_MAX_INTRA_BITRATE_PCT,
VP8E_SET_MAX_INTRA_BITRATE_PCT
};
/*!\brief vpx 1-D scaling mode
@ -258,7 +258,7 @@ typedef enum
VP8_ONE_TOKENPARTITION = 0,
VP8_TWO_TOKENPARTITION = 1,
VP8_FOUR_TOKENPARTITION = 2,
VP8_EIGHT_TOKENPARTITION = 3,
VP8_EIGHT_TOKENPARTITION = 3
} vp8e_token_partitions;

View File

@ -55,6 +55,11 @@ enum vp8_dec_control_id
/** check if the indicated frame is corrupted */
VP8D_GET_FRAME_CORRUPTED,
/** control function to get info on which reference frames were used
* by the last decode
*/
VP8D_GET_LAST_REF_USED,
VP8_DECODER_CTRL_ID_MAX
} ;
@ -69,7 +74,7 @@ enum vp8_dec_control_id
VPX_CTRL_USE_TYPE(VP8D_GET_LAST_REF_UPDATES, int *)
VPX_CTRL_USE_TYPE(VP8D_GET_FRAME_CORRUPTED, int *)
VPX_CTRL_USE_TYPE(VP8D_GET_LAST_REF_USED, int *)
/*! @} - end defgroup vp8_decoder */

View File

@ -55,8 +55,8 @@ extern "C" {
#define VPX_CODEC_CAP_POSTPROC 0x40000 /**< Can postprocess decoded frame */
#define VPX_CODEC_CAP_ERROR_CONCEALMENT 0x80000 /**< Can conceal errors due to
packet loss */
#define VPX_CODEC_CAP_INPUT_PARTITION 0x100000 /**< Can receive encoded frames
one partition at a time */
#define VPX_CODEC_CAP_INPUT_FRAGMENTS 0x100000 /**< Can receive encoded frames
one fragment at a time */
/*! \brief Initialization-time Feature Enabling
*
@ -68,9 +68,9 @@ extern "C" {
#define VPX_CODEC_USE_POSTPROC 0x10000 /**< Postprocess decoded frame */
#define VPX_CODEC_USE_ERROR_CONCEALMENT 0x20000 /**< Conceal errors in decoded
frames */
#define VPX_CODEC_USE_INPUT_PARTITION 0x40000 /**< The input frame should be
#define VPX_CODEC_USE_INPUT_FRAGMENTS 0x40000 /**< The input frame should be
passed to the decoder one
partition at a time */
fragment at a time */
/*!\brief Stream properties
*
@ -189,11 +189,13 @@ extern "C" {
* generated, as appropriate. Encoded data \ref MUST be passed in DTS (decode
* time stamp) order. Frames produced will always be in PTS (presentation
* time stamp) order.
* If the decoder is configured with VPX_CODEC_USE_INPUT_PARTITION enabled,
* data and data_sz must contain at most one encoded partition. When no more
* data is available, this function should be called with NULL as data and 0
* as data_sz. The memory passed to this function must be available until
* the frame has been decoded.
* If the decoder is configured with VPX_CODEC_USE_INPUT_FRAGMENTS enabled,
* data and data_sz can contain a fragment of the encoded frame. Fragment
* \#n must contain at least partition \#n, but can also contain subsequent
* partitions (\#n+1 - \#n+i), and if so, fragments \#n+1, .., \#n+i must
* be empty. When no more data is available, this function should be called
* with NULL as data and 0 as data_sz. The memory passed to this function
* must be available until the frame has been decoded.
*
* \param[in] ctx Pointer to this instance's context
* \param[in] data Pointer to this block of new coded data. If
@ -325,7 +327,3 @@ extern "C" {
#ifdef __cplusplus
}
#endif
#if !defined(VPX_CODEC_DISABLE_COMPAT) || !VPX_CODEC_DISABLE_COMPAT
#include "vpx_decoder_compat.h"
#endif

View File

@ -32,6 +32,19 @@ extern "C" {
#define VPX_ENCODER_H
#include "vpx_codec.h"
/*! Temporal Scalability: Maximum length of the sequence defining frame
* layer membership
*/
#define VPX_TS_MAX_PERIODICITY 16
/*! Temporal Scalability: Maximum number of coding layers */
#define VPX_TS_MAX_LAYERS 5
/*!\deprecated Use #VPX_TS_MAX_PERIODICITY instead. */
#define MAX_PERIODICITY VPX_TS_MAX_PERIODICITY
/*!\deprecated Use #VPX_TS_MAX_LAYERS instead. */
#define MAX_LAYERS VPX_TS_MAX_LAYERS
/*!\brief Current ABI version number
*
@ -41,7 +54,7 @@ extern "C" {
* types, removing or reassigning enums, adding/removing/rearranging
* fields to structures
*/
#define VPX_ENCODER_ABI_VERSION (2 + VPX_CODEC_ABI_VERSION) /**<\hideinitializer*/
#define VPX_ENCODER_ABI_VERSION (3 + VPX_CODEC_ABI_VERSION) /**<\hideinitializer*/
/*! \brief Encoder capabilities bitfield
@ -592,6 +605,46 @@ extern "C" {
*/
unsigned int kf_max_dist;
/*
* Temporal scalability settings (ts)
*/
/*!\brief Number of coding layers
*
* This value specifies the number of coding layers to be used.
*/
unsigned int ts_number_layers;
/*!\brief Target bitrate for each layer
*
* These values specify the target coding bitrate for each coding layer.
*/
unsigned int ts_target_bitrate[VPX_TS_MAX_LAYERS];
/*!\brief Frame rate decimation factor for each layer
*
* These values specify the frame rate decimation factors to apply
* to each layer.
*/
unsigned int ts_rate_decimator[VPX_TS_MAX_LAYERS];
/*!\brief Length of the sequence defining frame layer membership
*
* This value specifies the length of the sequence that defines the
* membership of frames to layers. For example, if ts_periodicity=8 then
* frames are assigned to coding layers with a repeated sequence of
* length 8.
*/
unsigned int ts_periodicity;
/*!\brief Template defining the membership of frames to coding layers
*
* This array defines the membership of frames to coding layers. For a
* 2-layer encoding that assigns even numbered frames to one layer (0)
* and odd numbered frames to a second layer (1) with ts_periodicity=8,
* then ts_layer_id = (0,1,0,1,0,1,0,1).
*/
unsigned int ts_layer_id[VPX_TS_MAX_PERIODICITY];
} vpx_codec_enc_cfg_t; /**< alias for struct vpx_codec_enc_cfg */
@ -632,6 +685,48 @@ extern "C" {
vpx_codec_enc_init_ver(ctx, iface, cfg, flags, VPX_ENCODER_ABI_VERSION)
/*!\brief Initialize multi-encoder instance
*
* Initializes multi-encoder context using the given interface.
* Applications should call the vpx_codec_enc_init_multi convenience macro
* instead of this function directly, to ensure that the ABI version number
* parameter is properly initialized.
*
* In XMA mode (activated by setting VPX_CODEC_USE_XMA in the flags
* parameter), the storage pointed to by the cfg parameter must be
* kept readable and stable until all memory maps have been set.
*
* \param[in] ctx Pointer to this instance's context.
* \param[in] iface Pointer to the algorithm interface to use.
* \param[in] cfg Configuration to use, if known. May be NULL.
* \param[in] num_enc Total number of encoders.
* \param[in] flags Bitfield of VPX_CODEC_USE_* flags
* \param[in] dsf Pointer to down-sampling factors.
* \param[in] ver ABI version number. Must be set to
* VPX_ENCODER_ABI_VERSION
* \retval #VPX_CODEC_OK
* The decoder algorithm initialized.
* \retval #VPX_CODEC_MEM_ERROR
* Memory allocation failed.
*/
vpx_codec_err_t vpx_codec_enc_init_multi_ver(vpx_codec_ctx_t *ctx,
vpx_codec_iface_t *iface,
vpx_codec_enc_cfg_t *cfg,
int num_enc,
vpx_codec_flags_t flags,
vpx_rational_t *dsf,
int ver);
/*!\brief Convenience macro for vpx_codec_enc_init_multi_ver()
*
* Ensures the ABI version parameter is properly set.
*/
#define vpx_codec_enc_init_multi(ctx, iface, cfg, num_enc, flags, dsf) \
vpx_codec_enc_init_multi_ver(ctx, iface, cfg, num_enc, flags, dsf, \
VPX_ENCODER_ABI_VERSION)
/*!\brief Get a default configuration
*
* Initializes a encoder configuration structure with default values. Supports
@ -737,7 +832,6 @@ extern "C" {
vpx_enc_frame_flags_t flags,
unsigned long deadline);
/*!\brief Set compressed data output buffer
*
* Sets the buffer that the codec should output the compressed data

View File

@ -160,7 +160,8 @@ extern "C" {
* \param[in] fmt Format for the image
* \param[in] d_w Width of the image
* \param[in] d_h Height of the image
* \param[in] align Alignment, in bytes, of each row in the image.
* \param[in] align Alignment, in bytes, of the image buffer and
* each row in the image(stride).
*
* \return Returns a pointer to the initialized image descriptor. If the img
* parameter is non-null, the value of the img parameter will be

View File

@ -29,16 +29,8 @@ typedef signed __int64 int64_t;
typedef unsigned __int64 uint64_t;
#endif
#ifdef HAVE_ARMV6
typedef unsigned int int_fast16_t;
#else
typedef signed short int_fast16_t;
#endif
typedef signed char int_fast8_t;
typedef unsigned char uint_fast8_t;
#ifndef _UINTPTR_T_DEFINED
typedef unsigned int uintptr_t;
typedef size_t uintptr_t;
#endif
#else