encoder: remove postproc dependency
Remove the dependency on postproc.c for the encoder in general, the only unchecked need for it is when CONFIG_PSNR is enabled. All other cases are already wrapped in CONFIG_POSTPROC. In the CONFIG_PSNR case the file will still be included. Additionally, when VP8_SET_POSTPROC is used with the encoder when post processing has been disabled an error will be returned. This addresses issue #153. Change-Id: Ia6dfe20167f7077734a6058cbd1d794550346089
This commit is contained in:
Родитель
7a3e0a1d93
Коммит
76640f85da
|
@ -126,11 +126,13 @@ void vp8_machine_specific_config(VP8_COMMON *ctx)
|
|||
rtcd->loopfilter.simple_b_h = vp8_loop_filter_bhs_c;
|
||||
#endif
|
||||
|
||||
#if CONFIG_POSTPROC || (CONFIG_VP8_ENCODER && CONFIG_PSNR)
|
||||
rtcd->postproc.down = vp8_mbpost_proc_down_c;
|
||||
rtcd->postproc.across = vp8_mbpost_proc_across_ip_c;
|
||||
rtcd->postproc.downacross = vp8_post_proc_down_and_across_c;
|
||||
rtcd->postproc.addnoise = vp8_plane_add_noise_c;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if HAVE_ARMV7
|
||||
vp8_build_intra_predictors_mby_ptr = vp8_build_intra_predictors_mby_neon;
|
||||
|
|
|
@ -61,7 +61,7 @@ void vp8_machine_specific_config(VP8_COMMON *ctx)
|
|||
rtcd->loopfilter.simple_mb_h = vp8_loop_filter_mbhs_c;
|
||||
rtcd->loopfilter.simple_b_h = vp8_loop_filter_bhs_c;
|
||||
|
||||
#if CONFIG_POSTPROC || CONFIG_VP8_ENCODER
|
||||
#if CONFIG_POSTPROC || (CONFIG_VP8_ENCODER && CONFIG_PSNR)
|
||||
rtcd->postproc.down = vp8_mbpost_proc_down_c;
|
||||
rtcd->postproc.across = vp8_mbpost_proc_across_ip_c;
|
||||
rtcd->postproc.downacross = vp8_post_proc_down_and_across_c;
|
||||
|
|
|
@ -96,8 +96,6 @@ VP8_COMMON_SRCS-$(ARCH_X86)$(ARCH_X86_64) += common/x86/vp8_asm_stubs.c
|
|||
VP8_COMMON_SRCS-$(ARCH_X86)$(ARCH_X86_64) += common/x86/loopfilter_x86.c
|
||||
VP8_COMMON_SRCS-$(CONFIG_POSTPROC) += common/postproc.h
|
||||
VP8_COMMON_SRCS-$(CONFIG_POSTPROC) += common/postproc.c
|
||||
VP8_COMMON_SRCS-$(CONFIG_VP8_ENCODER) += common/postproc.h
|
||||
VP8_COMMON_SRCS-$(CONFIG_VP8_ENCODER) += common/postproc.c
|
||||
VP8_COMMON_SRCS-$(HAVE_MMX) += common/x86/idctllm_mmx.asm
|
||||
VP8_COMMON_SRCS-$(HAVE_MMX) += common/x86/iwalsh_mmx.asm
|
||||
VP8_COMMON_SRCS-$(HAVE_MMX) += common/x86/recon_mmx.asm
|
||||
|
|
|
@ -826,7 +826,9 @@ static vpx_codec_err_t vp8e_set_previewpp(vpx_codec_alg_priv_t *ctx,
|
|||
int ctr_id,
|
||||
va_list args)
|
||||
{
|
||||
#if CONFIG_POSTPROC
|
||||
vp8_postproc_cfg_t *data = va_arg(args, vp8_postproc_cfg_t *);
|
||||
(void)ctr_id;
|
||||
|
||||
if (data)
|
||||
{
|
||||
|
@ -835,6 +837,12 @@ static vpx_codec_err_t vp8e_set_previewpp(vpx_codec_alg_priv_t *ctx,
|
|||
}
|
||||
else
|
||||
return VPX_CODEC_INVALID_PARAM;
|
||||
#else
|
||||
(void)ctx;
|
||||
(void)ctr_id;
|
||||
(void)args;
|
||||
return VPX_CODEC_INCAPABLE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -80,6 +80,8 @@ VP8_CX_SRCS-$(CONFIG_PSNR) += encoder/ssim.c
|
|||
VP8_CX_SRCS-yes += encoder/tokenize.c
|
||||
VP8_CX_SRCS-yes += encoder/treewriter.c
|
||||
VP8_CX_SRCS-yes += encoder/variance_c.c
|
||||
VP8_CX_SRCS-$(CONFIG_PSNR) += common/postproc.h
|
||||
VP8_CX_SRCS-$(CONFIG_PSNR) += common/postproc.c
|
||||
|
||||
ifeq ($(CONFIG_REALTIME_ONLY),yes)
|
||||
VP8_CX_SRCS_REMOVE-yes += encoder/firstpass.c
|
||||
|
|
Загрузка…
Ссылка в новой задаче