Merge remote branch 'internal/upstream-experimental' into HEAD
Conflicts: vp8/common/blockd.h Change-Id: Ica2bd1c3da614eab5ce23acfb597e777d16b3983
This commit is contained in:
commit
738a791917
@ -31,7 +31,7 @@
|
||||
The WebM project is an open source project supported by its community. For
|
||||
questions about this SDK, please mail the apps-devel@webmproject.org list.
|
||||
To contribute, see http://www.webmproject.org/code/contribute and mail
|
||||
vpx-devel@webmproject.org.
|
||||
codec-devel@webmproject.org.
|
||||
*/
|
||||
|
||||
/*!\page changelog CHANGELOG
|
||||
|
12
usage.dox
12
usage.dox
@ -25,7 +25,7 @@
|
||||
codec may write into to store details about a single instance of that codec.
|
||||
Most of the context is implementation specific, and thus opaque to the
|
||||
application. The context structure as seen by the application is of fixed
|
||||
size, and thus can be allocated eith with automatic storage or dynamically
|
||||
size, and thus can be allocated with automatic storage or dynamically
|
||||
on the heap.
|
||||
|
||||
Most operations require an initialized codec context. Codec context
|
||||
@ -74,7 +74,7 @@
|
||||
the ABI is versioned. The ABI version number must be passed at
|
||||
initialization time to ensure the application is using a header file that
|
||||
matches the library. The current ABI version number is stored in the
|
||||
prepropcessor macros #VPX_CODEC_ABI_VERSION, #VPX_ENCODER_ABI_VERSION, and
|
||||
preprocessor macros #VPX_CODEC_ABI_VERSION, #VPX_ENCODER_ABI_VERSION, and
|
||||
#VPX_DECODER_ABI_VERSION. For convenience, each initialization function has
|
||||
a wrapper macro that inserts the correct version number. These macros are
|
||||
named like the initialization methods, but without the _ver suffix.
|
||||
@ -125,7 +125,7 @@
|
||||
|
||||
The special value <code>0</code> is reserved to represent an infinite
|
||||
deadline. In this case, the codec will perform as much processing as
|
||||
possible to yeild the highest quality frame.
|
||||
possible to yield the highest quality frame.
|
||||
|
||||
By convention, the value <code>1</code> is used to mean "return as fast as
|
||||
possible."
|
||||
@ -135,7 +135,7 @@
|
||||
|
||||
/*! \page usage_xma External Memory Allocation
|
||||
Applications that wish to have fine grained control over how and where
|
||||
decoders allocate memory \ref MAY make use of the e_xternal Memory Allocation
|
||||
decoders allocate memory \ref MAY make use of the eXternal Memory Allocation
|
||||
(XMA) interface. Not all codecs support the XMA \ref usage_features.
|
||||
|
||||
To use a decoder in XMA mode, the decoder \ref MUST be initialized with the
|
||||
@ -143,7 +143,7 @@
|
||||
allocate is heavily dependent on the size of the encoded video frames. The
|
||||
size of the video must be known before requesting the decoder's memory map.
|
||||
This stream information can be obtained with the vpx_codec_peek_stream_info()
|
||||
function, which does not require a contructed decoder context. If the exact
|
||||
function, which does not require a constructed decoder context. If the exact
|
||||
stream is not known, a stream info structure can be created that reflects
|
||||
the maximum size that the decoder instance is required to support.
|
||||
|
||||
@ -175,7 +175,7 @@
|
||||
\section usage_xma_seg_szalign Segment Size and Alignment
|
||||
The sz (size) and align (alignment) parameters describe the required size
|
||||
and alignment of the requested segment. Alignment will always be a power of
|
||||
two. Applications \ref MUST honor the aligment requested. Failure to do so
|
||||
two. Applications \ref MUST honor the alignment requested. Failure to do so
|
||||
could result in program crashes or may incur a speed penalty.
|
||||
|
||||
\section usage_xma_seg_flags Segment Flags
|
||||
|
@ -12,8 +12,6 @@
|
||||
#include "blockd.h"
|
||||
#include "vpx_mem/vpx_mem.h"
|
||||
|
||||
const int vp8_block2type[25] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 1};
|
||||
|
||||
const unsigned char vp8_block2left[25] =
|
||||
{
|
||||
0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8
|
||||
|
@ -28,10 +28,6 @@ void vpx_log(const char *format, ...);
|
||||
#define DCPREDSIMTHRESH 0
|
||||
#define DCPREDCNTTHRESH 3
|
||||
|
||||
#define Y1CONTEXT 0
|
||||
#define UCONTEXT 1
|
||||
#define VCONTEXT 2
|
||||
#define Y2CONTEXT 3
|
||||
#define MB_FEATURE_TREE_PROBS 3
|
||||
|
||||
#define MAX_MB_SEGMENTS 4
|
||||
@ -48,6 +44,11 @@ typedef struct
|
||||
int r, c;
|
||||
} POS;
|
||||
|
||||
#define PLANE_TYPE_Y_NO_DC 0
|
||||
#define PLANE_TYPE_Y2 1
|
||||
#define PLANE_TYPE_UV 2
|
||||
#define PLANE_TYPE_Y_WITH_DC 3
|
||||
|
||||
|
||||
typedef char ENTROPY_CONTEXT;
|
||||
typedef struct
|
||||
@ -58,8 +59,6 @@ typedef struct
|
||||
ENTROPY_CONTEXT y2;
|
||||
} ENTROPY_CONTEXT_PLANES;
|
||||
|
||||
extern const int vp8_block2type[25];
|
||||
|
||||
extern const unsigned char vp8_block2left[25];
|
||||
extern const unsigned char vp8_block2above[25];
|
||||
|
||||
|
@ -522,7 +522,7 @@ void vp8_optimize_mb(MACROBLOCK *x, const VP8_ENCODER_RTCD *rtcd)
|
||||
|
||||
has_2nd_order = (x->e_mbd.mode_info_context->mbmi.mode != B_PRED
|
||||
&& x->e_mbd.mode_info_context->mbmi.mode != SPLITMV);
|
||||
type = has_2nd_order ? 0 : 3;
|
||||
type = has_2nd_order ? PLANE_TYPE_Y_NO_DC : PLANE_TYPE_Y_WITH_DC;
|
||||
|
||||
for (b = 0; b < 16; b++)
|
||||
{
|
||||
@ -530,23 +530,16 @@ void vp8_optimize_mb(MACROBLOCK *x, const VP8_ENCODER_RTCD *rtcd)
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
|
||||
for (b = 16; b < 20; b++)
|
||||
for (b = 16; b < 24; b++)
|
||||
{
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
vp8_optimize_b(x, b, PLANE_TYPE_UV,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
|
||||
for (b = 20; b < 24; b++)
|
||||
{
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
|
||||
|
||||
if (has_2nd_order)
|
||||
{
|
||||
b=24;
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
vp8_optimize_b(x, b, PLANE_TYPE_Y2,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
}
|
||||
@ -576,7 +569,7 @@ void vp8_optimize_mby(MACROBLOCK *x, const VP8_ENCODER_RTCD *rtcd)
|
||||
|
||||
has_2nd_order = (x->e_mbd.mode_info_context->mbmi.mode != B_PRED
|
||||
&& x->e_mbd.mode_info_context->mbmi.mode != SPLITMV);
|
||||
type = has_2nd_order ? 0 : 3;
|
||||
type = has_2nd_order ? PLANE_TYPE_Y_NO_DC : PLANE_TYPE_Y_WITH_DC;
|
||||
|
||||
for (b = 0; b < 16; b++)
|
||||
{
|
||||
@ -588,7 +581,7 @@ void vp8_optimize_mby(MACROBLOCK *x, const VP8_ENCODER_RTCD *rtcd)
|
||||
if (has_2nd_order)
|
||||
{
|
||||
b=24;
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
vp8_optimize_b(x, b, PLANE_TYPE_Y2,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
}
|
||||
@ -612,18 +605,11 @@ void vp8_optimize_mbuv(MACROBLOCK *x, const VP8_ENCODER_RTCD *rtcd)
|
||||
ta = (ENTROPY_CONTEXT *)&t_above;
|
||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
||||
|
||||
for (b = 16; b < 20; b++)
|
||||
for (b = 16; b < 24; b++)
|
||||
{
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
vp8_optimize_b(x, b, PLANE_TYPE_UV,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
|
||||
for (b = 20; b < 24; b++)
|
||||
{
|
||||
vp8_optimize_b(x, b, vp8_block2type[b],
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b], rtcd);
|
||||
}
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -560,8 +560,8 @@ void vp8_first_pass(VP8_COMP *cpi)
|
||||
YV12_BUFFER_CONFIG *gld_yv12 = &cm->yv12_fb[cm->gld_fb_idx];
|
||||
int recon_y_stride = lst_yv12->y_stride;
|
||||
int recon_uv_stride = lst_yv12->uv_stride;
|
||||
int intra_error = 0;
|
||||
int coded_error = 0;
|
||||
long long intra_error = 0;
|
||||
long long coded_error = 0;
|
||||
|
||||
int sum_mvr = 0, sum_mvc = 0;
|
||||
int sum_mvr_abs = 0, sum_mvc_abs = 0;
|
||||
@ -648,7 +648,7 @@ void vp8_first_pass(VP8_COMP *cpi)
|
||||
this_error += intrapenalty;
|
||||
|
||||
// Cumulative intra error total
|
||||
intra_error += this_error;
|
||||
intra_error += (long long)this_error;
|
||||
|
||||
// Indicate default assumption of intra in the motion map
|
||||
*fp_motion_map_ptr = 0;
|
||||
@ -800,7 +800,7 @@ void vp8_first_pass(VP8_COMP *cpi)
|
||||
}
|
||||
}
|
||||
|
||||
coded_error += this_error;
|
||||
coded_error += (long long)this_error;
|
||||
|
||||
// adjust to the next column of macroblocks
|
||||
x->src.y_buffer += 16;
|
||||
|
@ -590,10 +590,10 @@ static int vp8_rdcost_mby(MACROBLOCK *mb)
|
||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
||||
|
||||
for (b = 0; b < 16; b++)
|
||||
cost += cost_coeffs(mb, x->block + b, 0,
|
||||
cost += cost_coeffs(mb, x->block + b, PLANE_TYPE_Y_NO_DC,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b]);
|
||||
|
||||
cost += cost_coeffs(mb, x->block + 24, 1,
|
||||
cost += cost_coeffs(mb, x->block + 24, PLANE_TYPE_Y2,
|
||||
ta + vp8_block2above[24], tl + vp8_block2left[24]);
|
||||
|
||||
return cost;
|
||||
@ -645,33 +645,14 @@ static void macro_block_yrd( MACROBLOCK *mb,
|
||||
*Rate = vp8_rdcost_mby(mb);
|
||||
}
|
||||
|
||||
static void save_predictor(unsigned char *predictor, unsigned char *dst)
|
||||
static void copy_predictor(unsigned char *dst, const unsigned char *predictor)
|
||||
{
|
||||
int r, c;
|
||||
for (r = 0; r < 4; r++)
|
||||
{
|
||||
for (c = 0; c < 4; c++)
|
||||
{
|
||||
*dst = predictor[c];
|
||||
dst++;
|
||||
}
|
||||
|
||||
predictor += 16;
|
||||
}
|
||||
}
|
||||
static void restore_predictor(unsigned char *predictor, unsigned char *dst)
|
||||
{
|
||||
int r, c;
|
||||
for (r = 0; r < 4; r++)
|
||||
{
|
||||
for (c = 0; c < 4; c++)
|
||||
{
|
||||
predictor[c] = *dst;
|
||||
dst++;
|
||||
}
|
||||
|
||||
predictor += 16;
|
||||
}
|
||||
const unsigned int *p = (const unsigned int *)predictor;
|
||||
unsigned int *d = (unsigned int *)dst;
|
||||
d[0] = p[0];
|
||||
d[4] = p[4];
|
||||
d[8] = p[8];
|
||||
d[12] = p[12];
|
||||
}
|
||||
static int rd_pick_intra4x4block(
|
||||
VP8_COMP *cpi,
|
||||
@ -694,9 +675,13 @@ static int rd_pick_intra4x4block(
|
||||
|
||||
ENTROPY_CONTEXT ta = *a, tempa = *a;
|
||||
ENTROPY_CONTEXT tl = *l, templ = *l;
|
||||
|
||||
DECLARE_ALIGNED_ARRAY(16, unsigned char, predictor, 16);
|
||||
DECLARE_ALIGNED_ARRAY(16, short, dqcoeff, 16);
|
||||
/*
|
||||
* The predictor buffer is a 2d buffer with a stride of 16. Create
|
||||
* a temp buffer that meets the stride requirements, but we are only
|
||||
* interested in the left 4x4 block
|
||||
* */
|
||||
DECLARE_ALIGNED_ARRAY(16, unsigned char, best_predictor, 16*4);
|
||||
DECLARE_ALIGNED_ARRAY(16, short, best_dqcoeff, 16);
|
||||
|
||||
for (mode = B_DC_PRED; mode <= B_HU_PRED; mode++)
|
||||
{
|
||||
@ -713,7 +698,7 @@ static int rd_pick_intra4x4block(
|
||||
tempa = ta;
|
||||
templ = tl;
|
||||
|
||||
ratey = cost_coeffs(x, b, 3, &tempa, &templ);
|
||||
ratey = cost_coeffs(x, b, PLANE_TYPE_Y_WITH_DC, &tempa, &templ);
|
||||
rate += ratey;
|
||||
distortion = ENCODEMB_INVOKE(IF_RTCD(&cpi->rtcd.encodemb), berr)(be->coeff, b->dqcoeff) >> 2;
|
||||
|
||||
@ -728,21 +713,17 @@ static int rd_pick_intra4x4block(
|
||||
*best_mode = mode;
|
||||
*a = tempa;
|
||||
*l = templ;
|
||||
save_predictor(b->predictor, predictor);
|
||||
vpx_memcpy(dqcoeff, b->dqcoeff, 32);
|
||||
copy_predictor(best_predictor, b->predictor);
|
||||
vpx_memcpy(best_dqcoeff, b->dqcoeff, 32);
|
||||
}
|
||||
}
|
||||
|
||||
b->bmi.mode = (B_PREDICTION_MODE)(*best_mode);
|
||||
|
||||
restore_predictor(b->predictor, predictor);
|
||||
vpx_memcpy(b->dqcoeff, dqcoeff, 32);
|
||||
|
||||
IDCT_INVOKE(IF_RTCD(&cpi->rtcd.common->idct), idct16)(b->dqcoeff, b->diff, 32);
|
||||
RECON_INVOKE(IF_RTCD(&cpi->rtcd.common->recon), recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
|
||||
IDCT_INVOKE(IF_RTCD(&cpi->rtcd.common->idct), idct16)(best_dqcoeff, b->diff, 32);
|
||||
RECON_INVOKE(IF_RTCD(&cpi->rtcd.common->recon), recon)(best_predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
|
||||
|
||||
return best_rd;
|
||||
|
||||
}
|
||||
|
||||
int vp8_rd_pick_intra4x4mby_modes(VP8_COMP *cpi, MACROBLOCK *mb, int *Rate,
|
||||
@ -753,7 +734,7 @@ int vp8_rd_pick_intra4x4mby_modes(VP8_COMP *cpi, MACROBLOCK *mb, int *Rate,
|
||||
int cost = mb->mbmode_cost [xd->frame_type] [B_PRED];
|
||||
int distortion = 0;
|
||||
int tot_rate_y = 0;
|
||||
int total_rd = 0;
|
||||
long long total_rd = 0;
|
||||
ENTROPY_CONTEXT_PLANES t_above, t_left;
|
||||
ENTROPY_CONTEXT *ta;
|
||||
ENTROPY_CONTEXT *tl;
|
||||
@ -794,12 +775,12 @@ int vp8_rd_pick_intra4x4mby_modes(VP8_COMP *cpi, MACROBLOCK *mb, int *Rate,
|
||||
tot_rate_y += ry;
|
||||
mic->bmi[i].mode = xd->block[i].bmi.mode = best_mode;
|
||||
|
||||
if(total_rd >= best_rd)
|
||||
break;
|
||||
if(total_rd >= (long long)best_rd)
|
||||
break;
|
||||
}
|
||||
|
||||
if(total_rd >= best_rd)
|
||||
return INT_MAX;
|
||||
if(total_rd >= (long long)best_rd)
|
||||
return INT_MAX;
|
||||
|
||||
*Rate = cost;
|
||||
*rate_y += tot_rate_y;
|
||||
@ -862,12 +843,8 @@ static int rd_cost_mbuv(MACROBLOCK *mb)
|
||||
ta = (ENTROPY_CONTEXT *)&t_above;
|
||||
tl = (ENTROPY_CONTEXT *)&t_left;
|
||||
|
||||
for (b = 16; b < 20; b++)
|
||||
cost += cost_coeffs(mb, x->block + b, vp8_block2type[b],
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b]);
|
||||
|
||||
for (b = 20; b < 24; b++)
|
||||
cost += cost_coeffs(mb, x->block + b, vp8_block2type[b],
|
||||
for (b = 16; b < 24; b++)
|
||||
cost += cost_coeffs(mb, x->block + b, PLANE_TYPE_UV,
|
||||
ta + vp8_block2above[b], tl + vp8_block2left[b]);
|
||||
|
||||
return cost;
|
||||
@ -1048,7 +1025,7 @@ static int rdcost_mbsegment_y(MACROBLOCK *mb, const int *labels,
|
||||
|
||||
for (b = 0; b < 16; b++)
|
||||
if (labels[ b] == which_label)
|
||||
cost += cost_coeffs(mb, x->block + b, 3,
|
||||
cost += cost_coeffs(mb, x->block + b, PLANE_TYPE_Y_WITH_DC,
|
||||
ta + vp8_block2above[b],
|
||||
tl + vp8_block2left[b]);
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file decoder_impl.h
|
||||
/*!\file
|
||||
* \brief Describes the decoder algorithm interface for algorithm
|
||||
* implementations.
|
||||
*
|
||||
@ -214,7 +214,7 @@ typedef vpx_image_t*(*vpx_codec_get_frame_fn_t)(vpx_codec_alg_priv_t *ctx,
|
||||
vpx_codec_iter_t *iter);
|
||||
|
||||
|
||||
/*\brief e_xternal Memory Allocation memory map get iterator
|
||||
/*\brief eXternal Memory Allocation memory map get iterator
|
||||
*
|
||||
* Iterates over a list of the memory maps requested by the decoder. The
|
||||
* iterator storage should be initialized to NULL to start the iteration.
|
||||
@ -230,7 +230,7 @@ typedef vpx_codec_err_t (*vpx_codec_get_mmap_fn_t)(const vpx_codec_ctx_t *c
|
||||
vpx_codec_iter_t *iter);
|
||||
|
||||
|
||||
/*\brief e_xternal Memory Allocation memory map set iterator
|
||||
/*\brief eXternal Memory Allocation memory map set iterator
|
||||
*
|
||||
* Sets a memory descriptor inside the decoder instance.
|
||||
*
|
||||
@ -405,7 +405,7 @@ vpx_codec_iface_t id##_algo
|
||||
|
||||
/* Internal Utility Functions
|
||||
*
|
||||
* The following functions are indended to be used inside algorithms as
|
||||
* The following functions are intended to be used inside algorithms as
|
||||
* utilities for manipulating vpx_codec_* data structures.
|
||||
*/
|
||||
struct vpx_codec_pkt_list
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file vpx_decoder.c
|
||||
/*!\file
|
||||
* \brief Provides the high level interface to wrap decoder algorithms.
|
||||
*
|
||||
*/
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file vpx_decoder.c
|
||||
/*!\file
|
||||
* \brief Provides the high level interface to wrap decoder algorithms.
|
||||
*
|
||||
*/
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file vpx_decoder.c
|
||||
/*!\file
|
||||
* \brief Provides the high level interface to wrap decoder algorithms.
|
||||
*
|
||||
*/
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file vpx_encoder.c
|
||||
/*!\file
|
||||
* \brief Provides the high level interface to wrap encoder algorithms.
|
||||
*
|
||||
*/
|
||||
|
@ -14,7 +14,7 @@
|
||||
* VP8 is vpx's newest video compression algorithm that uses motion
|
||||
* compensated prediction, Discrete Cosine Transform (DCT) coding of the
|
||||
* prediction error signal and context dependent entropy coding techniques
|
||||
* based on arithmatic principles. It features:
|
||||
* based on arithmetic principles. It features:
|
||||
* - YUV 4:2:0 image format
|
||||
* - Macro-block based coding (16x16 luma plus two 8x8 chroma)
|
||||
* - 1/4 (1/8) pixel accuracy motion compensated prediction
|
||||
@ -25,7 +25,7 @@
|
||||
*
|
||||
* @{
|
||||
*/
|
||||
/*!\file vp8.h
|
||||
/*!\file
|
||||
* \brief Provides controls common to both the VP8 encoder and decoder.
|
||||
*/
|
||||
#ifndef VP8_H
|
||||
@ -67,7 +67,7 @@ enum vp8_postproc_level
|
||||
/*!\brief post process flags
|
||||
*
|
||||
* This define a structure that describe the post processing settings. For
|
||||
* the best objective measure (using thet PSNR metric) set post_proc_flag
|
||||
* the best objective measure (using the PSNR metric) set post_proc_flag
|
||||
* to VP8_DEBLOCK and deblocking_level to 1.
|
||||
*/
|
||||
|
||||
@ -101,7 +101,7 @@ typedef struct vpx_ref_frame
|
||||
} vpx_ref_frame_t;
|
||||
|
||||
|
||||
/*!\brief vp8 decoder control funciton parameter type
|
||||
/*!\brief vp8 decoder control function parameter type
|
||||
*
|
||||
* defines the data type for each of VP8 decoder control function requires
|
||||
*/
|
||||
|
@ -16,7 +16,7 @@
|
||||
*/
|
||||
#include "vp8.h"
|
||||
|
||||
/*!\file vp8cx.h
|
||||
/*!\file
|
||||
* \brief Provides definitions for using the VP8 encoder algorithm within the
|
||||
* vpx Codec Interface.
|
||||
*/
|
||||
|
@ -16,7 +16,7 @@
|
||||
*
|
||||
* @{
|
||||
*/
|
||||
/*!\file vp8dx.h
|
||||
/*!\file
|
||||
* \brief Provides definitions for using the VP8 algorithm within the vpx Decoder
|
||||
* interface.
|
||||
*/
|
||||
|
@ -16,7 +16,7 @@
|
||||
* @{
|
||||
*/
|
||||
|
||||
/*!\file vpx_codec.h
|
||||
/*!\file
|
||||
* \brief Describes the codec algorithm interface to applications.
|
||||
*
|
||||
* This file describes the interface between an application and a
|
||||
@ -145,7 +145,7 @@ extern "C" {
|
||||
typedef long vpx_codec_caps_t;
|
||||
#define VPX_CODEC_CAP_DECODER 0x1 /**< Is a decoder */
|
||||
#define VPX_CODEC_CAP_ENCODER 0x2 /**< Is an encoder */
|
||||
#define VPX_CODEC_CAP_XMA 0x4 /**< Supports e_xternal Memory Allocation */
|
||||
#define VPX_CODEC_CAP_XMA 0x4 /**< Supports eXternal Memory Allocation */
|
||||
|
||||
|
||||
/*! \brief Initialization-time Feature Enabling
|
||||
@ -156,7 +156,7 @@ extern "C" {
|
||||
* The available flags are specified by VPX_CODEC_USE_* defines.
|
||||
*/
|
||||
typedef long vpx_codec_flags_t;
|
||||
#define VPX_CODEC_USE_XMA 0x00000001 /**< Use e_xternal Memory Allocation mode */
|
||||
#define VPX_CODEC_USE_XMA 0x00000001 /**< Use eXternal Memory Allocation mode */
|
||||
|
||||
|
||||
/*!\brief Codec interface structure.
|
||||
@ -232,7 +232,7 @@ extern "C" {
|
||||
/*!\brief Return the version major number */
|
||||
#define vpx_codec_version_major() ((vpx_codec_version()>>16)&0xff)
|
||||
|
||||
/*!\brief Return the version minr number */
|
||||
/*!\brief Return the version minor number */
|
||||
#define vpx_codec_version_minor() ((vpx_codec_version()>>8)&0xff)
|
||||
|
||||
/*!\brief Return the version patch number */
|
||||
@ -338,9 +338,9 @@ extern "C" {
|
||||
|
||||
/*!\brief Get the capabilities of an algorithm.
|
||||
*
|
||||
* Retrieves the capabliities bitfield from the algorithm's interface.
|
||||
* Retrieves the capabilities bitfield from the algorithm's interface.
|
||||
*
|
||||
* \param[in] iface Pointer to the alogrithm interface
|
||||
* \param[in] iface Pointer to the algorithm interface
|
||||
*
|
||||
*/
|
||||
vpx_codec_caps_t vpx_codec_get_caps(vpx_codec_iface_t *iface);
|
||||
@ -354,7 +354,7 @@ extern "C" {
|
||||
*
|
||||
* This wrapper function dispatches the request to the helper function
|
||||
* associated with the given ctrl_id. It tries to call this function
|
||||
* transparantly, but will return #VPX_CODEC_ERROR if the request could not
|
||||
* transparently, but will return #VPX_CODEC_ERROR if the request could not
|
||||
* be dispatched.
|
||||
*
|
||||
* Note that this function should not be used directly. Call the
|
||||
@ -525,7 +525,7 @@ extern "C" {
|
||||
* passed in the order they are read from vpx_codec_get_mem_map(), but may be
|
||||
* passed in groups of any size. Segments \ref MUST be set only once. The
|
||||
* allocation function \ref MUST ensure that the vpx_codec_mmap_t::base member
|
||||
* is non-NULL. If the segment requires cleanup handling (eg, calling free()
|
||||
* is non-NULL. If the segment requires cleanup handling (e.g., calling free()
|
||||
* or close()) then the vpx_codec_mmap_t::dtor member \ref MUST be populated.
|
||||
*
|
||||
* \param[in] ctx Pointer to this instance's context.
|
||||
|
@ -17,7 +17,7 @@
|
||||
* @{
|
||||
*/
|
||||
|
||||
/*!\file vpx_decoder.h
|
||||
/*!\file
|
||||
* \brief Describes the decoder algorithm interface to applications.
|
||||
*
|
||||
* This file describes the interface between an application and a
|
||||
@ -48,7 +48,7 @@ extern "C" {
|
||||
* ::vpx_codec_iface_t interface structure. Capabilities are extra interfaces
|
||||
* or functionality, and are not required to be supported by a decoder.
|
||||
*
|
||||
* The available flags are specifiedby VPX_CODEC_CAP_* defines.
|
||||
* The available flags are specified by VPX_CODEC_CAP_* defines.
|
||||
*/
|
||||
#define VPX_CODEC_CAP_PUT_SLICE 0x10000 /**< Will issue put_slice callbacks */
|
||||
#define VPX_CODEC_CAP_PUT_FRAME 0x20000 /**< Will issue put_frame callbacks */
|
||||
@ -109,7 +109,7 @@ extern "C" {
|
||||
* 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 alogrithm interface to use.
|
||||
* \param[in] iface Pointer to the algorithm interface to use.
|
||||
* \param[in] cfg Configuration to use, if known. May be NULL.
|
||||
* \param[in] flags Bitfield of VPX_CODEC_USE_* flags
|
||||
* \param[in] ver ABI version number. Must be set to
|
||||
@ -139,7 +139,7 @@ extern "C" {
|
||||
* context is not necessary. Can be used to determine if the bitstream is
|
||||
* of the proper format, and to extract information from the stream.
|
||||
*
|
||||
* \param[in] iface Pointer to the alogrithm interface
|
||||
* \param[in] iface Pointer to the algorithm interface
|
||||
* \param[in] data Pointer to a block of data to parse
|
||||
* \param[in] data_sz Size of the data buffer
|
||||
* \param[in,out] si Pointer to stream info to update. The size member
|
||||
|
@ -16,7 +16,7 @@
|
||||
* @{
|
||||
*/
|
||||
|
||||
/*!\file vpx_decoder_compat.h
|
||||
/*!\file
|
||||
* \brief Provides a compatibility layer between version 1 and 2 of this API.
|
||||
*
|
||||
* This interface has been deprecated. Only existing code should make use
|
||||
@ -89,12 +89,12 @@ extern "C" {
|
||||
* ::vpx_dec_iface_t interface structure. Capabilities are extra interfaces
|
||||
* or functionality, and are not required to be supported by a decoder.
|
||||
*
|
||||
* The available flags are specifiedby VPX_DEC_CAP_* defines.
|
||||
* The available flags are specified by VPX_DEC_CAP_* defines.
|
||||
*/
|
||||
typedef int vpx_dec_caps_t;
|
||||
#define VPX_DEC_CAP_PUT_SLICE 0x0001 /**< Will issue put_slice callbacks */
|
||||
#define VPX_DEC_CAP_PUT_FRAME 0x0002 /**< Will issue put_frame callbacks */
|
||||
#define VPX_DEC_CAP_XMA 0x0004 /**< Supports e_xternal Memory Allocation */
|
||||
#define VPX_DEC_CAP_XMA 0x0004 /**< Supports eXternal Memory Allocation */
|
||||
|
||||
/*!\brief Stream properties
|
||||
*
|
||||
@ -222,7 +222,7 @@ extern "C" {
|
||||
* is properly initialized.
|
||||
*
|
||||
* \param[in] ctx Pointer to this instance's context.
|
||||
* \param[in] iface Pointer to the alogrithm interface to use.
|
||||
* \param[in] iface Pointer to the algorithm interface to use.
|
||||
* \param[in] ver ABI version number. Must be set to
|
||||
* VPX_DECODER_ABI_VERSION
|
||||
* \retval #VPX_DEC_OK
|
||||
@ -253,9 +253,9 @@ extern "C" {
|
||||
|
||||
/*!\brief Get the capabilities of an algorithm.
|
||||
*
|
||||
* Retrieves the capabliities bitfield from the algorithm's interface.
|
||||
* Retrieves the capabilities bitfield from the algorithm's interface.
|
||||
*
|
||||
* \param[in] iface Pointer to the alogrithm interface
|
||||
* \param[in] iface Pointer to the algorithm interface
|
||||
*
|
||||
*/
|
||||
vpx_dec_caps_t vpx_dec_get_caps(vpx_dec_iface_t *iface) DEPRECATED;
|
||||
@ -267,7 +267,7 @@ extern "C" {
|
||||
* context is not necessary. Can be used to determine if the bitstream is
|
||||
* of the proper format, and to extract information from the stream.
|
||||
*
|
||||
* \param[in] iface Pointer to the alogrithm interface
|
||||
* \param[in] iface Pointer to the algorithm interface
|
||||
* \param[in] data Pointer to a block of data to parse
|
||||
* \param[in] data_sz Size of the data buffer
|
||||
* \param[in,out] si Pointer to stream info to update. The size member
|
||||
@ -309,7 +309,7 @@ extern "C" {
|
||||
*
|
||||
* This wrapper function dispatches the request to the helper function
|
||||
* associated with the given ctrl_id. It tries to call this function
|
||||
* transparantly, but will return #VPX_DEC_ERROR if the request could not
|
||||
* transparently, but will return #VPX_DEC_ERROR if the request could not
|
||||
* be dispatched.
|
||||
*
|
||||
* \param[in] ctx Pointer to this instance's context
|
||||
@ -507,7 +507,7 @@ extern "C" {
|
||||
* is properly initialized.
|
||||
*
|
||||
* \param[in] ctx Pointer to this instance's context.
|
||||
* \param[in] iface Pointer to the alogrithm interface to use.
|
||||
* \param[in] iface Pointer to the algorithm interface to use.
|
||||
* \param[in] ver ABI version number. Must be set to
|
||||
* VPX_DECODER_ABI_VERSION
|
||||
* \retval #VPX_DEC_OK
|
||||
@ -558,7 +558,7 @@ extern "C" {
|
||||
* passed in the order they are read from vpx_dec_get_mem_map(), but may be
|
||||
* passed in groups of any size. Segments \ref MUST be set only once. The
|
||||
* allocation function \ref MUST ensure that the vpx_dec_mmap_t::base member
|
||||
* is non-NULL. If the segment requires cleanup handling (eg, calling free()
|
||||
* is non-NULL. If the segment requires cleanup handling (e.g., calling free()
|
||||
* or close()) then the vpx_dec_mmap_t::dtor member \ref MUST be populated.
|
||||
*
|
||||
* \param[in] ctx Pointer to this instance's context.
|
||||
|
@ -17,7 +17,7 @@
|
||||
* @{
|
||||
*/
|
||||
|
||||
/*!\file vpx_encoder.h
|
||||
/*!\file
|
||||
* \brief Describes the encoder algorithm interface to applications.
|
||||
*
|
||||
* This file describes the interface between an application and a
|
||||
@ -51,7 +51,7 @@ extern "C" {
|
||||
* interfaces or functionality, and are not required to be supported
|
||||
* by an encoder.
|
||||
*
|
||||
* The available flags are specifiedby VPX_CODEC_CAP_* defines.
|
||||
* The available flags are specified by VPX_CODEC_CAP_* defines.
|
||||
*/
|
||||
#define VPX_CODEC_CAP_PSNR 0x10000 /**< Can issue PSNR packets */
|
||||
|
||||
@ -147,7 +147,7 @@ extern "C" {
|
||||
|
||||
/* This packet size is fixed to allow codecs to extend this
|
||||
* interface without having to manage storage for raw packets,
|
||||
* ie if it's smaller than 128 bytes, you can store in the
|
||||
* i.e., if it's smaller than 128 bytes, you can store in the
|
||||
* packet list directly.
|
||||
*/
|
||||
char pad[128 - sizeof(enum vpx_codec_cx_pkt_kind)]; /**< fixed sz */
|
||||
|
@ -9,7 +9,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*!\file vpx_image.h
|
||||
/*!\file
|
||||
* \brief Describes the vpx image descriptor and associated operations
|
||||
*
|
||||
*/
|
||||
@ -33,7 +33,7 @@ extern "C" {
|
||||
|
||||
#define VPX_IMG_FMT_PLANAR 0x100 /**< Image is a planar format */
|
||||
#define VPX_IMG_FMT_UV_FLIP 0x200 /**< V plane precedes U plane in memory */
|
||||
#define VPX_IMG_FMT_HAS_ALPHA 0x400 /**< Image has an alpha channel componnent */
|
||||
#define VPX_IMG_FMT_HAS_ALPHA 0x400 /**< Image has an alpha channel component */
|
||||
|
||||
|
||||
/*!\brief List of supported image formats */
|
||||
@ -115,7 +115,7 @@ extern "C" {
|
||||
#define VPX_PLANE_Y 0 /**< Y (Luminance) plane */
|
||||
#define VPX_PLANE_U 1 /**< U (Chroma) plane */
|
||||
#define VPX_PLANE_V 2 /**< V (Chroma) plane */
|
||||
#define VPX_PLANE_ALPHA 3 /**< A (Transparancy) plane */
|
||||
#define VPX_PLANE_ALPHA 3 /**< A (Transparency) plane */
|
||||
#if !defined(VPX_CODEC_DISABLE_COMPAT) || !VPX_CODEC_DISABLE_COMPAT
|
||||
#define PLANE_PACKED VPX_PLANE_PACKED
|
||||
#define PLANE_Y VPX_PLANE_Y
|
||||
|
@ -9,10 +9,10 @@
|
||||
*/
|
||||
|
||||
|
||||
/* \file mem_ops.h
|
||||
* \brief Provides portable memory access primatives
|
||||
/* \file
|
||||
* \brief Provides portable memory access primitives
|
||||
*
|
||||
* This function provides portable primatives for getting and setting of
|
||||
* This function provides portable primitives for getting and setting of
|
||||
* signed and unsigned integers in 16, 24, and 32 bit sizes. The operations
|
||||
* can be performed on unaligned data regardless of hardware support for
|
||||
* unaligned accesses.
|
||||
|
@ -9,12 +9,12 @@
|
||||
*/
|
||||
|
||||
|
||||
/* \file mem_ops_aligned.h
|
||||
* \brief Provides portable memory access primatives for operating on aligned
|
||||
/* \file
|
||||
* \brief Provides portable memory access primitives for operating on aligned
|
||||
* data
|
||||
*
|
||||
* This file is split from mem_ops.h for easier maintainence. See mem_ops.h
|
||||
* for a more detailed description of these primatives.
|
||||
* This file is split from mem_ops.h for easier maintenance. See mem_ops.h
|
||||
* for a more detailed description of these primitives.
|
||||
*/
|
||||
#ifndef INCLUDED_BY_MEM_OPS_H
|
||||
#error Include mem_ops.h, not mem_ops_aligned.h directly.
|
||||
|
Loading…
x
Reference in New Issue
Block a user