Luca Barbato <[email protected]> writes:

> On 12/09/2012 05:34 AM, Luca Barbato wrote:
>> Hi, I'm wondering if we could completely hide the avio checksum fields
>> from the public structure by moving it to an internal field or extend it
>> to be able to use any hash function from avutil and fully expose it to
>> our users.
>> 
>> The current situation is less than optimal.
>
> Sort of related, I'd provide some wrapper api over our crypto/hash stuff
> along those lines.
>
> typedef struct AVHash {
>     const AVClass *av_class;
>     int   context_size;
>     void *context;
>     int  (*init)  (struct AVHash);
>     void (*update)(struct AVHash, const uint8_t *src, const int len);
>     void (*close) (struct AVHash, uint8_t *dst);
> } AVHash;

That's something I've been thinking of doing for a long time.

-- 
Måns Rullgård
[email protected]
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to