Quoting Andreas Rheinhardt (2022-07-01 00:29:38) > The HEVC decoder has both HEVCContext and HEVCLocalContext > structures. The latter is supposed to be the structure > containing the per-slicethread state. > > Yet that is not how it is handled in practice: Each HEVCLocalContext > has a unique HEVCContext allocated for it and each of these > coincides except in exactly one field: The corresponding > HEVCLocalContext. This makes it possible to pass the HEVCContext > everywhere where logically a HEVCLocalContext should be used. > > This commit stops doing this for lavc/hevc_mvs.c; it also constifies > everything that is possible in order to ensure that no slice thread > accidentally modifies the main HEVCContext state. > > Signed-off-by: Andreas Rheinhardt <andreas.rheinha...@outlook.com> > --- > libavcodec/hevc_mvs.c | 56 +++++++++++++++++++++---------------------- > libavcodec/hevcdec.c | 27 +++++++++++---------- > libavcodec/hevcdec.h | 6 ++--- > 3 files changed, 45 insertions(+), 44 deletions(-)
Looks very reasonable -- Anton Khirnov _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".