Last active
August 14, 2026 03:34
-
-
Save jxu/5611321ca13d0ff60c2c5a10fe9c0cc1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Substring(7,10) for format like dvgrab-2008.08.08_17-53-10.dv | |
| Get-ChildItem *.dv | Sort Name | Group { $_.BaseName.Substring(7,10) } | % { | |
| $d=$_.Name | |
| $_.Group | % { "file '$($_.Name)'" } | Set-Content "$d.txt" | |
| ffmpeg -f concat -i "$d.txt" -vf bwdif -c:v libx264 -preset slow -crf 22 "$d.mp4" | |
| if ($LASTEXITCODE -eq 0) { Remove-Item "$d.txt" } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Get-ChildItem *.dv | Sort-Object Name | ForEach-Object { "file '$($_.Name)'" } | Set-Content files.txt | |
| # -vf bwdif to deinterlace, but breaks sometimes | |
| ffmpeg -f concat -i files.txt -c:v libx264 -preset slow -crf 22 concat.mp4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| exiftool -ext dv "-FileName<DV:DateTimeOriginal" -d "%Y-%m-%d_%H-%M-%S%%-c.%%e" . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Get-ChildItem *.dv | % { ffmpeg -i $_.FullName -vf bwdif -c:v libx264 -preset slow -crf 22 "$($_.BaseName).mp4" } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment