diff options
| author | James Mills <prologic@shortcircuit.net.au> | 2020-03-31 19:04:21 +1000 |
|---|---|---|
| committer | James Mills <prologic@shortcircuit.net.au> | 2020-03-31 19:19:58 +1000 |
| commit | cd574192bf9438691ad07c09cb157de74cada5e1 (patch) | |
| tree | 31414fbf4431930b936ab3c1c2cf1bffeac2a875 /app/config.go | |
| parent | 7c919b5f9b85a9f1f708884565f12b83ad4038e0 (diff) | |
Allow transcoding to smaller sizes a configurable and optional feature
Diffstat (limited to 'app/config.go')
| -rw-r--r-- | app/config.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/config.go b/app/config.go index 9c0e733..c93d2a5 100644 --- a/app/config.go +++ b/app/config.go @@ -34,9 +34,13 @@ type ThumbnailerConfig struct { Timeout int `json:"timeout"` } +// Sizes a map of ffmpeg -s option to suffix. e.g: hd720 -> #720p +type Sizes map[string]string + // TranscoderConfig settings for Transcoder type TranscoderConfig struct { - Timeout int `json:"timeout"` + Timeout int `json:"timeout"` + Sizes Sizes `json:"sizes"` } // FeedConfig settings for App Feed. @@ -73,6 +77,7 @@ func DefaultConfig() *Config { }, Transcoder: &TranscoderConfig{ Timeout: 300, + Sizes: Sizes(nil), }, Feed: &FeedConfig{ ExternalURL: "http://localhost:8000", |
