wiki:video_repair
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen der Seite angezeigt.
Beide Seiten, vorherige ÜberarbeitungVorherige ÜberarbeitungNächste Überarbeitung | Vorherige ÜberarbeitungLetzte ÜberarbeitungBeide Seiten, nächste Überarbeitung | ||
wiki:video_repair [2020/10/24 21:07] – [ffmpeg] pulsar | wiki:video_repair [2021/05/31 14:12] – techguru | ||
---|---|---|---|
Zeile 2: | Zeile 2: | ||
===== Videos Encodieren ===== | ===== Videos Encodieren ===== | ||
- | Dies gelang gut mit HandBrake. Dort hatte ich ein .mp4 Video geladen welches sich nicht unter VLC abspielen ließ(hat Codecs vermisst) Mit Handbrake konnte ich es in .webm Format umwandeln und nun läuft es überall. Es ist dabei aber auch größer geworden von 20MB auf 40MB gewachsen. | + | Manche Videos lassen sich nicht abspielen wegen Codec Warnung, daher muss man manche Videos umwandeln wenn man keine Codecs installieren mag. Dies gelang gut mit '' |
Im weiteren Schritt ließ es sich nun auch mit '' | Im weiteren Schritt ließ es sich nun auch mit '' | ||
Zeile 19: | Zeile 19: | ||
Man kann versuchen die defekte Video-Datei mit '' | Man kann versuchen die defekte Video-Datei mit '' | ||
- | mencoder -forceidx -oac copy -ovc copy corruptvideo.mp4 -o fixedvideo.avi | + | mencoder -forceidx -oac pcm -ovc copy corruptvideo.mp4 -o fixedvideo.avi |
| | ||
Zeile 64: | Zeile 64: | ||
ffmpeg -i input.mkv -vf " | ffmpeg -i input.mkv -vf " | ||
- | ==== Untrunc ==== | + | |
+ | |||
+ | Nur die ersten 30 Sekunden eines Videos in eine neue Datei speichern | ||
- | | + | |
- | * http:// | + | |
- | It is possible to repair the broken mp4 or m4v file using Untrunc. For this method you need: | + | Da der obige Kommando sehr lange dauerte, ohne sichtbare Qualitätsunterschiede, |
- | another video file which isn't broken | + | ffmpeg -i originalfilm.mkv -t 00:00:30 -c copy TheRunoftheGoldenBull_30s.mkv |
- | and Install some pre-requisite libraries with apt or zypper: | ||
- | sudo apt install libavformat-dev libavcodec-dev libavutil-dev | + | Aus der Mitte eines Videos einen bestimmten Bereich wählen. Hier ab der 11. Sekunde und ab da 31 Sekunden weiter. |
- | Unter Suse benötigte ich noch das Paket zlib-devel | + | ffmpeg |
+ | |||
+ | |||
+ | Video beschleunigen | ||
- | | + | |
+ | | ||
+ | Video verlangsamen | ||
- | This is what to do: | + | ffmpeg -i 20210112_15171777.mp4 -filter:v " |
- | | ||
- | Download the source code for Untrunc from the github repo: | ||
- | wget https://github.com/ponchio/ | + | Zwei einzelne Video Dateien zusammenfügen. Hierzu müssen die beiden oder mehrere Dateien untereinander in einer Text Datei eingetragen werden: |
+ | |||
+ | < | ||
+ | cat files.txt | ||
+ | file ' | ||
+ | file ' | ||
+ | </code> | ||
- | Unzip the source code: | + | Anschließend beginnt das zusammensetzen der Dateien mit '' |
- | | + | |
- | Go into the directory where it's been unzipped: | ||
- | cd untrunc-master | ||
- | Compile the source code using this command (all one line): | + | Audio, Musik, Ton aus einer Musik-Datei zu einem Video hinzufügen |
- | | + | |
- | (you can try skipping this step and using the ready-provided executable, but it didn't work for me) | ||
- | Then you can actually fix the video. You need both the broken video and an example working video. | + | ==== Untrunc ==== |
- | Ideally the video should be from the same camera & have the same resolution (mine was but it might work without). Also if it is at least as long as the broken one (preferably roughly the same) this may help. | + | * https:// |
- | Run this command in the folder where you have unzipped and compiled Untrunc but replace the / | + | oder eine verbesserte Version: |
- | | + | |
- | Then it should churn away and hopefully produce a playable file called broken-video_fixed.m4v | ||
- | That's it you're done! | + | Es wir neben der defekten Videodatei noch eine funktionierende Datei benötigt welche vom gleichen Gerät erstellt worden ist wie die defekte. |
- | VLC Media Player should now be able to play the file. However it may be reporting the wrong length information (Untrunc tries to guess/work this out, but doesn't always get it right). To fix this try re-encoding the video through another program. | + | Zusätzlich werden noch benötigte Libraries mit '' |
+ | sudo apt install libavformat-dev libavcodec-dev libavutil-dev | ||
- | ==== Screenshots von WebCam ==== | + | Unter Suse benötigte ich noch das Paket // |
- | === MPlayer === | + | zypper in zlib-devel |
- | To use MPlayer to take snapshots from your webcam run this command from the terminal: | ||
- | mplayer tv:// -tv driver=v4l2: | + | Dann '' |
- | From here you have to press s to take the snapshot. The snapshot will be saved in your current folder as shotXXXX.png. | + | Die Verwendung von '' |
+ | |||
+ | |||
+ | | ||
+ | |||
+ | |||
+ | |||
+ | ===== Video und Bild Aufnahme ===== | ||
+ | |||
+ | Mit hilfe gängiger Programme wie Mplay, mpv und Vlc | ||
- | ===== Video aufnehmen | + | ==== Video aufnehmen ==== |
If you want to record continuous video: | If you want to record continuous video: | ||
Zeile 138: | Zeile 152: | ||
Unter Debian, openSuse und weiteren zu finden | Unter Debian, openSuse und weiteren zu finden | ||
guvcview | guvcview | ||
+ | |||
+ | |||
+ | |||
+ | ==== Screenshots von WebCam ==== | ||
+ | |||
+ | === MPlayer === | ||
+ | |||
+ | To use MPlayer to take snapshots from your webcam run this command from the terminal: | ||
+ | |||
+ | mplayer tv:// -tv driver=v4l2: | ||
+ | |||
+ | From here you have to press s to take the snapshot. The snapshot will be saved in your current folder as shotXXXX.png. | ||
+ | |||
+ | |||