On Fri, Apr 7, 2017 at 8:13 PM, James Almer <jamr...@gmail.com> wrote: > On 4/7/2017 1:48 PM, Vittorio Giovara wrote: >> On Fri, Apr 7, 2017 at 2:27 PM, Steve Lhomme <rob...@gmail.com> wrote: >>> + * @note The struct should be allocated with >>> av_mastering_display_metadata_alloc() >>> + * and its size is not a part of the public ABI. >>> + */ >>> +typedef struct AVMasteringDisplayMetadata { >>> +} AVMasteringDisplayMetadata; >>> + >>> +/** >>> + * Allocate an AVMasteringDisplayMetadata structure and set its fields to >>> + * default values. The resulting struct can be freed using av_freep(). >>> + * >>> + * @return An AVMasteringDisplayMetadata filled with default values or NULL >>> + * on failure. >>> + */ >>> +AVMasteringDisplayMetadata *av_mastering_display_metadata_alloc(void); >> >> This signature might be problematic, it should host a size_t* which >> should be filled with the size of the struct, like it's done for other >> side data (except stereo3d for historical reasons). > > That will mean different signature between projects. > > And for that matter, why were you against me trying to add a replacement > alloc function with this parameter, then?
Because I don't think it's an issue big enough to warrant an API change over existing code. On the other hand this new code in Libav so hopefully the code should be fixed before committing and there is no need to break anything. It's unfortunate that the signature will be different but either documentation or ABI is currently violated in ffmpeg, there is no need to replicate this behaviour in libav, in my opinion. -- Vittorio _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel