On Mon, May 22, 2017 at 04:08:53PM -0400, Vittorio Giovara wrote: > On Sat, May 20, 2017 at 7:18 AM, wm4 <nfx...@googlemail.com> wrote: > > On Fri, 19 May 2017 11:25:59 -0400 > > Vittorio Giovara <vittorio.giov...@gmail.com> wrote: > > > >> >> > Also, why is this only 1 byte per channel? Seems a little > >> >> > short-sighted. > >> >> > >> >> Probably because even in the long run there won't be more than 255 > >> >> different channels so 1 byte should be enough. > >> > > >> > Well that seems short-sighted :) > >> > >> Do you think changing it to (enum AVChannel *) is enough? > > > > Using enum in ABIs is somewhat risky, because some ABIs might make the > > underlying type as small as possible. (Clarification on whether C > > allows this and/or whether any platforms really do it would be welcome.) > > I'm ok with int* as well.
C99 6.7.2.2 Enumeration specifiers: Each enumerated type shall be compatible with char, a signed integer type, or an unsigned integer type. The choice of type is implementation-defined, but shall be capable of representing the values of all the members of the enumeration. I'd still go with the more type-safe enum type. Diego _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel