/* send RTSP PLAY request */
static void rtsp_play(CURL *curl, const char *uri, const char *range)
{
CURLcode res = CURLE_OK;
printf("\nRTSP: PLAY %s\n", uri);
my_curl_easy_setopt(curl, CURLOPT_RTSP_STREAM_URI, uri);
my_curl_easy_setopt(curl, CURLOPT_RANGE, range);
my_curl_easy_setopt(curl, CURLOPT_RTSP_REQUEST, (long)CURL_RTSPREQ_PLAY);
my_curl_easy_perform(curl);
my_curl_easy_setopt(curl, CURLOPT_RANGE, NULL);
/* fp=popen( "gst-launch-1.0 videotestsrc ! openh264enc ! rtph264pay config-interval=10 pt=96 ! udpsink rtsp://freja.hiof.no:1935/rtplive/definst/hessdalen03.stream","r" ); */
my_curl_easy_perform(curl);
/* switch off using range again */
my_curl_easy_setopt(curl, CURLOPT_RANGE, NULL);
}