> Hi all,
> 
> This revives Paul's Bink 2 video decoder (last posted June 2022, never
> applied), forward-ported to current master with the accumulated review
> feedback addressed as far as I could. Paul is kept as author; I did the
> rebase and the fixes below. Paul, please correct me if you'd rather
> handle this yourself.
> 
> Changes over the 2022 version:
> - VLC tables migrated to the current API (VLCElem + ff_vlc_init_sparse)
> - Dropped the unused BlockDSPContext threading and the unused
>   idctdsp.h include (no configure change needed as a result)
> - Includes updated for the current tree (mem_internal.h, emms.h,
>   decode.h, mem.h); AVFrame.key_frame replaced with pict_type-only
>   marking; removed FF_CODEC_CAP_INIT_THREADSAFE flag dropped
> - Fixed operator precedence in the demuxer KB2 i/j/k/n revision check
>   (the bare `|| revision == 'n'` applied to any signature)
> - Headers are self-contained; `make checkheaders` passes
> 
> Review points from the 2020/2022 threads, status:
> - James (flush callback): present in the 2022 base, kept.
> - James (idctdsp.h unused): removed.
> - James (compile f/g separately): kept as headers (Paul's 2022
>   layout); they are standalone now. Happy to split into separate
>   compilation units if still preferred.
> - Peter/Nicolas (duplicated tables): the internal next_skips
>   duplicate and ones_count are gone from the 2022 base (av_popcount).
>   The three remaining tiny tables (luma_repos 16B, dq_patterns 8B,
>   bink2g_dc_pat 37 entries) have no shareable counterpart: the
>   lookalikes are either static, encoder-local, or numerically
>   different (verified). Total 61 bytes kept local; will share if
>   reviewers prefer.
> - Jan (limitations in message): noted below. FATE test: I can provide
>   samples (mplayerhq bink2 set + I can cut smaller ones) but have no
>   fate-suite upload access; happy to have someone generate/upload.
> 
> Limitations: no in-loop deblocking filter; KB2n and alpha-combined
> streams are untested here (decoder attempts all revisions f and up).
> 
> Testing, all on AArch64 macOS, current master:
> - fate-bink-video-b, fate-bink-video-f, fate-bink-video-i,
>   fate-bink-demux, fate-binkaudio-dct, fate-binkaudio-rdft: all pass
> - make checkheaders: passes (two -Wunused-function notes for the
>   slice entry points in the synthetic TU only; real build is
>   warning-free)
> - ge_video_86l.bk2 (KB2g, 1024x576): 490/490 frames, visually verified
> - sc13_01_partial.bk2 (KB2f, 1280x736): 236 frames to its truncation
>   point, visually verified; cross-checked against an independent
>   Rust decoder within +/-1 LSB on a fraction of pixels (rounding)
> - seek smoke tests (-ss before/after input) pass
> 
> The samples above are from https://samples.mplayerhq.hu/game-formats/bink2/.
> 
> The patch is attached to this email 
> (0001-avcodec-add-Bink-2-video-decoder.patch).
> It is also available at https://github.com/mrowlinson/bink2-ffmpeg
> 
> Thanks for looking,
> Michael 

_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to