more stuff for better wuality hopefully
This commit is contained in:
parent
8e7944f688
commit
6b69d7a532
2 changed files with 8 additions and 4 deletions
|
|
@ -24,10 +24,10 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- /mnt/user/plex:/media:ro
|
- /mnt/user/plex:/media:ro
|
||||||
- ./transcode-config.yaml:/app/config.yaml:ro
|
- ./transcode-config.yaml:/app/config.yaml:ro
|
||||||
- transcode-cache-v3:/cache
|
- transcode-cache-v4:/cache
|
||||||
ports:
|
ports:
|
||||||
- "8090:8080"
|
- "8090:8080"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
transcode-cache-v3:
|
transcode-cache-v4:
|
||||||
|
|
|
||||||
|
|
@ -82,7 +82,7 @@ index 9bbe037..c0297fe 100644
|
||||||
// Input specs
|
// Input specs
|
||||||
args = append(args, []string{
|
args = append(args, []string{
|
||||||
"-i", config.InputFilePath, // Input file
|
"-i", config.InputFilePath, // Input file
|
||||||
@@ -89,14 +106,26 @@ func TranscodeSegments(ctx context.Context, ffmpegBinary string, config Transcod
|
@@ -89,14 +106,30 @@ func TranscodeSegments(ctx context.Context, ffmpegBinary string, config Transcod
|
||||||
scale = fmt.Sprintf("scale=%d:-2", profile.Width)
|
scale = fmt.Sprintf("scale=%d:-2", profile.Width)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -105,7 +105,11 @@ index 9bbe037..c0297fe 100644
|
||||||
+ }
|
+ }
|
||||||
+ args = append(args, []string{
|
+ args = append(args, []string{
|
||||||
+ "-vf", scale, "-c:v", "h264_vaapi", "-profile:v", "high",
|
+ "-vf", scale, "-c:v", "h264_vaapi", "-profile:v", "high",
|
||||||
+ "-level:v", "4.0", "-b:v", fmt.Sprintf("%dk", profile.Bitrate),
|
+ "-level:v", "4.0", "-rc_mode", "VBR",
|
||||||
|
+ "-b:v", fmt.Sprintf("%dk", profile.Bitrate),
|
||||||
|
+ "-maxrate", fmt.Sprintf("%dk", profile.Bitrate*3/2),
|
||||||
|
+ "-bufsize", fmt.Sprintf("%dk", profile.Bitrate*2),
|
||||||
|
+ "-bf", "2", "-compression_level", "0",
|
||||||
+ }...)
|
+ }...)
|
||||||
+ } else {
|
+ } else {
|
||||||
+ args = append(args, []string{
|
+ args = append(args, []string{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue