xine-lib 1.2.11
Data Structures | Macros | Typedefs | Functions | Variables
mmal.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#include <bcm_host.h>
#include <interface/mmal/mmal.h>
#include <interface/mmal/util/mmal_util.h>
#include <interface/mmal/util/mmal_default_components.h>
#include <xine/xine_internal.h>
#include <xine/video_out.h>
#include <xine/buffer.h>
#include <xine/xineutils.h>

Data Structures

struct  mmal_decoder_s
 

Macros

#define LOG_MODULE   "mmal_video_decoder"
 

Typedefs

typedef struct mmal_decoder_s mmal_decoder_t
 

Functions

static void free_output_buffer (MMAL_BUFFER_HEADER_T *buffer)
 
static int send_output_buffer (mmal_decoder_t *this)
 
static void fill_output_port (mmal_decoder_t *this)
 
static void control_port_cb (MMAL_PORT_T *port, MMAL_BUFFER_HEADER_T *buffer)
 
static void input_port_cb (MMAL_PORT_T *port, MMAL_BUFFER_HEADER_T *buffer)
 
static void output_port_cb (MMAL_PORT_T *port, MMAL_BUFFER_HEADER_T *buffer)
 
static void stop_codec (mmal_decoder_t *this)
 
static int start_codec (mmal_decoder_t *this)
 
static void send_frames (mmal_decoder_t *this)
 
static int change_output_format (mmal_decoder_t *this)
 
static void handle_output (mmal_decoder_t *this)
 
static void set_extradata (mmal_decoder_t *this, void *extradata, size_t extradata_size)
 
static void free_input_buffer (mmal_decoder_t *this)
 
static MMAL_BUFFER_HEADER_T * get_input_buffer (mmal_decoder_t *this)
 
static int send_input_buffer (mmal_decoder_t *this)
 
static void handle_header (mmal_decoder_t *this, buf_element_t *buf)
 
static void mmal_decode_data (video_decoder_t *this_gen, buf_element_t *buf)
 
static void mmal_flush (video_decoder_t *this_gen)
 
static void mmal_reset (video_decoder_t *this_gen)
 
static void mmal_discontinuity (video_decoder_t *this_gen)
 
static void mmal_dispose (video_decoder_t *this_gen)
 
static video_decoder_topen_plugin (video_decoder_class_t *class_gen, xine_stream_t *stream)
 
static void * init_plugin (xine_t *xine, const void *data)
 

Variables

static const uint32_t video_types []
 
static const decoder_info_t dec_info
 
const plugin_info_t xine_plugin_info[] EXPORTED
 

Macro Definition Documentation

◆ LOG_MODULE

#define LOG_MODULE   "mmal_video_decoder"

Typedef Documentation

◆ mmal_decoder_t

Function Documentation

◆ change_output_format()

static int change_output_format ( mmal_decoder_t this)
static

◆ control_port_cb()

static void control_port_cb ( MMAL_PORT_T *  port,
MMAL_BUFFER_HEADER_T *  buffer 
)
static

References LOG_MODULE, XINE_VERBOSITY_LOG, and xprintf.

Referenced by mmal_reset(), and open_plugin().

◆ fill_output_port()

static void fill_output_port ( mmal_decoder_t this)
static

References send_output_buffer().

Referenced by output_port_cb(), and send_frames().

◆ free_input_buffer()

static void free_input_buffer ( mmal_decoder_t this)
static

References NULL.

Referenced by mmal_dispose(), mmal_reset(), and send_input_buffer().

◆ free_output_buffer()

static void free_output_buffer ( MMAL_BUFFER_HEADER_T *  buffer)
static

◆ get_input_buffer()

static MMAL_BUFFER_HEADER_T * get_input_buffer ( mmal_decoder_t this)
static

◆ handle_header()

static void handle_header ( mmal_decoder_t this,
buf_element_t buf 
)
static

◆ handle_output()

static void handle_output ( mmal_decoder_t this)
static

◆ init_plugin()

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

◆ input_port_cb()

static void input_port_cb ( MMAL_PORT_T *  port,
MMAL_BUFFER_HEADER_T *  buffer 
)
static

◆ mmal_decode_data()

static void mmal_decode_data ( video_decoder_t this_gen,
buf_element_t buf 
)
static

◆ mmal_discontinuity()

static void mmal_discontinuity ( video_decoder_t this_gen)
static

References send_input_buffer(), and xine_container_of.

Referenced by open_plugin().

◆ mmal_dispose()

static void mmal_dispose ( video_decoder_t this_gen)
static

◆ mmal_flush()

static void mmal_flush ( video_decoder_t this_gen)
static

References send_frames(), and xine_container_of.

Referenced by open_plugin().

◆ mmal_reset()

static void mmal_reset ( video_decoder_t this_gen)
static

◆ open_plugin()

static video_decoder_t * open_plugin ( video_decoder_class_t class_gen,
xine_stream_t stream 
)
static

◆ output_port_cb()

static void output_port_cb ( MMAL_PORT_T *  port,
MMAL_BUFFER_HEADER_T *  buffer 
)
static

◆ send_frames()

static void send_frames ( mmal_decoder_t this)
static

◆ send_input_buffer()

static int send_input_buffer ( mmal_decoder_t this)
static

◆ send_output_buffer()

static int send_output_buffer ( mmal_decoder_t this)
static

◆ set_extradata()

static void set_extradata ( mmal_decoder_t this,
void *  extradata,
size_t  extradata_size 
)
static

◆ start_codec()

static int start_codec ( mmal_decoder_t this)
static

◆ stop_codec()

static void stop_codec ( mmal_decoder_t this)
static

Referenced by mmal_dispose(), and mmal_reset().

Variable Documentation

◆ dec_info

const decoder_info_t dec_info
static
Initial value:
= {
.supported_types = video_types,
.priority = 10,
}
static const uint32_t video_types[]
Definition: mmal.c:860

◆ EXPORTED

const plugin_info_t xine_plugin_info [] EXPORTED
Initial value:
= {
{ PLUGIN_NONE, 0, NULL, 0, NULL, NULL }
}
static const decoder_info_t dec_info
Definition: mmal.c:868
static void * init_plugin(xine_t *xine, const void *data)
Definition: mmal.c:844
#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_VIDEO_DECODER
Definition: xine_plugin.h:33

◆ video_types

const uint32_t video_types[]
static
Initial value:
= {
0
}
#define BUF_VIDEO_JPEG
Definition: buffer.h:108
#define BUF_VIDEO_MPEG
Definition: buffer.h:91
#define BUF_VIDEO_H264
Definition: buffer.h:167
#define BUF_VIDEO_VC1
Definition: buffer.h:191