XINE, A Free Video Player Project - API reference

Main Page Modules Data Structures File List Data Fields Globals

# Engine management

## Defines
#define | SPEED_PAUSE 0
#define | SPEED_SLOW_4 1
#define | SPEED_SLOW_2 2
#define | SPEED_NORMAL 4
#define | SPEED_FAST_2 8
#define | SPEED_FAST_4 16
## Functions
void | xine_play (xine_t *self, char *MRL, int start_pos, int start_time)
| Start to play a stream.
void | xine_set_speed (xine_t *self, int speed)
| Set playback speed.
int | xine_get_speed (xine_t *self)
| Get the playback speed.
void | xine_set_av_offset (xine_t *self, int offset_pts)
| Set audio/video sync.
int | xine_get_av_offset (xine_t *self)
| Get audio/video sync.
void | xine_stop (xine_t *self)
| Stop playing.
int | xine_eject (xine_t *self)
| Eject media.
int | xine_get_status (xine_t *self)
| Get current xine status.
int | xine_get_current_position (xine_t *self)
| Get current position.
int | xine_get_current_time (xine_t *self)
| get current pos in seconds.
int | xine_get_stream_length (xine_t *self)
| estimate length of input stream in seconds.
int | xine_get_audio_channel (xine_t *self)
| Get current audio channel.
void | xine_select_audio_channel (xine_t *self, int channel)
| Set audio channel.
int | xine_get_spu_channel (xine_t *self)
| Get current sub-title channel.
void | xine_select_spu_channel (xine_t *self, int channel)
| Set sub-title channel.

## Define Documentation

#define SPEED_FAST_2 8

| Playback at 200% speed. See also: xine_set_speed(), xine_get_speed()

#define SPEED_FAST_4 16

| Playback at 400% speed. See also: xine_set_speed(), xine_get_speed()

#define SPEED_NORMAL 4

| Playback at 100% speed. See also: xine_set_speed(), xine_get_speed()

#define SPEED_PAUSE 0

| Playback pause. See also: xine_set_speed(), xine_get_speed()

#define SPEED_SLOW_2 2

| Playback at 50% speed. See also: xine_set_speed(), xine_get_speed()

#define SPEED_SLOW_4 1

| Playback at 25% speed. See also: xine_set_speed(), xine_get_speed()

## Function Documentation

int xine_eject ( | xine_t * self )

  | Eject media. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: 1 on success, 0 on failure. Tell current input plugin to eject media. Parameters:
  self |

int xine_get_audio_channel ( | xine_t * self )

  | Get current audio channel. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Current audio chennel Get current audio channel. Parameters:
  self |

int xine_get_av_offset ( | xine_t * self )

  | Get audio/video sync. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Current audio/video offset. Return the current audio/video sync offset ( see xine_set_av_offset() ). Parameters:
  self |

int xine_get_current_position ( | xine_t * self )

  | Get current position. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Current position ( 0..65535 ) Get current position in stream. Parameters:
  self |

int xine_get_current_time ( | xine_t * self )

  | get current pos in seconds. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: current position measured in seconds from the beginning of the stream get current position measured in seconds from the beginning of the stream Parameters:
  self |

int xine_get_speed ( | xine_t * self )

  | Get the playback speed. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: speed value ( see SPEED_PAUSE, SPEED_SLOW_4, SPEED_SLOW_2, SPEED_NORMAL, SPEED_FAST_2, SPEED_FAST_4 ) Get the current speed playback. Possible values are SPEED_PAUSE, SPEED_SLOW_4, SPEED_SLOW_2, SPEED_NORMAL, SPEED_FAST_2, SPEED_FAST_4. Parameters:
  self |

int xine_get_spu_channel ( | xine_t * self )

  | Get current sub-title channel. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Current sub-title channel Get current sub-title channel. Parameters:
  self |

int xine_get_status ( | xine_t * self )

  | Get current xine status. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Current status ( see Player status constants ) Return the current state of xine engine. Parameters:
  self |

int xine_get_stream_length ( | xine_t * self )

  | estimate length of input stream in seconds. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: length of input stream in seconds or 0 if stream is not seekable estimate length of input stream in seconds Parameters:
  self |

void xine_play ( | xine_t * self,
| char * MRL,
| int start_pos,
| int start_time )

  | Start to play a stream. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  MRL | Media Resource Location to open
  start_pos | position in input source (0..65535)
  start_time | position measured in seconds from stream start
  Returns: Nothing Open a stream and play it. If both start position parameters are !=0 start_pos will be used for non-seekable streams both values will be ignored Parameters:
  self |
  MRL |
  start_pos |
  start_time |

void xine_select_audio_channel ( | xine_t * self,
| int channel )

  | Set audio channel. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Nothing Set desired audio channel. Parameters:
  self |
  channel |

void xine_select_spu_channel ( | xine_t * self,
| int channel )

  | Set sub-title channel. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Nothing Set desired sub-title channel. Parameters:
  self |
  channel |

void xine_set_av_offset ( | xine_t * self,
| int offset_pts )

  | Set audio/video sync. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  offset_pts | New pts.
  Returns: Nothing Set audio/video sync offset, according to offset_pts value ( see xine_get_av_offset() ). Parameters:
  self |
  offset_pts |

void xine_set_speed ( | xine_t * self,
| int speed )

  | Set playback speed. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  speed | Desired playback speed ( see SPEED_PAUSE, SPEED_SLOW_4, SPEED_SLOW_2, SPEED_NORMAL, SPEED_FAST_2, SPEED_FAST_4 )
  Returns: Nothing Set the playback speed to desired speed, according of SPEED_x constant. Parameters:
  self |
  speed |

void xine_stop ( | xine_t * self )

  | Stop playing. Parameters:
  self | Current xine engine configuration ( see xine_init() )
  Returns: Nothing Stop the playback. Parameters:
  self |