Lines Matching refs:gif
115 static const ColorMapObject* find_colormap(const GifFileType* gif) { in find_colormap() argument
116 const ColorMapObject* cmap = gif->Image.ColorMap; in find_colormap()
118 cmap = gif->SColorMap; in find_colormap()
152 static bool error_return(GifFileType* gif, const SkBitmap& bm, in error_return() argument
162 GifFileType* gif = DGifOpen(sk_stream, DecodeCallBackProc); in onDecode() local
163 if (NULL == gif) { in onDecode()
164 return error_return(gif, *bm, "DGifOpen"); in onDecode()
167 SkAutoTCallIProc<GifFileType, DGifCloseFile> acp(gif); in onDecode()
180 if (DGifGetRecordType(gif, &recType) == GIF_ERROR) { in onDecode()
181 return error_return(gif, *bm, "DGifGetRecordType"); in onDecode()
186 if (DGifGetImageDesc(gif) == GIF_ERROR) { in onDecode()
187 return error_return(gif, *bm, "IMAGE_DESC_RECORD_TYPE"); in onDecode()
190 if (gif->ImageCount < 1) { // sanity check in onDecode()
191 return error_return(gif, *bm, "ImageCount < 1"); in onDecode()
194 width = gif->SWidth; in onDecode()
195 height = gif->SHeight; in onDecode()
199 return error_return(gif, *bm, "chooseFromOneChoice"); in onDecode()
206 SavedImage* image = &gif->SavedImages[gif->ImageCount-1]; in onDecode()
213 return error_return(gif, *bm, "TopLeft"); in onDecode()
219 const ColorMapObject* cmap = find_colormap(gif); in onDecode()
221 return error_return(gif, *bm, "null cmap"); in onDecode()
242 return error_return(gif, *bm, "allocPixelRef"); in onDecode()
257 return error_return(gif, *bm, "non-pos inner width/height"); in onDecode()
268 fill = gif->SBackGroundColor; in onDecode()
281 if (gif->Image.Interlace) in onDecode()
287 if (DGifGetLine(gif, row, innerWidth) == GIF_ERROR) { in onDecode()
288 return error_return(gif, *bm, "interlace DGifGetLine"); in onDecode()
297 if (DGifGetLine(gif, scanline, innerWidth) == GIF_ERROR) { in onDecode()
298 return error_return(gif, *bm, "DGifGetLine"); in onDecode()
307 if (DGifGetExtension(gif, &temp_save.Function, in onDecode()
309 return error_return(gif, *bm, "DGifGetExtension"); in onDecode()
316 return error_return(gif, *bm, "AddExtensionBlock"); in onDecode()
318 if (DGifGetExtensionNext(gif, &extData) == GIF_ERROR) { in onDecode()
319 return error_return(gif, *bm, "DGifGetExtensionNext"); in onDecode()