Getting started on rtmp output

This commit is contained in:
Unknown 2018-02-07 17:05:34 +10:30
parent 91bc6fbff9
commit edb4ffd826
3 changed files with 2 additions and 1 deletions

View File

@ -107,6 +107,7 @@ const (
Mjpeg = 7 Mjpeg = 7
None = 8 None = 8
Mpegts = 9 Mpegts = 9
Rtmp = 10
) )
// Default config settings // Default config settings
@ -226,7 +227,7 @@ func (r *revidInst) ChangeState(config Config) error {
} }
case Mjpeg: case Mjpeg:
if config.Quantization != "" { if config.Quantization != "" {
quantization, _ := strconv.Atoi(config.Quantization) quantization, _ := strconv.Atoi(config.Quantization)
if quantization > 0 || config.Bitrate == "" { if quantization > 0 || config.Bitrate == "" {
return errors.New("Bad bitrate or quantization for mjpeg input!") return errors.New("Bad bitrate or quantization for mjpeg input!")
} }

View File