Libnemesi internals

Libnemesi is implemented with several nested threads dispatched for every session. Within the main thread we send requests to the various servers identified by an RTSP Controller structure, then a thread is dispatched to handle responses.

  • First of all by calling rtsp_init we create an RTSP thread which handles incoming RTSP packets.
  • The RTSP thread as soon as it receives a valid SETUP response from the server creates two different threads to handle RTP and RTCP packets
  • The RTP thread as soon as its created initializes the various parsers for the session
  • Then all the threads will run handling the packets of their specific layer until the RTSP thread for the given session is terminated.

This is a brief documentation of the various layers involved in libnemesi

libnemesi Reference: Doxygenerated reference for libnemesi

RTSP Layer: How the RTSP layer in libnemesi works

RTP Layer: Quick description of the RTP layer in libnemesi

RTCP Layer: How libnemesi implements the RTCP protocol

SDP parser: Libnemesi implements a simple SDP parser for sessions. This is how it works