Skip to content

Commit

Permalink
fix increment packets sent in SRT and UDP
Browse files Browse the repository at this point in the history
  • Loading branch information
pedroSG94 committed Jan 16, 2025
1 parent 2d4cab5 commit 8a38212
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions srt/src/main/java/com/pedro/srt/srt/SrtSender.kt
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,8 @@ class SrtSender(
size += commandsManager.writeData(mpegTsPacket, socket)
bytesSend += size
}
if (type == MpegType.VIDEO) videoFramesSent++
else if (type == MpegType.AUDIO) audioFramesSent++
if (isEnableLogs) {
Log.i(TAG, "wrote ${type.name} packet, size $bytesSend")
}
Expand Down
2 changes: 2 additions & 0 deletions udp/src/main/java/com/pedro/udp/UdpSender.kt
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,8 @@ class UdpSender(
size += commandManager.writeData(mpegTsPacket, socket)
bytesSend += size
}
if (type == MpegType.VIDEO) videoFramesSent++
else if (type == MpegType.AUDIO) audioFramesSent++
if (isEnableLogs) {
Log.i(TAG, "wrote ${type.name} packet, size $bytesSend")
}
Expand Down

0 comments on commit 8a38212

Please sign in to comment.