00001 #ifndef XINE_DEMUX_SPUTEXT_H
00002 #define XINE_DEMUX_SPUTEXT_H
00003
00004 #ifdef __cplusplus
00005 extern "C" {
00006 #endif
00007
00008 #include <ctype.h>
00009 #include <stdio.h>
00010
00011 #define SUB_BUFSIZE 1024
00012 #define SUB_MAX_TEXT 5
00013 #define MAX_TIMEOUT 4
00014
00015 #define DEBUG_XINE_DEMUX_SPUTEXT 1
00016
00017 typedef struct {
00018
00019 int lines;
00020
00021 long start;
00022 long end;
00023
00024 char *text[SUB_MAX_TEXT];
00025 } subtitle_t;
00026
00027 typedef struct {
00028
00029 FILE* file_ptr;
00030
00031 int status;
00032
00033 char buf[SUB_BUFSIZE];
00034 off_t buflen;
00035
00036 float mpsub_position;
00037
00038 int uses_time;
00039 int errs;
00040 subtitle_t *subtitles;
00041 int num;
00042 int cur;
00043 int format;
00044 char next_line[SUB_BUFSIZE];
00045
00046 } demux_sputext_t;
00047
00048
00049 subtitle_t *sub_read_file (demux_sputext_t*);
00050
00051 #ifdef __cplusplus
00052 }
00053 #endif
00054
00055 #endif