Authentication methods, ordered by strength Opaque RTSP connection object. Clear the list of authentication directives stored in @conn. Close the connected @conn. After this call, the connection is in the same state as when it was first created. #GST_RTSP_OK on success. Attempt to connect to the url of @conn made with gst_rtsp_connection_create(). If @timeout is #NULL this function can block forever. If @timeout contains a valid timeout, this function will return #GST_RTSP_ETIMEOUT after the timeout expired. This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK when a connection could be made. a #GTimeVal timeout If @conn received the first tunnel connection and @conn2 received the second tunnel connection, link the two connections together so that After this call, @conn2 cannot be used anymore and must be freed with gst_rtsp_connection_free(). If @conn2 is %NULL then only the base64 decoding context will be setup for return GST_RTSP_OK on success. a #GstRTSPConnection or %NULL Start or stop the flushing action on @conn. When flushing, all current and future actions on @conn will return #GST_RTSP_EINTR until the connection is set to non-flushing mode again. #GST_RTSP_OK. start or stop the flush Close and free @conn. #GST_RTSP_OK on success. Retrieve the IP address of the other end of @conn. connection is closed. The IP address as a string. this value remains valid until the Get the file descriptor for reading. descriptor remains valid until the connection is closed. the file descriptor used for reading or -1 on error. The file Get the tunnel session id the connection. returns a non-empty string if @conn is being tunneled over HTTP. Retrieve the URL of the other end of @conn. connection is freed. The URL. This value remains valid until the Get the file descriptor for writing. descriptor remains valid until the connection is closed. the file descriptor used for writing or -1 on error. The file Get the tunneling state of the connection. if @conn is using HTTP tunneling. Calculate the next timeout for @conn, storing the result in @timeout. #GST_RTSP_OK. a timeout Wait up to the specified @timeout for the connection to become available for at least one of the operations specified in @events. When the function returns with #GST_RTSP_OK, @revents will contain a bitmask of available operations on This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK on success. a bitmask of #GstRTSPEvent flags to check location for result flags a timeout Attempt to read @size bytes into @data from the connected @conn, blocking up to the specified @timeout. @timeout can be #NULL, in which case this function might block forever. This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK on success. the data to read the size of @data a timeout value or #NULL Attempt to read into @message from the connected @conn, blocking up to the specified @timeout. @timeout can be #NULL, in which case this function might block forever. This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK on success. the message to read a timeout value or #NULL Reset the timeout of @conn. #GST_RTSP_OK. Attempt to send @message to the connected @conn, blocking up to the specified @timeout. @timeout can be #NULL, in which case this function might block forever. This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK on success. the message to send a timeout value or #NULL Configure @conn for authentication mode @method with @user and @pass as the user and password respectively. #GST_RTSP_OK. authentication method the user the password Setup @conn with authentication directives. This is not necesary for methods #GST_RTSP_AUTH_NONE and #GST_RTSP_AUTH_BASIC. For #GST_RTSP_AUTH_DIGEST, directives should be taken from the digest challenge in the WWW-Authenticate response header and can include realm, domain, nonce, opaque, stale, algorithm, qop as per RFC2617. authentication directive value By setting the HTTP mode to %TRUE the message parsing will support HTTP messages in addition to the RTSP messages. It will also disable the automatic handling of setting up an HTTP tunnel. %TRUE to enable manual HTTP mode Set the IP address of the server. an ip address Set the proxy host and port. #GST_RTSP_OK. the proxy host the proxy port Configure @conn to use the specified DSCP value. #GST_RTSP_OK on success. DSCP value Set the HTTP tunneling state of the connection. This must be configured before the @conn is connected. the new state Attempt to write @size bytes of @data to the connected @conn, blocking up to the specified @timeout. @timeout can be #NULL, in which case this function might block forever. This function can be cancelled with gst_rtsp_connection_flush(). #GST_RTSP_OK on success. the data to write the size of @data a timeout value or #NULL The possible events for the connection. The possible network families. The different transport methods. An RTSP message containing request, response or data messages. Depending on the @type, the appropriate structure may be accessed. Add a header with key @field and @value to @msg. This function takes a copy of @value. a #GstRTSPResult. a #GstRTSPHeaderField the value of the header Append the currently configured headers in @msg to the #GString @str suitable for transmission. #GST_RTSP_OK. a string Dump the contents of @msg to stdout. #GST_RTSP_OK. Free the memory used by @msg. a #GstRTSPResult. Get the body of @msg. @data remains valid for as long as @msg is valid and unchanged. #GST_RTSP_OK. location for the data location for the size of @data Get the @indx header value with key @field from @msg. The result in @value stays valid as long as it remains present in @msg. was not found. #GST_RTSP_OK when @field was found, #GST_RTSP_ENOTIMPL if the key a #GstRTSPHeaderField pointer to hold the result the index of the header Initialize @msg. This function is mostly used when @msg is allocated on the stack. The reverse operation of this is gst_rtsp_message_unset(). a #GstRTSPResult. Initialize a new data #GstRTSPMessage for @channel. a #GstRTSPResult. a channel Initialize @msg as a request message with @method and @uri. To clear @msg again, use gst_rtsp_message_unset(). a #GstRTSPResult. the request method to use the uri of the request Initialize @msg with @code and @reason. When @reason is #NULL, the default reason for @code will be used. When @request is not #NULL, the relevant headers will be copied to the new response message. a #GstRTSPResult. the status code the status reason or #NULL the request that triggered the response or #NULL Parse the data message @msg and store the channel in @channel. a #GstRTSPResult. location to hold the channel Parse the request message @msg and store the values @method, @uri and value. a #GstRTSPResult. location to hold the method location to hold the uri location to hold the version Parse the response message @msg and store the values @code, @reason and value. a #GstRTSPResult. location to hold the status code location to hold the status reason location to hold the version Remove the @indx header with key @field from @msg. If @indx equals -1, all headers will be removed. a #GstRTSPResult. a #GstRTSPHeaderField the index of the header Set the body of @msg to a copy of @data. #GST_RTSP_OK. the data the size of @data Take the body of @msg and store it in @data and @size. After this method, the body and size of @msg will be set to #NULL and 0 respectively. #GST_RTSP_OK. location for the data location for the size of @data Set the body of @msg to @data and @size. This method takes ownership of #GST_RTSP_OK. the data the size of @data Add a header with key @field and @value to @msg. This function takes ownership of @value. a #GstRTSPResult. a #GstRTSPHeaderField the value of the header Unset the contents of @msg so that it becomes an uninitialized #GstRTSPMessage again. This function is mostly used in combination with gst_rtsp_message_init_request(), gst_rtsp_message_init_response() and gst_rtsp_message_init_data() on stack allocated #GstRTSPMessage structures. #GST_RTSP_OK. The different supported RTSP methods. The type of a message. The transfer profile to use. A type to specify a range. Different possible time range units. Result codes from the RTSP functions. The different RTSP states. A time indication. A time range. Possible time types. The transfer mode to use. A structure holding the RTSP transport values. Convert @transport into a string that can be used to signal the transport in an RTSP SETUP response. is invalid. a string describing the RTSP transport or #NULL when the transport Free the memory used by @transport. #GST_RTSP_OK. Initialize @transport so that it can be used. #GST_RTSP_OK. This structure contains the result of a parsed RTSP URL Make a copy of @url. a copy of @url. Free with gst_rtsp_url_free () after usage. Splits the path of @url on '/' boundaries, decoding the resulting components, The decoding performed by this routine is "URI decoding", as defined in RFC 3986, commonly known as percent-decoding. For example, a string "foo%2fbar" will decode to "foo/bar" -- the %2f being replaced by the corresponding byte with hex value 0x2f. Note that there is no guarantee that the resulting byte sequence is valid in any given encoding. As a special case, %00 is not unescaped to NUL, as that would prematurely terminate the string. Also note that since paths usually start with a slash, the first component will usually be the empty string. a string vector. g_strfreev() after usage. Free the memory used by @url. Get the port number of @url. #GST_RTSP_OK. location to hold the port Get a newly allocated string describing the request URI for @url. a string with the request URI. g_free() after usage. Set the port number in @url to @port. #GST_RTSP_OK. the port The supported RTSP versions. Opaque RTSP watch object that can be used for asynchronous RTSP operations. Adds a #GstRTSPWatch to a context so that it will be executed within that context. the ID (greater than 0) for the watch within the GMainContext. a GMainContext (if NULL, the default context will be used) Queue @data for transmission in @watch. It will be transmitted when the connection of the @watch becomes writable. This function will take ownership of @data and g_free() it after use. The return value of this function will be used as the id argument in the message_sent callback. an id. the data to queue the size of @data Queue a @message for transmission in @watch. The contents of this message will be serialized and transmitted when the connection of the The return value of this function will be used as the id argument in the message_sent callback. an id. a #GstRTSPMessage Reset @watch, this is usually called after gst_rtsp_connection_do_tunnel() when the file descriptors of the connection might have changed. Send a @message using the connection of the @watch. If it cannot be sent immediately, it will be queued for transmission in @watch. The contents of callback. #GST_RTSP_OK on success. a #GstRTSPMessage location for a message ID or %NULL Decreases the reference count of @watch by one. If the resulting reference count is zero the watch and associated memory will be destroyed. Write @data using the connection of the @watch. If it cannot be sent immediately, it will be queued for transmission in @watch. The contents of callback. This function will take ownership of @data and g_free() it after use. #GST_RTSP_OK on success. the data to queue the size of @data location for a message ID or %NULL Callback functions from a #GstRTSPWatch. Decode the base64 string pointed to by @data in-place. When @len is not #NULL it will contain the length of the decoded data. the base64 encoded data location for output length or NULL Encode a sequence of binary data into its Base-64 stringified representation. representing @data. a newly allocated, zero-terminated Base-64 encoded string the binary data to encode the length of @data Accept a new connection on @sock and create a new #GstRTSPConnection for handling communication on new socket. #GST_RTSP_OK when @conn contains a valid connection. a socket storage for a #GstRTSPConnection Create a newly allocated #GstRTSPConnection from @url and store it in @conn. The connection will not yet attempt to connect to @url, use gst_rtsp_connection_connect(). A copy of @url will be made. #GST_RTSP_OK when @conn contains a valid connection. a #GstRTSPUrl storage for a #GstRTSPConnection Create a new #GstRTSPConnection for handling communication on the existing file descriptor @fd. The @initial_buffer contains any data already read from #GST_RTSP_OK when @conn contains a valid connection. a file descriptor the IP address of the other end the port used by the other end data already read from @fd storage for a #GstRTSPConnection Convert @header to a #GstRTSPHeaderField. header field is unknown. a #GstRTSPHeaderField for @header or #GST_RTSP_HDR_INVALID if the a header string Convert @method to a #GstRTSPMethod. method is unknown. a #GstRTSPMethod for @method or #GST_RTSP_INVALID if the a method Check whether @field may appear multiple times in a message. %TRUE if multiple headers are allowed. a #GstRTSPHeaderField Convert @field to a string. a string representation of @field. a #GstRTSPHeaderField Get the message type of @msg. the message type. a #GstRTSPMessage Create a new initialized #GstRTSPMessage. Free with gst_rtsp_message_free(). a #GstRTSPResult. a location for the new #GstRTSPMessage Create a new data #GstRTSPMessage with @channel and store the result message in @msg. Free with gst_rtsp_message_free(). a #GstRTSPResult. a location for the new #GstRTSPMessage the channel Create a new #GstRTSPMessage with @method and @uri and store the result request message in @msg. Free with gst_rtsp_message_free(). a #GstRTSPResult. a location for the new #GstRTSPMessage the request method to use the uri of the request Create a new response #GstRTSPMessage with @code and @reason and store the result message in @msg. Free with gst_rtsp_message_free(). When @reason is #NULL, the default reason for @code will be used. When @request is not #NULL, the relevant headers will be copied to the new response message. a #GstRTSPResult. a location for the new #GstRTSPMessage the status code the status reason or #NULL the request that triggered the response or #NULL Convert @method to a string. a string representation of @method. a #GstRTSPMethod Convert @options to a string. a new string of @options. g_free() after usage. one or more #GstRTSPMethod Free the memory alocated by @range. a #GstRTSPTimeRange Parse @rangestr to a #GstRTSPTimeRange. #GST_RTSP_OK on success. a range string to parse location to hold the #GstRTSPTimeRange result Convert @range into a string representation. The string representation of @range. g_free() after usage. a #GstRTSPTimeRange Convert @code to a string. a string representation of @code. a #GstRTSPStatusCode Convert @result in a human readable string. a newly allocated string. g_free() after usage. a #GstRTSPResult Get the #GStreamer element that can handle the buffers transported over It is possible that there are several managers available, use @option to selected one. needed/available for @trans. #GST_RTSP_OK. a #GstRTSPTransMode location to hold the result option index. Get the mime type of the transport mode @trans. This mime type is typically used to generate #GstCaps on buffers. #GST_RTSP_OK. a #GstRTSPTransMode location to hold the result Allocate a new initialized #GstRTSPTransport. Use gst_rtsp_transport_free() after usage. a #GstRTSPResult. location to hold the new #GstRTSPTransport Parse the RTSP transport string @str into @transport. a #GstRTSPResult. a transport string a #GstRTSPTransport Parse the RTSP @urlstr into a newly allocated #GstRTSPUrl. Free after usage with gst_rtsp_url_free(). a #GstRTSPResult. the url string to parse location to hold the result. Convert @version to a string. a string representation of @version. a #GstRTSPVersion Create a watch object for @conn. The functions provided in @funcs will be called with @user_data when activity happened on the watch. The new watch is usually created so that it can be attached to a maincontext with gst_rtsp_watch_attach(). communication. Free with gst_rtsp_watch_unref () after usage. a #GstRTSPWatch that can be used for asynchronous RTSP a #GstRTSPConnection watch functions user data to pass to @funcs notify when @user_data is not referenced anymore