Quoting Michael Niedermayer (2020-05-21 08:59:27) > > I dont see IS_IRAP_NAL() and IS_IDR_NAL() to check every field in the headers > to be consistent with IDR / IRAP NALs, which is what the tiff code in this > thread does kind off .. > > to match hevc, i could add something like > #define HAVE_TILES(s) s->has_tiles > #define HAVE_STRIPS(s) s->strips > > but iam not sure what that would simplify > The validity checks are needed once and if thats put in a macro then maybe > that > could be called HAVE_RANDOM_TILE_BITS() and HAVE_RANDOM_STRIP_BITS() could be > maybe a possibility > then again if thats what is suggested then i would suggest to rather add 2 > local variable with these names instead of a macro which would seem more > readable > > whats your opinion ?
I see little difference between a macro and a local variable in this case, either one is fine with me. And both are significantly more readable than a giant condition that the reader has to reverse engineer into (have_tiles && have_strips) -- 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".