On Fri,  5 Jan 2018 22:06:42 +0100
Vittorio Giovara <[email protected]> wrote:

> This patch introduces a new type, av_stride, which is set for any
> representation of strides or linesize, including AVFrame and av_image_*
> APIs. This is done in preparation of a future switch to ptrdiff_t, a
> better suited type to represent this type of data, in a way that it is
> atomically changed at the version bump.
> ---
> 
> This is a work in progress change that I was preparing and briefly discussed
> on IRC today, based on suggestion by wm4. I wanted to share this early to
> thread waters, as well as gather feedback on this approach. As a matter of
> fact I haven't fully tested this yet, but if the idea is welcome, I will
> extensively test it on Oracle.
> 
> The rationale of introducing this "temporary" type is to minimize impact on
> downstream, allowing a long enough transition time to API users to change
> their code. I say temporary because it is possible that in the very distant
> future it would be nice to be able to just the standard type instead of a
> custom one.
> 
> We considered other ideas, such as deprecating the current APIs and frame
> fields and introducing setters and getters but they seemed less elegant and
> more likely to induce annoying code breaks to our users.

I like this (at least more than the other alternatives). In addition to
being cleaner, this would allow us to support images with higher
resolutions, without having to fear to overflow stride calculations.

So, do we want this or not?
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to