xine-lib 1.2.13-20230125hg15249
Macros | Functions
vcdio.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <fcntl.h>
#include <time.h>
#include <string.h>
#include <errno.h>
#include "libvcd/types.h"
#include "libvcd/files.h"
#include "cdio/iso9660.h"
#include "vcdplayer.h"
#include "vcdio.h"

Macros

#define LOG_ERR(p_vcdplayer, s, args...)
 
#define dbg_print(p_vcdplayer, mask, s, args...)
 
#define FREE_AND_NULL(ptr)   if (NULL != ptr) free(ptr); ptr = NULL;
 

Functions

int vcdio_close (vcdplayer_t *p_vcdplayer)
 
bool vcdio_open (vcdplayer_t *p_vcdplayer, char *intended_vcd_device)
 
off_t vcdio_seek (vcdplayer_t *p_vcdplayer, off_t offset, int origin)
 

Macro Definition Documentation

◆ dbg_print

#define dbg_print ( p_vcdplayer,
mask,
s,
args... )
Value:
if (p_vcdplayer->log_msg) \
p_vcdplayer->log_msg (p_vcdplayer->user_data, mask, "%s: "s, __func__ , ##args)

Referenced by vcdio_open(), and vcdio_seek().

◆ FREE_AND_NULL

#define FREE_AND_NULL ( ptr)    if (NULL != ptr) free(ptr); ptr = NULL;

Referenced by vcdio_close().

◆ LOG_ERR

#define LOG_ERR ( p_vcdplayer,
s,
args... )
Value:
if (p_vcdplayer->log_err) \
p_vcdplayer->log_err (p_vcdplayer->user_data, ~0, "%s: "s, __func__ , ##args)

Referenced by vcdio_seek().

Function Documentation

◆ vcdio_close()

int vcdio_close ( vcdplayer_t * p_vcdplayer)

◆ vcdio_open()

bool vcdio_open ( vcdplayer_t * p_vcdplayer,
char * intended_vcd_device )

Opens VCD device and initializes things.

  • do nothing if the device had already been open and is the same device.
  • if the device had been open and is a different, close it before trying to open new device.

References vcdplayer_s::b_opened, dbg_print, vcdplayer_s::entry, vcdplayer_s::i_entries, vcdplayer_s::i_lids, vcdplayer_s::i_segments, vcdplayer_s::i_still, vcdplayer_s::i_tracks, INPUT_DBG_CALL, NULL, vcdplayer_s::psz_source, vcdplayer_s::segment, vcdplayer_play_item_info_t::size, vcdplayer_play_item_info_t::start_LSN, vcdplayer_s::track, vcdplayer_s::vcd, vcdplayer_s::vcd_format, and vcdio_close().

Referenced by vcd_build_mrl_list(), and vcd_plugin_read_block().

◆ vcdio_seek()

off_t vcdio_seek ( vcdplayer_t * p_vcdplayer,
off_t offset,
int origin )