Skip to content

Add diagonal combing detection#64

Open
dimag0g wants to merge 1 commit into
pinterf:masterfrom
dimag0g:fix/diag_decomb
Open

Add diagonal combing detection#64
dimag0g wants to merge 1 commit into
pinterf:masterfrom
dimag0g:fix/diag_decomb

Conversation

@dimag0g
Copy link
Copy Markdown

@dimag0g dimag0g commented May 10, 2026

This PR modifies the combing detection algorithm metric=1 to better detect combing along diagonal lines. Since the algorithm detects extra pixels as combed (in addition to those detected by the base algorithm), the MI value must be increased to compensate.

Currently there's only the C implementation. If the changes are deemed worthy, we can discuss the SSE2 implementation.

Here are some screenshots for comparison, produced by:

left=FFVideoSource(FileName).TFM(pp=1, metric=1, opt=0, MI=85, display=true).TDecimate()
right=FFVideoSource(FileName).TFM(pp=7, metric=1, opt=0, MI=85).TDecimate()
StackHorizontal(left, right)

This PR, clean frame correctly detected
compare new2_03 59 994

This PR, combed frame correctly detected
compare new2_05 47 807

This PR, combed frame correctly detected
compare new2_05 48 753

Base algorithm, clean frame detected as combed
compare old_03 59 964

Base algorithm, combed frame not detected
compare old_05 47 813

Base algorithm, combed frame not detected
compare old_05 48 766

@dimag0g dimag0g marked this pull request as ready for review May 10, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant