Update ffmpeg info
This commit is contained in:
parent
b460a83e3d
commit
45c32024d6
@ -1,4 +1,5 @@
|
|||||||
# ffmpeg
|
# ffmpeg
|
||||||
|
|
||||||
- [List en-/decoders](https://write.corbpie.com/ffmpeg-list-all-codecs-encoders-decoders-and-formats/)
|
- [List en-/decoders](https://write.corbpie.com/ffmpeg-list-all-codecs-encoders-decoders-and-formats/)
|
||||||
- [Map option to select video, audio, subtitle streams](https://trac.ffmpeg.org/wiki/Map)
|
- [Map option to select video, audio, subtitle streams](https://trac.ffmpeg.org/wiki/Map)
|
||||||
- [ffmpeg doc](https://ffmpeg.org/ffmpeg.html)
|
- [ffmpeg doc](https://ffmpeg.org/ffmpeg.html)
|
||||||
@ -10,6 +11,7 @@
|
|||||||
- [Set stream as default](https://stackoverflow.com/questions/26956762/ffmpeg-set-subtitles-track-as-default)
|
- [Set stream as default](https://stackoverflow.com/questions/26956762/ffmpeg-set-subtitles-track-as-default)
|
||||||
|
|
||||||
## Tests
|
## Tests
|
||||||
|
|
||||||
- Keijo!!!!!!!! - S01E01 handbrake h264
|
- Keijo!!!!!!!! - S01E01 handbrake h264
|
||||||
- size: 607.4MB
|
- size: 607.4MB
|
||||||
|
|
||||||
@ -48,6 +50,7 @@
|
|||||||
`ffmpeg -i \[Arid\]\ Death\ Note\ -\ 01\ -\ Rebirth\ \[3BECAA78\].mkv -c:v libx264 -c:a libopus -b:a 192k -crf 20 -tune animation -map 0:v:0 -map 0:a:0 -map 0:a:1 -map 0:s:0 -metadata:s:v:0 title="Video" -metadata:s:a:0 title="Japanese" -metadata:s:a:0 language=jpn -disposition:a:0 default -metadata:s:a:1 title="English" -metadata:s:a:1 language=eng -metadata:s:s:0 title="English" -metadata:s:s:0 language=eng -disposition:s:0 default "Death Note - 01 - Rebirth libx264 mapped metadata tune.mkv"`
|
`ffmpeg -i \[Arid\]\ Death\ Note\ -\ 01\ -\ Rebirth\ \[3BECAA78\].mkv -c:v libx264 -c:a libopus -b:a 192k -crf 20 -tune animation -map 0:v:0 -map 0:a:0 -map 0:a:1 -map 0:s:0 -metadata:s:v:0 title="Video" -metadata:s:a:0 title="Japanese" -metadata:s:a:0 language=jpn -disposition:a:0 default -metadata:s:a:1 title="English" -metadata:s:a:1 language=eng -metadata:s:s:0 title="English" -metadata:s:s:0 language=eng -disposition:s:0 default "Death Note - 01 - Rebirth libx264 mapped metadata tune.mkv"`
|
||||||
|
|
||||||
Convert Season in loop
|
Convert Season in loop
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 26)
|
for i in (seq -w 1 26)
|
||||||
|
|
||||||
@ -57,6 +60,7 @@ end
|
|||||||
```
|
```
|
||||||
|
|
||||||
Death Note bluray
|
Death Note bluray
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 2 37)
|
for i in (seq -w 2 37)
|
||||||
|
|
||||||
@ -67,6 +71,7 @@ end
|
|||||||
|
|
||||||
Complex example with different audio channels
|
Complex example with different audio channels
|
||||||
Note that the disposition is deleted first. Otherwise later settings might not apply
|
Note that the disposition is deleted first. Otherwise later settings might not apply
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 25); ffmpeg -i Steins\;Gate\ -\ {$i}.mkv -metadata title="Steins;Gate - $i" -map_metadata -1 -disposition 0 \
|
for i in (seq -w 1 25); ffmpeg -i Steins\;Gate\ -\ {$i}.mkv -metadata title="Steins;Gate - $i" -map_metadata -1 -disposition 0 \
|
||||||
|
|
||||||
@ -78,6 +83,7 @@ for i in (seq -w 1 25); ffmpeg -i Steins\;Gate\ -\ {$i}.mkv -metadata title="Ste
|
|||||||
```
|
```
|
||||||
|
|
||||||
Note how the subtitles are identified by their new id after mapping
|
Note how the subtitles are identified by their new id after mapping
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 13); ffmpeg -i Vivy\ -\ Flourite\ Eye\'s\ Song\ -\ {$i}.mkv -metadata title="Vivy - Flourite Eye's Song - $i" -map_metadata -1 -disposition 0 \
|
for i in (seq -w 1 13); ffmpeg -i Vivy\ -\ Flourite\ Eye\'s\ Song\ -\ {$i}.mkv -metadata title="Vivy - Flourite Eye's Song - $i" -map_metadata -1 -disposition 0 \
|
||||||
|
|
||||||
@ -91,6 +97,7 @@ for i in (seq -w 1 13); ffmpeg -i Vivy\ -\ Flourite\ Eye\'s\ Song\ -\ {$i}.mkv -
|
|||||||
```
|
```
|
||||||
|
|
||||||
Include subtitles from external files
|
Include subtitles from external files
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 11); ffmpeg -i Bartender\ {$i}\ \[BDRip\ 1920x1080\ HEVC\ FLAC\].mkv -i ENG\ Subs/Bartender\ {$i}\ \[BDRip\ 1920x1080\ HEVC\ FLAC\].eng.\[BD\].sup.mks -metadata title="Bartender - S01E$i" -map_metadata -1 -disposition 0 \
|
for i in (seq -w 1 11); ffmpeg -i Bartender\ {$i}\ \[BDRip\ 1920x1080\ HEVC\ FLAC\].mkv -i ENG\ Subs/Bartender\ {$i}\ \[BDRip\ 1920x1080\ HEVC\ FLAC\].eng.\[BD\].sup.mks -metadata title="Bartender - S01E$i" -map_metadata -1 -disposition 0 \
|
||||||
|
|
||||||
@ -104,6 +111,7 @@ for i in (seq -w 1 11); ffmpeg -i Bartender\ {$i}\ \[BDRip\ 1920x1080\ HEVC\ FLA
|
|||||||
```
|
```
|
||||||
|
|
||||||
Edit medatada, here set subtitles as default, from exising files
|
Edit medatada, here set subtitles as default, from exising files
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 12); ffmpeg -i S02E{$i}.mkv -c:v copy -map 0:v -c:a copy -map 0:a -c:s copy -map 0:s:0 -disposition:s:0 default \
|
for i in (seq -w 1 12); ffmpeg -i S02E{$i}.mkv -c:v copy -map 0:v -c:a copy -map 0:a -c:s copy -map 0:s:0 -disposition:s:0 default \
|
||||||
|
|
||||||
@ -111,6 +119,7 @@ for i in (seq -w 1 12); ffmpeg -i S02E{$i}.mkv -c:v copy -map 0:v -c:a copy -map
|
|||||||
```
|
```
|
||||||
|
|
||||||
Extract subtitles
|
Extract subtitles
|
||||||
|
|
||||||
```
|
```
|
||||||
for i in (seq -w 1 37); ffmpeg -i Death\ Note\ {$i}.mkv -map 0:s:0 -metadata:s:s:0 title="English [Redc4t]" -metadata:s:s:0 language=eng \
|
for i in (seq -w 1 37); ffmpeg -i Death\ Note\ {$i}.mkv -map 0:s:0 -metadata:s:s:0 title="English [Redc4t]" -metadata:s:s:0 language=eng \
|
||||||
|
|
||||||
@ -119,8 +128,15 @@ for i in (seq -w 1 37); ffmpeg -i Death\ Note\ {$i}.mkv -map 0:s:0 -metadata:s:s
|
|||||||
|
|
||||||
Encoding stuff but with a set bitrate and using hevc (cause VP9 is kinda unsupported still)
|
Encoding stuff but with a set bitrate and using hevc (cause VP9 is kinda unsupported still)
|
||||||
Bitrate of 20 Mib/20480 kib
|
Bitrate of 20 Mib/20480 kib
|
||||||
|
|
||||||
```
|
```
|
||||||
ffmpeg -y -i "/mnt/storage/MediaLibrary/Shows/To Your Eternity (2021)/Season 01/S01E01 - The Last One [1080p].mkv" -c:v libx265 -b:v 20480k -preset fast -map 0:v:0 -x265-params pass=1 -f null /dev/null && \
|
ffmpeg -y -i "/mnt/storage/MediaLibrary/Shows/To Your Eternity (2021)/Season 01/S01E01 - The Last One [1080p].mkv" -c:v libx265 -b:v 20480k -preset fast -map 0:v:0 -x265-params pass=1 -f null /dev/null && \
|
||||||
ffmpeg -i "/mnt/storage/MediaLibrary/Shows/To Your Eternity (2021)/Season 01/S01E01 - The Last One [1080p].mkv" -c:v libx265 -b:v 20480k -preset fast -map 0:v:0 -x265-params pass=2 -c:a copy -map 0:a -c:s copy -map 0:s "/mnt/storage/MediaLibrary/output/To Your Eternity/S01E01.mk
|
ffmpeg -i "/mnt/storage/MediaLibrary/Shows/To Your Eternity (2021)/Season 01/S01E01 - The Last One [1080p].mkv" -c:v libx265 -b:v 20480k -preset fast -map 0:v:0 -x265-params pass=2 -c:a copy -map 0:a -c:s copy -map 0:s "/mnt/storage/MediaLibrary/output/To Your Eternity/S01E01.mk
|
||||||
v"
|
v"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
# New stuff
|
||||||
|
|
||||||
|
```
|
||||||
|
ffmpeg -i Die\ Pfeiler\ der\ Macht_t00.mkv -map 0:v:0 -map 0:a:0 -map 0:s:0 -c copy -c:a flac -metadata title="Die Pfeiler der Macht - 1" -metadata:s:v:0 title="Video" -metadata:s:v:0 language=zxx -metadata:s:a:0 title="Deutsch" -metadata:s:a:0 language=ger -disposition:a:0 default -metadata:s:s:0 title="Deutsch" /mnt/storage/MediaLibrary/tdarrready/Die\ Pfeiler\ der\ Macht/Movie1.mkv
|
||||||
|
```
|
||||||
|
2
arch-config/scripts/in_path/sc-media-input
Normal file → Executable file
2
arch-config/scripts/in_path/sc-media-input
Normal file → Executable file
@ -11,6 +11,6 @@ if ! ssh-add -T "${sshkeypath}.pub" &>/dev/null; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# transfer from local storage to input
|
# transfer from local storage to input
|
||||||
rsync -uvr --progress --bwlimit=2M "/mnt/storage/MediaLibrary/tdarrready/" ${user}@${server}:/mnt/Media/input/
|
rsync -uvr --progress --bwlimit=4M "/mnt/storage/MediaLibrary/tdarrready/" ${user}@${server}:/mnt/Media/input/
|
||||||
|
|
||||||
echo "Finished transfering data"
|
echo "Finished transfering data"
|
||||||
|
Loading…
Reference in New Issue
Block a user