Lines Matching refs:wpi
222 void MuxImageInit(WebPMuxImage* const wpi) { in MuxImageInit() argument
223 assert(wpi); in MuxImageInit()
224 memset(wpi, 0, sizeof(*wpi)); in MuxImageInit()
227 WebPMuxImage* MuxImageRelease(WebPMuxImage* const wpi) { in MuxImageRelease() argument
229 if (wpi == NULL) return NULL; in MuxImageRelease()
232 ChunkListDelete(&wpi->header_); in MuxImageRelease()
233 ChunkListDelete(&wpi->alpha_); in MuxImageRelease()
234 ChunkListDelete(&wpi->img_); in MuxImageRelease()
235 ChunkListDelete(&wpi->unknown_); in MuxImageRelease()
237 next = wpi->next_; in MuxImageRelease()
238 MuxImageInit(wpi); in MuxImageRelease()
246 static WebPChunk** GetChunkListFromId(const WebPMuxImage* const wpi, in GetChunkListFromId() argument
248 assert(wpi != NULL); in GetChunkListFromId()
250 case WEBP_CHUNK_ANMF: return (WebPChunk**)&wpi->header_; in GetChunkListFromId()
251 case WEBP_CHUNK_ALPHA: return (WebPChunk**)&wpi->alpha_; in GetChunkListFromId()
252 case WEBP_CHUNK_IMAGE: return (WebPChunk**)&wpi->img_; in GetChunkListFromId()
301 WebPMuxError MuxImagePush(const WebPMuxImage* wpi, WebPMuxImage** wpi_list) { in MuxImagePush() argument
312 *new_wpi = *wpi; in MuxImagePush()
326 WebPMuxImage* MuxImageDelete(WebPMuxImage* const wpi) { in MuxImageDelete() argument
328 WebPMuxImage* const next = MuxImageRelease(wpi); in MuxImageDelete()
329 WebPSafeFree(wpi); in MuxImageDelete()
346 WebPMuxImage** wpi) { in MuxImageGetNth()
348 assert(wpi); in MuxImageGetNth()
353 *wpi = (WebPMuxImage*)*wpi_list; in MuxImageGetNth()
361 size_t MuxImageDiskSize(const WebPMuxImage* const wpi) { in MuxImageDiskSize() argument
363 if (wpi->header_ != NULL) size += ChunkDiskSize(wpi->header_); in MuxImageDiskSize()
364 if (wpi->alpha_ != NULL) size += ChunkDiskSize(wpi->alpha_); in MuxImageDiskSize()
365 if (wpi->img_ != NULL) size += ChunkDiskSize(wpi->img_); in MuxImageDiskSize()
366 if (wpi->unknown_ != NULL) size += ChunkListDiskSize(wpi->unknown_); in MuxImageDiskSize()
386 uint8_t* MuxImageEmit(const WebPMuxImage* const wpi, uint8_t* dst) { in MuxImageEmit() argument
391 assert(wpi); in MuxImageEmit()
392 if (wpi->header_ != NULL) { in MuxImageEmit()
393 dst = ChunkEmitSpecial(wpi->header_, MuxImageDiskSize(wpi), dst); in MuxImageEmit()
395 if (wpi->alpha_ != NULL) dst = ChunkEmit(wpi->alpha_, dst); in MuxImageEmit()
396 if (wpi->img_ != NULL) dst = ChunkEmit(wpi->img_, dst); in MuxImageEmit()
397 if (wpi->unknown_ != NULL) dst = ChunkListEmit(wpi->unknown_, dst); in MuxImageEmit()