mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
rtp dispatch done, but video can not play in chrome
This commit is contained in:
parent
2f462775a0
commit
3ae510b843
9 changed files with 325 additions and 32 deletions
|
@ -214,6 +214,14 @@ SrsSharedPtrMessage::SrsSharedPtrPayload::~SrsSharedPtrPayload()
|
|||
srs_memory_unwatch(payload);
|
||||
#endif
|
||||
srs_freepa(payload);
|
||||
|
||||
for (int i = 0; i < nb_rtp_fragments; ++i) {
|
||||
srs_freep(rtp_fragments[i].bytes);
|
||||
}
|
||||
|
||||
if (nb_rtp_fragments) {
|
||||
srs_freepa(rtp_fragments);
|
||||
}
|
||||
}
|
||||
|
||||
SrsSharedPtrMessage::SrsSharedPtrMessage() : timestamp(0), stream_id(0), size(0), payload(NULL), rtp_fragments(NULL), nb_rtp_fragments(0)
|
||||
|
@ -307,6 +315,15 @@ bool SrsSharedPtrMessage::check(int stream_id)
|
|||
return false;
|
||||
}
|
||||
|
||||
void SrsSharedPtrMessage::set_rtp_fragments(SrsSample* samples, int nb_samples)
|
||||
{
|
||||
ptr->rtp_fragments = samples;
|
||||
ptr->nb_rtp_fragments = nb_samples;
|
||||
|
||||
rtp_fragments = samples;
|
||||
nb_rtp_fragments = nb_samples;
|
||||
}
|
||||
|
||||
bool SrsSharedPtrMessage::is_av()
|
||||
{
|
||||
return ptr->header.message_type == RTMP_MSG_AudioMessage
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue