fix RTCP-SR init timestamp value

This commit is contained in:
ireader
2022-11-19 18:37:10 +08:00
parent 37f76424e9
commit 2f477a594a
2 changed files with 4 additions and 2 deletions

View File

@@ -11,6 +11,8 @@ LOCAL_SRC_FILES += $(wildcard source/*.c)
LOCAL_SRC_FILES += $(wildcard source/*.cpp)
LOCAL_SRC_FILES += $(wildcard payload/*.c)
LOCAL_SRC_FILES += $(wildcard payload/*.cpp)
LOCAL_SRC_FILES += $(wildcard rtpext/*.c)
LOCAL_SRC_FILES += $(wildcard rtpext/*.cpp)
LOCAL_MODULE := rtp
include $(BUILD_STATIC_LIBRARY)

View File

@@ -67,8 +67,8 @@ int rtp_onsend(void* rtp, const void* data, int bytes)
if(0 != rtp_packet_deserialize(&pkt, data, bytes))
return -1; // packet error
//ctx->self->rtp_clock = rtpclock();
//ctx->self->rtp_timestamp = pkt.rtp.timestamp; // RTP timestamp
ctx->self->rtp_clock = rtpclock();
ctx->self->rtp_timestamp = pkt.rtp.timestamp; // RTP timestamp
ctx->self->rtp_bytes += pkt.payloadlen;
ctx->self->rtp_packets += 1;
return 0;