On Thu, Apr 09, 2015 at 06:50:24PM +0200, Vittorio Giovara wrote: > On Thu, Apr 9, 2015 at 6:42 PM, Diego Biurrun <[email protected]> wrote: > > On Thu, Apr 09, 2015 at 06:09:33PM +0200, Vittorio Giovara wrote: > >> @@ -47,12 +48,21 @@ typedef struct HQXAC { > >> > >> +typedef int (*mb_decode_func)(void *ctx, GetBitContext *gb, int x, int y); > >> + > >> typedef struct HQXContext { > >> HQXDSPContext hqxdsp; > >> > >> + AVFrame *pic; > >> + mb_decode_func decode_func; > > > > Why not pass the correct type to the decode function instead of void*? > > Because HQXContext is defined below, and I wanted to avoid a forward > declaration. > I'll add that if you think it doesn't matter.
I think a forward declaration is much less ugly than a void* indirection. Diego _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
