FLAC__metadata_object_picture_set_data

Sets the picture data of a PICTURE block.

If \a copy is \c true, a copy of the data is stored; otherwise, the object takes ownership of the pointer. Also sets the \a data_length field of the metadata object to what is passed in as the \a length parameter. The existing data will be freed if this function is successful, otherwise the original data and data_length will remain if \a copy is \c true and malloc() fails.

\note It is safe to pass a const pointer to \a data if \a copy is \c true.

\param object A pointer to an existing PICTURE object. \param data A pointer to the data to set. \param length The length of \a data in bytes. \param copy See above. \assert \code object != NULL \endcode \code object->type == FLAC__METADATA_TYPE_PICTURE \endcode \code (data != NULL && length > 0) || (data == NULL && length == 0 && copy == false) \endcode \retval FLAC__bool \c false if \a copy is \c true and malloc() fails, else \c true.

extern (C) nothrow
FLAC__metadata_object_picture_set_data

Meta