does gstreamer rtsp server support trickplay with scale/speed option?

zhi sunzhidev at 163.com
Fri Feb 2 06:10:41 UTC 2018


Hi guys,


I am trying to implement a activex control using decodebin as rtsp client play, as well as gst-rtsp-server as backend server. 
I want to play rtsp video stream with fast/slow option from the client control, and it needs the support of the rtsp-server. but i cannot find a way to do so. 
i can playback with range option from the control with rtsp server.


I have dig into the code and find the following information, the range rtsp option (GST_RTSP_HDR_RANGEļ¼‰ is handled (so the range is workable), but there is no GST_RTSP_HDR_RATE or GST_RTSP_HDR_SPEED related logical here.


..........................
gst-rtsp-server-1.12.3/gst/rtsp-server/rtsp-client.c


gst_rtsp_client_handle_message


static gboolean
handle_play_request (GstRTSPClient * client, GstRTSPContext * ctx)
{
.....
/* parse the range header if we have one */
res = gst_rtsp_message_get_header (ctx->request, GST_RTSP_HDR_RANGE, &str, 0);
if (res == GST_RTSP_OK) {
if (gst_rtsp_range_parse (str, &range) == GST_RTSP_OK) {
GstRTSPMediaStatus media_status;


/* we have a range, seek to the position */
unit = range->unit;
gst_rtsp_media_seek (media, range);
gst_rtsp_range_free (range);
.....


on the control side, related code as below:


gboolean res = FALSE;
gint64 start, stop;
GstEvent *s_event;
gdouble rate = 10.0;
start = 3.0 * GST_SECOND;


GstSeekFlags flags = (GstSeekFlags)(GST_SEEK_FLAG_FLUSH | GST_SEEK_FLAG_ACCURATE | GST_SEEK_FLAG_SKIP);


s_event = gst_event_new_seek(rate,GST_FORMAT_TIME,flags,GST_SEEK_TYPE_SET, start, GST_SEEK_TYPE_NONE, 0);


res = gst_element_send_event(pipeline, s_event);
if (!res)
g_print("seek failed\n");


gst_element_get_state(pipeline, NULL, NULL, GST_CLOCK_TIME_NONE);




so i want to confirm whether or not the gst-rtsp-server supports the trickplay with scale or speed rtsp option?


thanks in advance
zhi









-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20180202/b3a85895/attachment-0001.html>


More information about the gstreamer-devel mailing list