From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> To: ffmpeg-devel@ffmpeg.org Cc: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Subject: [FFmpeg-devel] [PATCH 02/22] avcodec/eamad: Don't use IDCTDSP-API unnecessarily Date: Thu, 20 Oct 2022 10:45:20 +0200 Message-ID: <AS8P250MB0744CC1E4CA805DC0273484C8F2A9@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM> (raw) In-Reply-To: <AS8P250MB0744A863420578904013459B8F2A9@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM> The eamad decoder uses a custom IDCT and actually does not use the IDCTDSP API at all. Somehow it was nevertheless used to simply apply the identity permutation on ff_zigzag_direct. This commit stops doing so. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- configure | 2 +- libavcodec/eamad.c | 8 +------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/configure b/configure index bb61e9a0b8..16b2084945 100755 --- a/configure +++ b/configure @@ -2820,7 +2820,7 @@ dxa_decoder_deps="zlib" dxv_decoder_select="lzf texturedsp" eac3_decoder_select="ac3_decoder" eac3_encoder_select="ac3_encoder" -eamad_decoder_select="aandcttables blockdsp bswapdsp idctdsp" +eamad_decoder_select="aandcttables blockdsp bswapdsp" eatgq_decoder_select="aandcttables idctdsp" eatqi_decoder_select="aandcttables blockdsp bswapdsp idctdsp" exr_decoder_deps="zlib" diff --git a/libavcodec/eamad.c b/libavcodec/eamad.c index 2a5aac912d..de8f488f65 100644 --- a/libavcodec/eamad.c +++ b/libavcodec/eamad.c @@ -39,7 +39,6 @@ #include "get_bits.h" #include "aandcttab.h" #include "eaidct.h" -#include "idctdsp.h" #include "mpeg12data.h" #include "mpeg12vlc.h" @@ -52,13 +51,11 @@ typedef struct MadContext { AVCodecContext *avctx; BlockDSPContext bdsp; BswapDSPContext bbdsp; - IDCTDSPContext idsp; AVFrame *last_frame; GetBitContext gb; void *bitstream_buf; unsigned int bitstream_buf_size; DECLARE_ALIGNED(32, int16_t, block)[64]; - ScanTable scantable; uint16_t quant_matrix[64]; int mb_x; int mb_y; @@ -71,9 +68,6 @@ static av_cold int decode_init(AVCodecContext *avctx) avctx->pix_fmt = AV_PIX_FMT_YUV420P; ff_blockdsp_init(&s->bdsp); ff_bswapdsp_init(&s->bbdsp); - ff_idctdsp_init(&s->idsp, avctx); - ff_init_scantable_permutation(s->idsp.idct_permutation, FF_IDCT_PERM_NONE); - ff_init_scantable(s->idsp.idct_permutation, &s->scantable, ff_zigzag_direct); ff_mpeg12_init_vlcs(); s->last_frame = av_frame_alloc(); @@ -135,7 +129,7 @@ static inline int decode_block_intra(MadContext *s, int16_t * block) { int level, i, j, run; RLTable *rl = &ff_rl_mpeg1; - const uint8_t *scantable = s->scantable.permutated; + const uint8_t *scantable = ff_zigzag_direct; int16_t *quant_matrix = s->quant_matrix; block[0] = (128 + get_sbits(&s->gb, 8)) * quant_matrix[0]; -- 2.34.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2022-10-20 8:45 UTC|newest] Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-10-20 8:31 [FFmpeg-devel] [PATCH 01/22] configure: Add idctdsp dependency to codecs that need it Andreas Rheinhardt 2022-10-20 8:45 ` Andreas Rheinhardt [this message] 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 03/22] avcodec/eatgq: Don't use IDCTDSP-API unnecessarily Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 04/22] avcodec/eatqi: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 05/22] avcodec/aic: Remove useless ScanTable Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 06/22] avcodec/imm4: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 07/22] avcodec/idctdsp: Add function to apply permutation to array Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 08/22] avcodec/agm: Only keep what is used from ScanTable Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 09/22] avcodec/asvdec: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 10/22] avcodec/dnxhddec: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 11/22] avcodec/cavs: Only keep what is needed from IDCTDSP-API Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 12/22] avcodec/g2meet: Only keep what is used from ScanTable Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 13/22] avcodec/g2meet: Pre-permute quantization tables Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 14/22] avcodec/intrax8: Only keep what is used from ScanTable Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 15/22] avcodec/mdec: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 16/22] avcodec/mimic: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 17/22] avcodec/mjpegdec: " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 18/22] avcodec/mjpegenc_common: Only pass " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 19/22] avcodec/speedhq: Only keep " Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 20/22] avcodec/wmv2dec: Remove unnecessary ScanTables Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 21/22] avcodec/idctdsp: Move ScanTable to mpegvideo Andreas Rheinhardt 2022-10-20 8:45 ` [FFmpeg-devel] [PATCH 22/22] avcodec/eatgq: Move transient GetByteContext from context to stack Andreas Rheinhardt 2022-10-20 17:24 ` [FFmpeg-devel] [PATCH 23/24] avcodec/mpegvideo: Move ASM-offset warning to its proper place Andreas Rheinhardt 2022-10-20 17:24 ` [FFmpeg-devel] [PATCH 24/24] avcodec/mpegvideo: Don't use ScanTable where unnecessary Andreas Rheinhardt 2022-10-21 18:46 ` Michael Niedermayer 2022-10-21 19:00 ` Andreas Rheinhardt
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=AS8P250MB0744CC1E4CA805DC0273484C8F2A9@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM \ --to=andreas.rheinhardt@outlook.com \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git