X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=afh.h;h=77874108a056c73707f2b39516168558bf1b4e80;hb=d61d4f3dc0d2e0a59e221add150bf971c0f03c65;hp=403b7a55e2e62ade3b8a97a1cb2ec2c1bdc06fa4;hpb=f3ebfd3dcb117f1c4a91c2c9f08d8ed710ee3907;p=paraslash.git diff --git a/afh.h b/afh.h index 403b7a55..77874108 100644 --- a/afh.h +++ b/afh.h @@ -90,10 +90,11 @@ struct audio_format_handler { * this audio format. A negative return value indicates that this audio format * handler did not recognize the given file. On success, the function is * expected to return a positive value and to fill in \arg info_str, \arg - * chunks and \arg seconds appropriately. + * chunks and \arg seconds appropriately and to return the chunk table + * via \a vss_chunk_table. */ int (*get_file_info)(FILE *audio_file, char *info_str, - long unsigned *chunks, int *seconds); + long unsigned *chunks, int *seconds, size_t **vss_chunk_table); /** * cleanup function of this audio format handler * @@ -102,24 +103,4 @@ struct audio_format_handler { * for closing the file handle. It is assumed to succeed. */ void (*close_audio_file)(void); - /** - * jump to another position in the current audio file - * - * This is called if a client issued the ff or jmp command with \a request - * being the number of the next chunk that should be sent out. Must return a - * positive value on success and a negative value on errors. - */ - int (*reposition_stream)(long unsigned request); - /** - * function responsible for reading one data chunk. - * - * \a read_chunk() must return a pointer to the next chunk of data that should - * be sent out, or \p NULL on errors or if the end of the file was encountered. - * - * If it returns non-NULL, \a len must contain the length of the returned - * buffer (which may be zero if nothing has to be sent for some reason). - * Otherwise, \a len is used to distinguish between the eof and the error case: - * It must be zero in the eof case, or negative if an error occcured. - */ - char * (*read_chunk)(long unsigned chunk_num, ssize_t *len); };