diff --git a/revid/revid.go b/revid/revid.go index 409ba702..899b401f 100644 --- a/revid/revid.go +++ b/revid/revid.go @@ -50,27 +50,17 @@ import ( // Misc constants const ( - clipDuration = 1 * time.Second - mp2tPacketSize = 188 // MPEG-TS packet size - mp2tMaxPackets = int(clipDuration * 2016 / time.Second) // # first multiple of 7 and 8 greater than 2000 - ringBufferSize = 10000 - ringBufferElementSize = 150000 - writeTimeout = 10 * time.Millisecond - readTimeout = 10 * time.Millisecond - httpTimeout = 5 * time.Second - bitrateTime = 1 * time.Minute - mjpegParserInChanLen = 100000 - ffmpegPath = "/usr/local/bin/ffmpeg" - rtmpConnectionTimout = 10 - outputChanSize = 1000 - cameraRetryPeriod = 5 * time.Second - sendFailedDelay = 5 * time.Millisecond - maxSendFailedErrorCount = 500 - clipSizeThreshold = 11 - rtmpConnectionMaxTries = 5 - raspividNoOfTries = 3 - sendingWaitTime = 5 * time.Millisecond - pkg = "revid:" + clipDuration = 1 * time.Second + ringBufferSize = 10000 + ringBufferElementSize = 150000 + writeTimeout = 10 * time.Millisecond + readTimeout = 10 * time.Millisecond + bitrateTime = 1 * time.Minute + ffmpegPath = "/usr/local/bin/ffmpeg" + rtmpConnectionTimeout = 10 + sendFailedDelay = 5 * time.Millisecond + rtmpConnectionMaxTries = 5 + pkg = "revid:" ) // Log Types @@ -230,7 +220,7 @@ func (r *Revid) reset(config Config) error { } r.destination[outNo] = s case Rtmp: - s, err := newRtmpSender(config.RtmpUrl, rtmpConnectionTimout, rtmpConnectionMaxTries, r.config.Logger.Log) + s, err := newRtmpSender(config.RtmpUrl, rtmpConnectionTimeout, rtmpConnectionMaxTries, r.config.Logger.Log) if err != nil { return err }