mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-17 20:40:07 +01:00
swscale/internal: use static_assert for enforcing offsets
Instead of sprinkling av_assert0 into random init functions. Sponsored-by: Sovereign Tech Fund Signed-off-by: Niklas Haas <git@haasn.dev>
This commit is contained in:
@@ -1228,8 +1228,6 @@ SwsContext *sws_alloc_context(void)
|
||||
{
|
||||
SwsInternal *c = av_mallocz(sizeof(SwsInternal));
|
||||
|
||||
av_assert0(offsetof(SwsInternal, redDither) + DITHER32_INT == offsetof(SwsInternal, dither32));
|
||||
|
||||
if (c) {
|
||||
c->av_class = &ff_sws_context_class;
|
||||
av_opt_set_defaults(c);
|
||||
|
||||
Reference in New Issue
Block a user