implemented the -d flag
This commit is contained in:
parent
43271c64a8
commit
87226dc587
2 changed files with 5 additions and 3 deletions
|
@ -9,7 +9,7 @@ If used on containers with subtitles or audiostreams, this skript will only conv
|
||||||
|
|
||||||
## Flags
|
## Flags
|
||||||
```-e``` defines the extension of the files that should be converted<br>
|
```-e``` defines the extension of the files that should be converted<br>
|
||||||
```-d``` deletes original files after conversion (not implemented)<br>
|
```-d``` deletes original files after conversion<br>
|
||||||
```-h``` show help (not implemented)
|
```-h``` show help (not implemented)
|
||||||
|
|
||||||
## Examples
|
## Examples
|
||||||
|
|
|
@ -72,13 +72,15 @@ for file in **/*.@($extension); do
|
||||||
#there are problems with the -global_quality:v/-q:v settings only being able to make quality worse. Help is appreciated
|
#there are problems with the -global_quality:v/-q:v settings only being able to make quality worse. Help is appreciated
|
||||||
#not enough tested. So it is still experimental
|
#not enough tested. So it is still experimental
|
||||||
if [[ $encoder == "vp9_vaapi" ]]; then
|
if [[ $encoder == "vp9_vaapi" ]]; then
|
||||||
ffmpeg -hide_banner -hwaccel vaapi -vaapi_device $gpu -i "$file" -map 0 -c copy -c:v vp9_vaapi -rc_mode CQP -bf 1 -bsf:v vp9_raw_reorder,vp9_superframe -vf 'hwupload' "$file_out"
|
ffmpeg -hide_banner -hwaccel vaapi -vaapi_device $gpu -i "$file" -map 0 -c copy -c:v vp9_vaapi -rc_mode CQP -bf 1 -bsf:v vp9_raw_reorder,vp9_superframe -vf 'hwupload' "$file_out" &&
|
||||||
|
if [[ "$delete" = true ]]; then rm "$file"; fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#VP9_qsv
|
#VP9_qsv
|
||||||
#was not able to test it. So it is still experimental
|
#was not able to test it. So it is still experimental
|
||||||
if [[ $encoder == "vp9_qsv" ]]; then
|
if [[ $encoder == "vp9_qsv" ]]; then
|
||||||
ffmpeg -hide_banner -hwaccel qsv -qsv_device $gpu -i "$file" -c:v vp9_qsv -vf 'hwupload' "${file%.*}.mkv"
|
ffmpeg -hide_banner -hwaccel qsv -qsv_device $gpu -i "$file" -c:v vp9_qsv -vf 'hwupload' "${file%.*}.mkv" &&
|
||||||
|
if [[ "$delete" = true ]]; then rm "$file"; fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#libvpx-vp9
|
#libvpx-vp9
|
||||||
|
|
Loading…
Reference in a new issue