mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-23 15:48:23 +00:00
srtsrc: Receive one frame per gstbuffer
Don't aggregate the received data, just receive it one packet at a time. So it keeps the packetization boundaries
This commit is contained in:
parent
1acd9c726a
commit
42fa4cb2ad
1 changed files with 2 additions and 16 deletions
|
@ -1191,25 +1191,11 @@ gst_srt_object_read (GstSRTObject * srtobject,
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (len < size) {
|
|
||||||
gint recv;
|
|
||||||
gint rest = size - len;
|
|
||||||
|
|
||||||
/* Workaround for SRT being unhappy about buffers that
|
len = srt_recvmsg (rsock, (char *) (data), size);
|
||||||
* are less than the chunk size */
|
break;
|
||||||
if (rest < msg_size)
|
|
||||||
goto out;
|
|
||||||
|
|
||||||
recv = srt_recvmsg (rsock, (char *) (data + len), rest);
|
|
||||||
|
|
||||||
if (recv <= 0)
|
|
||||||
goto out;
|
|
||||||
|
|
||||||
len += recv;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
out:
|
|
||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue