Document defaults of padding constraints

This commit is contained in:
Martchus 2016-11-18 17:09:26 +01:00
parent 802e6e2dfb
commit 0e6f16e2fe
2 changed files with 11 additions and 3 deletions

View File

@ -22,7 +22,10 @@ or appending the tag. Usage of padding can be configured:
- minimum/maximum padding: The file is rewritten if the padding would fall below/exceed the specifed limits.
- preferred padding: If the file needs to be rewritten the preferred padding is used.
However, it is also possible to force rewriting the entire file.
Default value for minimum and maximum padding is zero. Hence the library will almost always have to rewrite
the entire file to apply changes. To prevent this, set at least the maximum padding to a higher value.
It is also possible to force rewriting the entire file always.
Taking advantage of padding is currently not supported when dealing with Ogg streams (it is supported when dealing with raw FLAC streams).

View File

@ -435,9 +435,11 @@ inline void MediaFileInfo::setForceRewrite(bool forceRewrite)
/*!
* \brief Returns the minimum padding to be written before the data blocks when applying changes.
*
* Padding in front of the file allows adding additional fields afterwards whithout needing
* Minimum padding in front of the file allows adding additional fields afterwards whithout needing
* to rewrite the entire file or to put tag information at the end of the file.
*
* The default value is 0.
*
* \sa maxPadding()
* \sa tagPosition()
* \sa setMinPadding()
@ -460,9 +462,12 @@ inline void MediaFileInfo::setMinPadding(size_t minPadding)
/*!
* \brief Returns the maximum padding to be written before the data blocks when applying changes.
*
* Padding in front of the file allows adding additional fields afterwards whithout needing
* Maximum padding in front of the file allows adding additional fields afterwards whithout needing
* to rewrite the entire file or to put tag information at the end of the file.
*
* The default value is 0 which will force the library to rewrite the entire file almost always when
* applying changes. Increate the value using setMaxPadding() to prevent this.
*
* \sa minPadding()
* \sa tagPosition()
* \sa setMaxPadding()