The source is DVD with PAL to NTSC conversion done not like usual telecine, but adding 1 duplicate frame after every 5 or 6 frames. Is it possible to remove duplicate frames but no reencode?
+ Reply to Thread
Results 1 to 13 of 13
-
-
Yes, it is possible to remove duplicate frames without re-encoding the video.
The specific technique involves using the `mpdecimate` filter, which can
detect and remove duplicate frames with minimal quality loss.
Code:ffmpeg -i input.dvd.mkv -vf mpdecimate -vsync passthrough output.mkv
- `-vf mpdecimate` : The video filter that detects and removes duplicate frames
- `-vsync passthrough`: Ensures the frame rate is preserved after duplicate removal
Additional Considerations
- The `mpdecimate` filter works best when duplicates are exact matches
- For your specific scenario (1 duplicate after every 5-6 frames), this might require some fine-tuning
- You may need to adjust parameters like `max=1` to control duplicate frame detection
If the basic command doesn't work perfectly, you can add more precise parameters:
Code:ffmpeg -i input.dvd.mkv -vf "mpdecimate=max=1:hi=64:lo=64" -vsync passthrough output.mkv
Last edited by videoAI; 26th Aug 2025 at 07:41.
As always .. there is nothing wrong with my environment -
-
I'm no expert but I can't see any way of not re-encoding if you start removing frames.
If you're into AVISynth, 1 in 6 decimation seems to work (with Ass to increase the speed from 24.975 after the Tdec to 25):
Code:LWLibavVideoSource("sample2.m2v") TFM() TDecimate(Cycle=6, CycleR=1) AssumeFPS(25)
-
-
-
-
Let me help clarify this for you by breaking down the nuances of frame decimation and video processing.
When using the `mpdecimate` filter, there are actually two potential scenarios of "quality" impact:
1. Computational Processing
- The `mpdecimate` filter analyzes and removes duplicate frames
- This process itself does not re-encode or modify the video's actual visual quality
- The computational analysis might have a minimal processing overhead
2. Frame Selection Mechanism
- `mpdecimate` uses a comparison algorithm to detect duplicate frames
- It makes decisions about which frames to keep or remove
- While not re-encoding, the frame selection process could potentially introduce very slight
artifacts or discontinuities in frame sequence
Technical Nuance
True quality loss occurs during re-encoding. In this case, with `mpdecimate`,
you're not re-compressing the video, so the original video's visual fidelity remains intact.
- For Clever FFmpeg-GU, reach out to @ProWo for how to use the tool.
As always .. there is nothing wrong with my environment -
The GOP length is 15, so you end up re-encoding the entire thing anyways even with a smart renderer
And for ffmpeg, anything -vf means data gets decoded to uncompressed before the filter chain - so this usually means re-encoding and quality loss, unless you leave it uncompressed (very huge filesizes) , or re-encode with lossless compression (huge filesizes) -
Yes, it is possible to remove duplicate frames without re-encoding the video.
Also
Code:ffmpeg -i input.dvd.mkv -vf "mpdecimate=max=1:hi=64:lo=64" -vsync passthrough output.mkv
users currently on my ignore list: deadrats, Stears555, marcorocchini -
OK. I got the answer to my question.
Conclusion - I need to find a PAL DVD with the same content -
poisondeathray is right and videoAI not - you can only remove losslessly repeated frames (if they are duplicated in MPEG syntax) - for this DGPulldown is probably best tool - if repeated frames are hardcoded then there is no way to remove them from stream without re-encoding.
-
As always .. there is nothing wrong with my environment
Similar Threads
-
How to remove jaggies/steps/aliasing from progressive mpeg2/vob file
By Darryl In Canada in forum RestorationReplies: 12Last Post: 30th Jan 2025, 03:17 -
Remove Duplicate Frames
By Mr. Fanservice in forum Newbie / General discussionsReplies: 3Last Post: 28th Jan 2024, 11:03 -
Remove Duplicate Images
By Jay123210599 in forum ComputerReplies: 3Last Post: 12th Jan 2024, 11:21 -
25->23.976 conversion (duplicate frames)
By sebastiaaan in forum RestorationReplies: 1Last Post: 1st Jul 2023, 02:43 -
Duplicate Frames or???
By salvo00786 in forum DVD RippingReplies: 13Last Post: 3rd Oct 2022, 13:07