Hi Hendrik, On Tue, 15 Dec 2015 11:31:57 +0100, Hendrik Leppkes wrote: > On Tue, Dec 15, 2015 at 11:20 AM, Michael Niedermayer <michae...@gmx.at> > wrote: > > On Tue, Dec 15, 2015 at 08:58:01AM +0100, Jean Delvare wrote: > >> Also I can see 12 occurrences of the same cast for this parameter of > >> function av_image_copy() in the ffmpeg code already. And over 20 more > >> similar casts for similar parameters of other functions > >> (ff_combine_frame, swr_convert, copy_picture_field...) So I'm not > >> introducing anything new, just proposing one more of the same. > > > > yes, I have no real oppinion on this except that C is insane or I am > > and i dont really mind to apply the patch if thats what people prefer. > > Any real compiler that follows this litterally and breaks the code is > > IMHO a compiler one should avoid (quite independant of it being used > > for FFmpeg or other things) unless one wants to language lawyer around > > on such things instead of writing usefull code > > The "speed up" from removing a copy of 4 pointers is negligible as > well however, so maybe it should just be kept like it is.
Originally I proposed this patch for performance reasons and also because I think it makes the code more readable. But seeing how the same cast is already present everywhere in the ffmpeg code, I would now also invoke consistency. There's no rationale for not doing the same here that is already done everywhere else. If it caused any problem we would know by now (and I verified that this patch passes the test suite, FWIW.) -- Jean Delvare SUSE L3 Support _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel