> >     char *ext;
> >     int (*load)(void **data, char *filename);
> >     int (*save)(void **data, char *filename);
> 
> This is a bit simplistic. While the extension is a good hint usually, I'd as
> well include more sophisticated detection techniques.
> 
> I as well do not like teh void **data prototypes, but see below.

I was thinking about a function like 
register(LIBIMG_READER, "*.jpg", funcptr *isJpg?, funcptr *read_Jpeg);
Based on extension it will run the file id function isJpeg? which can check
the magic or whatever it wants, and if that passes it will read it, else test
the other registered formats with there is*? functions...

 -Adam Scislowicz([EMAIL PROTECTED])

Reply via email to