view asxparser.h @ 22771:ce6b4af46882

r22547: fix up some longer than 80 char lines , and use suggestion from Diego. r22570: dont start newline with a space and readd subdirectory r22718: add new audio and video codecs to libavcodec list r22748: add png and gif encoders, how to use them with mencoder is another question r22749: split sonic into sonic/sonicls and wma into wmav1/wmav2 r22750: add rest of lavc encoders to list (vcr1, cljr, jpegls, ffvhuff, msmpeg4v1) r22751: gsm requires libgsm so remove it r22752: aiff isnt there as well, TEST FIRST, THEN DOCUMENT COMPN! r22753: ok so cljr , vcr1 and msmpegv1 dont actually work... removed r22679: Some more details for the mga_vid section taken from drivers/README. r22686: tdfx_vid compilation has been simplified. r22695: Add a link to Attila's mga_vid port to Linux 2.6.x. r22704: 'make install' now takes care of most manual installation steps for *_vid.o.
author voroshil
date Sat, 24 Mar 2007 03:08:19 +0000
parents 2ec2301183cd
children ec2bfbd0d647
line wrap: on
line source



typedef struct _ASX_Parser_t ASX_Parser_t;

typedef struct {
  char* buffer;
  int line;
} ASX_LineSave_t;

struct _ASX_Parser_t {
  int line; // Curent line
  ASX_LineSave_t *ret_stack;
  int ret_stack_size;
  char* last_body;
  int deep;
};
  
ASX_Parser_t*
asx_parser_new(void);

void
asx_parser_free(ASX_Parser_t* parser);

/*
 * Return -1 on error, 0 when nothing is found, 1 on sucess
 */
int
asx_get_element(ASX_Parser_t* parser,char** _buffer,
		char** _element,char** _body,char*** _attribs);

int
asx_parse_attribs(ASX_Parser_t* parser,char* buffer,char*** _attribs);

/////// Attribs utils

char*
asx_get_attrib(const char* attrib,char** attribs);

int
asx_attrib_to_enum(const char* val,char** valid_vals);

#define asx_free_attribs(a) asx_list_free((void***)&a,free)

////// List utils

typedef void (*ASX_FreeFunc)(void* arg);

void
asx_list_free(void* list_ptr,ASX_FreeFunc free_func);