mirror of https://bitbucket.org/ausocean/av.git
revid: fix rtmp sending
Approved-by: kortschak <dan@kortschak.io>
This commit is contained in:
parent
081007b091
commit
5a181f3576
|
@ -157,7 +157,7 @@ func (p *packer) Write(frame []byte) (int, error) {
|
|||
}
|
||||
p.packetCount++
|
||||
now = time.Now()
|
||||
if now.Sub(prevTime) > clipDuration && p.packetCount%7 == 0 {
|
||||
if (p.owner.config.Output1 != Rtmp && now.Sub(prevTime) > clipDuration && p.packetCount%7 == 0) || p.owner.config.Output1 == Rtmp {
|
||||
p.owner.buffer.Flush()
|
||||
p.packetCount = 0
|
||||
prevTime = now
|
||||
|
|
Loading…
Reference in New Issue