Add doc precision about demux object keeping pointers to data.

Change-Id: I3d2139f975eedcce36606e586e0cbd6fa7d207e6
This commit is contained in:
skal 2013-08-21 11:09:37 -07:00
parent 61405a143d
commit bef7e9ccd1

View File

@ -94,6 +94,10 @@ static WEBP_INLINE WebPDemuxer* WebPDemux(const WebPData* data) {
// If 'state' is non-NULL it will be set to indicate the status of the demuxer. // If 'state' is non-NULL it will be set to indicate the status of the demuxer.
// Returns NULL in case of error or if there isn't enough data to start parsing; // Returns NULL in case of error or if there isn't enough data to start parsing;
// and a WebPDemuxer object on successful parse. // and a WebPDemuxer object on successful parse.
// Note that WebPDemuxer keeps internal pointers to 'data' memory segment.
// If this data is volatile, the demuxer object should be deleted (by calling
// WebPDemuxDelete()) and WebPDemuxPartial() called again on the new data.
// This is usually an inexpensive operation.
static WEBP_INLINE WebPDemuxer* WebPDemuxPartial( static WEBP_INLINE WebPDemuxer* WebPDemuxPartial(
const WebPData* data, WebPDemuxState* state) { const WebPData* data, WebPDemuxState* state) {
return WebPDemuxInternal(data, 1, state, WEBP_DEMUX_ABI_VERSION); return WebPDemuxInternal(data, 1, state, WEBP_DEMUX_ABI_VERSION);