xine-lib 1.2.13-20230125hg15249
Data Structures | Macros | Functions | Variables
input_rtp.c File Reference
#include <stdio.h>
#include <unistd.h>
#include <fcntl.h>
#include <string.h>
#include <sys/ioctl.h>
#include <errno.h>
#include <pthread.h>
#include <sys/time.h>
#include <stdlib.h>
#include <net/if.h>
#include <sys/select.h>
#include <xine/xine_internal.h>
#include <xine/xineutils.h>
#include <xine/input_plugin.h>
#include "net_buf_ctrl.h"
#include "input_helper.h"

Data Structures

struct  rtp_input_plugin_t
 

Macros

#define LOG_MODULE   "input_rtp"
 
#define LOG_VERBOSE
 
#define LOG_MSG(xine, ...)
 
#define BUFFER_SIZE   (1024*1024)
 

Functions

static int host_connect_attempt (struct in_addr ia, int port, const char *interface, xine_t *xine)
 
static int host_connect (const char *host, int port, const char *interface, xine_t *xine)
 
static void * input_plugin_read_loop (void *arg)
 
static off_t rtp_plugin_read (input_plugin_t *this_gen, void *buf_gen, off_t length)
 
static off_t rtp_plugin_seek (input_plugin_t *this_gen, off_t offset, int origin)
 
static off_t rtp_plugin_get_length (input_plugin_t *this_gen)
 
static off_t rtp_plugin_get_current_pos (input_plugin_t *this_gen)
 
static const char * rtp_plugin_get_mrl (input_plugin_t *this_gen)
 
static int rtp_plugin_get_optional_data (input_plugin_t *this_gen, void *data, int data_type)
 
static void rtp_plugin_dispose (input_plugin_t *this_gen)
 
static int rtp_plugin_open (input_plugin_t *this_gen)
 
static input_plugin_trtp_class_get_instance (input_class_t *cls_gen, xine_stream_t *stream, const char *data)
 
static void * init_class (xine_t *xine, const void *data)
 

Variables

const plugin_info_t xine_plugin_info[] EXPORTED
 

Macro Definition Documentation

◆ BUFFER_SIZE

#define BUFFER_SIZE   (1024*1024)

◆ LOG_MODULE

#define LOG_MODULE   "input_rtp"

◆ LOG_MSG

#define LOG_MSG ( xine,
... )
Value:
{ \
xine_log(xine, XINE_LOG_MSG, __VA_ARGS__); \
lprintf(__VA_ARGS__); \
}
#define XINE_LOG_MSG
Definition xine_internal.h:64

Referenced by host_connect(), host_connect_attempt(), input_plugin_read_loop(), rtp_plugin_dispose(), and rtp_plugin_open().

◆ LOG_VERBOSE

#define LOG_VERBOSE

Function Documentation

◆ host_connect()

static int host_connect ( const char * host,
int port,
const char * interface,
xine_t * xine )
static

References _, host_connect_attempt(), LOG_MSG, and NULL.

Referenced by rtp_plugin_open().

◆ host_connect_attempt()

static int host_connect_attempt ( struct in_addr ia,
int port,
const char * interface,
xine_t * xine )
static

References _, BUFFER_SIZE, LOG_MSG, NULL, and xine_socket_cloexec().

Referenced by host_connect().

◆ init_class()

static void * init_class ( xine_t * xine,
const void * data )
static

◆ input_plugin_read_loop()

static void * input_plugin_read_loop ( void * arg)
static

References _, BUFFER_SIZE, LOG_MSG, and NULL.

Referenced by rtp_plugin_open().

◆ rtp_class_get_instance()

static input_plugin_t * rtp_class_get_instance ( input_class_t * cls_gen,
xine_stream_t * stream,
const char * data )
static

◆ rtp_plugin_dispose()

static void rtp_plugin_dispose ( input_plugin_t * this_gen)
static

References _, _x_freep(), LOG_MSG, nbc_close, and NULL.

Referenced by rtp_class_get_instance().

◆ rtp_plugin_get_current_pos()

static off_t rtp_plugin_get_current_pos ( input_plugin_t * this_gen)
static

Referenced by rtp_class_get_instance().

◆ rtp_plugin_get_length()

static off_t rtp_plugin_get_length ( input_plugin_t * this_gen)
static

Referenced by rtp_class_get_instance().

◆ rtp_plugin_get_mrl()

static const char * rtp_plugin_get_mrl ( input_plugin_t * this_gen)
static

Referenced by rtp_class_get_instance().

◆ rtp_plugin_get_optional_data()

static int rtp_plugin_get_optional_data ( input_plugin_t * this_gen,
void * data,
int data_type )
static

◆ rtp_plugin_open()

static int rtp_plugin_open ( input_plugin_t * this_gen)
static

◆ rtp_plugin_read()

static off_t rtp_plugin_read ( input_plugin_t * this_gen,
void * buf_gen,
off_t length )
static

◆ rtp_plugin_seek()

static off_t rtp_plugin_seek ( input_plugin_t * this_gen,
off_t offset,
int origin )
static

Variable Documentation

◆ EXPORTED

const plugin_info_t xine_plugin_info [] EXPORTED
Initial value:
= {
{ PLUGIN_NONE, 0, NULL, 0, NULL, NULL }
}
static void * init_class(xine_t *xine, const void *data)
Definition input_rtp.c:765
#define XINE_VERSION_CODE
Definition xine_internal.h:57
NULL
Definition xine_plugin.c:78
#define PLUGIN_NONE
Definition xine_plugin.h:29
#define PLUGIN_INPUT
Definition xine_plugin.h:30