00001 #ifndef XINE_DEMUX_SPUTEXT_H 00002 #define XINE_DEMUX_SPUTEXT_H 00003 00004 #include "ringbuffer.h" 00005 00006 #define SUB_BUFSIZE 1024 00007 #define SUB_MAX_TEXT 5 00008 #define MAX_TIMEOUT 4 00009 00010 #define DEBUG_XINE_DEMUX_SPUTEXT 0 00011 00012 typedef struct { 00013 00014 int lines; 00015 00016 long start; 00017 long end; 00018 00019 char *text[SUB_MAX_TEXT]; 00020 } subtitle_t; 00021 00022 typedef struct { 00023 00024 RingBuffer* rbuffer; 00025 00026 int status; 00027 00028 char buf[SUB_BUFSIZE]; 00029 off_t buflen; 00030 off_t emptyReads; 00031 00032 float mpsub_position; 00033 00034 int uses_time; 00035 int errs; 00036 subtitle_t *subtitles; 00037 int num; /* number of subtitle structs */ 00038 int cur; /* current subtitle */ 00039 int format; /* constants see below */ 00040 char next_line[SUB_BUFSIZE]; /* a buffer for next line read from file */ 00041 00042 } demux_sputext_t; 00043 00044 00045 subtitle_t *sub_read_file (demux_sputext_t*); 00046 00047 #endif
1.6.3