vp8_yv12 -> vpx_yv12
Change-Id: Ifbf24b99a841b7f7b5bff78b8830ccaed0d38170
This commit is contained in:
@@ -171,7 +171,7 @@ vpx_codec_err_t vp10_copy_reference_dec(VP10Decoder *pbi,
|
|||||||
vpx_internal_error(&cm->error, VPX_CODEC_ERROR,
|
vpx_internal_error(&cm->error, VPX_CODEC_ERROR,
|
||||||
"Incorrect buffer dimensions");
|
"Incorrect buffer dimensions");
|
||||||
else
|
else
|
||||||
vp8_yv12_copy_frame(cfg, sd);
|
vpx_yv12_copy_frame(cfg, sd);
|
||||||
} else {
|
} else {
|
||||||
vpx_internal_error(&cm->error, VPX_CODEC_ERROR,
|
vpx_internal_error(&cm->error, VPX_CODEC_ERROR,
|
||||||
"Invalid reference frame");
|
"Invalid reference frame");
|
||||||
@@ -221,7 +221,7 @@ vpx_codec_err_t vp10_set_reference_dec(VP10_COMMON *cm,
|
|||||||
// Manage the reference counters and copy image.
|
// Manage the reference counters and copy image.
|
||||||
ref_cnt_fb(frame_bufs, ref_fb_ptr, free_fb);
|
ref_cnt_fb(frame_bufs, ref_fb_ptr, free_fb);
|
||||||
ref_buf->buf = &frame_bufs[*ref_fb_ptr].buf;
|
ref_buf->buf = &frame_bufs[*ref_fb_ptr].buf;
|
||||||
vp8_yv12_copy_frame(sd, ref_buf->buf);
|
vpx_yv12_copy_frame(sd, ref_buf->buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
return cm->error.error_code;
|
return cm->error.error_code;
|
||||||
|
@@ -2285,7 +2285,7 @@ int vp10_copy_reference_enc(VP10_COMP *cpi, VPX_REFFRAME ref_frame_flag,
|
|||||||
YV12_BUFFER_CONFIG *sd) {
|
YV12_BUFFER_CONFIG *sd) {
|
||||||
YV12_BUFFER_CONFIG *cfg = get_vp10_ref_frame_buffer(cpi, ref_frame_flag);
|
YV12_BUFFER_CONFIG *cfg = get_vp10_ref_frame_buffer(cpi, ref_frame_flag);
|
||||||
if (cfg) {
|
if (cfg) {
|
||||||
vp8_yv12_copy_frame(cfg, sd);
|
vpx_yv12_copy_frame(cfg, sd);
|
||||||
return 0;
|
return 0;
|
||||||
} else {
|
} else {
|
||||||
return -1;
|
return -1;
|
||||||
@@ -2296,7 +2296,7 @@ int vp10_set_reference_enc(VP10_COMP *cpi, VPX_REFFRAME ref_frame_flag,
|
|||||||
YV12_BUFFER_CONFIG *sd) {
|
YV12_BUFFER_CONFIG *sd) {
|
||||||
YV12_BUFFER_CONFIG *cfg = get_vp10_ref_frame_buffer(cpi, ref_frame_flag);
|
YV12_BUFFER_CONFIG *cfg = get_vp10_ref_frame_buffer(cpi, ref_frame_flag);
|
||||||
if (cfg) {
|
if (cfg) {
|
||||||
vp8_yv12_copy_frame(sd, cfg);
|
vpx_yv12_copy_frame(sd, cfg);
|
||||||
return 0;
|
return 0;
|
||||||
} else {
|
} else {
|
||||||
return -1;
|
return -1;
|
||||||
|
@@ -25,7 +25,7 @@
|
|||||||
(void*)(((size_t)(addr) + ((align) - 1)) & (size_t)-(align))
|
(void*)(((size_t)(addr) + ((align) - 1)) & (size_t)-(align))
|
||||||
|
|
||||||
int
|
int
|
||||||
vp8_yv12_de_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf) {
|
vpx_yv12_de_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf) {
|
||||||
if (ybf) {
|
if (ybf) {
|
||||||
// If libvpx is using frame buffer callbacks then buffer_alloc_sz must
|
// If libvpx is using frame buffer callbacks then buffer_alloc_sz must
|
||||||
// not be set.
|
// not be set.
|
||||||
@@ -44,7 +44,7 @@ vp8_yv12_de_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf) {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int vp8_yv12_realloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
int vpx_yv12_realloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
||||||
int width, int height, int border) {
|
int width, int height, int border) {
|
||||||
if (ybf) {
|
if (ybf) {
|
||||||
int aligned_width = (width + 15) & ~15;
|
int aligned_width = (width + 15) & ~15;
|
||||||
@@ -105,11 +105,11 @@ int vp8_yv12_realloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
|||||||
return -2;
|
return -2;
|
||||||
}
|
}
|
||||||
|
|
||||||
int vp8_yv12_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
int vpx_yv12_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
||||||
int width, int height, int border) {
|
int width, int height, int border) {
|
||||||
if (ybf) {
|
if (ybf) {
|
||||||
vp8_yv12_de_alloc_frame_buffer(ybf);
|
vpx_yv12_de_alloc_frame_buffer(ybf);
|
||||||
return vp8_yv12_realloc_frame_buffer(ybf, width, height, border);
|
return vpx_yv12_realloc_frame_buffer(ybf, width, height, border);
|
||||||
}
|
}
|
||||||
return -2;
|
return -2;
|
||||||
}
|
}
|
||||||
|
@@ -104,7 +104,7 @@ static void extend_plane_high(uint8_t *const src8, int src_stride,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void vp8_yv12_extend_frame_borders_c(YV12_BUFFER_CONFIG *ybf) {
|
void vpx_yv12_extend_frame_borders_c(YV12_BUFFER_CONFIG *ybf) {
|
||||||
const int uv_border = ybf->border / 2;
|
const int uv_border = ybf->border / 2;
|
||||||
|
|
||||||
assert(ybf->border % 2 == 0);
|
assert(ybf->border % 2 == 0);
|
||||||
@@ -222,7 +222,7 @@ void memcpy_short_addr(uint8_t *dst8, const uint8_t *src8, int num) {
|
|||||||
// Copies the source image into the destination image and updates the
|
// Copies the source image into the destination image and updates the
|
||||||
// destination's UMV borders.
|
// destination's UMV borders.
|
||||||
// Note: The frames are assumed to be identical in size.
|
// Note: The frames are assumed to be identical in size.
|
||||||
void vp8_yv12_copy_frame_c(const YV12_BUFFER_CONFIG *src_ybc,
|
void vpx_yv12_copy_frame_c(const YV12_BUFFER_CONFIG *src_ybc,
|
||||||
YV12_BUFFER_CONFIG *dst_ybc) {
|
YV12_BUFFER_CONFIG *dst_ybc) {
|
||||||
int row;
|
int row;
|
||||||
const uint8_t *src = src_ybc->y_buffer;
|
const uint8_t *src = src_ybc->y_buffer;
|
||||||
@@ -263,7 +263,7 @@ void vp8_yv12_copy_frame_c(const YV12_BUFFER_CONFIG *src_ybc,
|
|||||||
dst += dst_ybc->uv_stride;
|
dst += dst_ybc->uv_stride;
|
||||||
}
|
}
|
||||||
|
|
||||||
vp8_yv12_extend_frame_borders_c(dst_ybc);
|
vpx_yv12_extend_frame_borders_c(dst_ybc);
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
assert(!(dst_ybc->flags & YV12_FLAG_HIGHBITDEPTH));
|
assert(!(dst_ybc->flags & YV12_FLAG_HIGHBITDEPTH));
|
||||||
@@ -294,7 +294,7 @@ void vp8_yv12_copy_frame_c(const YV12_BUFFER_CONFIG *src_ybc,
|
|||||||
dst += dst_ybc->uv_stride;
|
dst += dst_ybc->uv_stride;
|
||||||
}
|
}
|
||||||
|
|
||||||
vp8_yv12_extend_frame_borders_c(dst_ybc);
|
vpx_yv12_extend_frame_borders_c(dst_ybc);
|
||||||
}
|
}
|
||||||
|
|
||||||
void vpx_yv12_copy_y_c(const YV12_BUFFER_CONFIG *src_ybc,
|
void vpx_yv12_copy_y_c(const YV12_BUFFER_CONFIG *src_ybc,
|
||||||
|
@@ -16,9 +16,9 @@ if (vpx_config("CONFIG_SPATIAL_RESAMPLING") eq "yes") {
|
|||||||
add_proto qw/void vp8_vertical_band_2_1_scale_i/, "unsigned char *source, unsigned int src_pitch, unsigned char *dest, unsigned int dest_pitch, unsigned int dest_width";
|
add_proto qw/void vp8_vertical_band_2_1_scale_i/, "unsigned char *source, unsigned int src_pitch, unsigned char *dest, unsigned int dest_pitch, unsigned int dest_width";
|
||||||
}
|
}
|
||||||
|
|
||||||
add_proto qw/void vp8_yv12_extend_frame_borders/, "struct yv12_buffer_config *ybf";
|
add_proto qw/void vpx_yv12_extend_frame_borders/, "struct yv12_buffer_config *ybf";
|
||||||
|
|
||||||
add_proto qw/void vp8_yv12_copy_frame/, "const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc";
|
add_proto qw/void vpx_yv12_copy_frame/, "const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc";
|
||||||
|
|
||||||
add_proto qw/void vpx_yv12_copy_y/, "const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc";
|
add_proto qw/void vpx_yv12_copy_y/, "const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc";
|
||||||
|
|
||||||
|
@@ -66,11 +66,11 @@ typedef struct yv12_buffer_config {
|
|||||||
|
|
||||||
#define YV12_FLAG_HIGHBITDEPTH 8
|
#define YV12_FLAG_HIGHBITDEPTH 8
|
||||||
|
|
||||||
int vp8_yv12_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
int vpx_yv12_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
||||||
int width, int height, int border);
|
int width, int height, int border);
|
||||||
int vp8_yv12_realloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
int vpx_yv12_realloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
||||||
int width, int height, int border);
|
int width, int height, int border);
|
||||||
int vp8_yv12_de_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf);
|
int vpx_yv12_de_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf);
|
||||||
|
|
||||||
int vpx_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
int vpx_alloc_frame_buffer(YV12_BUFFER_CONFIG *ybf,
|
||||||
int width, int height, int ss_x, int ss_y,
|
int width, int height, int ss_x, int ss_y,
|
||||||
|
Reference in New Issue
Block a user