Lines Matching refs:result

105 	struct gfxinfo *result = NULL;  in php_handle_gif()  local
114 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_gif()
115 result->width = (unsigned int)dim[0] | (((unsigned int)dim[1])<<8); in php_handle_gif()
116 result->height = (unsigned int)dim[2] | (((unsigned int)dim[3])<<8); in php_handle_gif()
117 result->bits = dim[4]&0x80 ? ((((unsigned int)dim[4])&0x07) + 1) : 0; in php_handle_gif()
118 result->channels = 3; /* always */ in php_handle_gif()
120 return result; in php_handle_gif()
128 struct gfxinfo *result = NULL; in php_handle_psd() local
137 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_psd()
138result->height = (((unsigned int)dim[0]) << 24) + (((unsigned int)dim[1]) << 16) + (((unsigned … in php_handle_psd()
139result->width = (((unsigned int)dim[4]) << 24) + (((unsigned int)dim[5]) << 16) + (((unsigned … in php_handle_psd()
141 return result; in php_handle_psd()
149 struct gfxinfo *result = NULL; in php_handle_bmp() local
161 result = (struct gfxinfo *) ecalloc (1, sizeof(struct gfxinfo)); in php_handle_bmp()
162 result->width = (((unsigned int)dim[ 5]) << 8) + ((unsigned int) dim[ 4]); in php_handle_bmp()
163 result->height = (((unsigned int)dim[ 7]) << 8) + ((unsigned int) dim[ 6]); in php_handle_bmp()
164 result->bits = ((unsigned int)dim[11]); in php_handle_bmp()
166 result = (struct gfxinfo *) ecalloc (1, sizeof(struct gfxinfo)); in php_handle_bmp()
167result->width = (((unsigned int)dim[ 7]) << 24) + (((unsigned int)dim[ 6]) << 16) + (((unsigne… in php_handle_bmp()
168result->height = (((unsigned int)dim[11]) << 24) + (((unsigned int)dim[10]) << 16) + (((unsigne… in php_handle_bmp()
169 result->height = abs((int32_t)result->height); in php_handle_bmp()
170 result->bits = (((unsigned int)dim[15]) << 8) + ((unsigned int)dim[14]); in php_handle_bmp()
175 return result; in php_handle_bmp()
184 unsigned long int result = 0; in php_swf_get_bits() local
188 result = result + in php_swf_get_bits()
191 return result; in php_swf_get_bits()
200 struct gfxinfo *result = NULL; in php_handle_swc() local
258 result = (struct gfxinfo *) ecalloc (1, sizeof (struct gfxinfo)); in php_handle_swc()
260 result->width = (php_swf_get_bits (b, 5 + bits, bits) - in php_handle_swc()
262 result->height = (php_swf_get_bits (b, 5 + (3 * bits), bits) - in php_handle_swc()
265 result = NULL; in php_handle_swc()
269 return result; in php_handle_swc()
278 struct gfxinfo *result = NULL; in php_handle_swf() local
288 result = (struct gfxinfo *) ecalloc (1, sizeof (struct gfxinfo)); in php_handle_swf()
290 result->width = (php_swf_get_bits (a, 5 + bits, bits) - in php_handle_swf()
292 result->height = (php_swf_get_bits (a, 5 + (3 * bits), bits) - in php_handle_swf()
294 result->bits = 0; in php_handle_swf()
295 result->channels = 0; in php_handle_swf()
296 return result; in php_handle_swf()
304 struct gfxinfo *result = NULL; in php_handle_png() local
321 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_png()
322result->width = (((unsigned int)dim[0]) << 24) + (((unsigned int)dim[1]) << 16) + (((unsigned int… in php_handle_png()
323result->height = (((unsigned int)dim[4]) << 24) + (((unsigned int)dim[5]) << 16) + (((unsigned int… in php_handle_png()
324 result->bits = (unsigned int)dim[8]; in php_handle_png()
325 return result; in php_handle_png()
470 struct gfxinfo *result = NULL; in php_handle_jpeg() local
491 if (result == NULL) { in php_handle_jpeg()
493 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_jpeg()
495 result->bits = php_stream_getc(stream); in php_handle_jpeg()
496 result->height = php_read2(stream); in php_handle_jpeg()
497 result->width = php_read2(stream); in php_handle_jpeg()
498 result->channels = php_stream_getc(stream); in php_handle_jpeg()
500 return result; in php_handle_jpeg()
503 return result; in php_handle_jpeg()
507 return result; in php_handle_jpeg()
530 return result; in php_handle_jpeg()
534 return result; in php_handle_jpeg()
541 return result; /* we're about to hit image data, or are at EOF. stop processing. */ in php_handle_jpeg()
545 return result; in php_handle_jpeg()
551 return result; /* perhaps image broken -> no info but size */ in php_handle_jpeg()
599 struct gfxinfo *result = NULL; in php_handle_jpc() local
620 result = (struct gfxinfo *)ecalloc(1, sizeof(struct gfxinfo)); in php_handle_jpc()
624 result->width = php_read4(stream); /* Xsiz */ in php_handle_jpc()
625 result->height = php_read4(stream); /* Ysiz */ in php_handle_jpc()
636 efree(result); in php_handle_jpc()
641 result->channels = php_read2(stream); /* Csiz */ in php_handle_jpc()
642 if ((result->channels == 0 && php_stream_eof(stream)) || result->channels > 256) { in php_handle_jpc()
643 efree(result); in php_handle_jpc()
649 for (i = 0; i < result->channels; i++) { in php_handle_jpc()
660 result->bits = highest_bit_depth; in php_handle_jpc()
662 return result; in php_handle_jpc()
670 struct gfxinfo *result = NULL; in php_handle_jp2() local
703 result = php_handle_jpc(stream); in php_handle_jp2()
718 if (result == NULL) { in php_handle_jp2()
722 return result; in php_handle_jp2()
797 struct gfxinfo *result = NULL; in php_handle_tiff() local
863 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_tiff()
864 result->height = height; in php_handle_tiff()
865 result->width = width; in php_handle_tiff()
866 result->bits = 0; in php_handle_tiff()
867 result->channels = 0; in php_handle_tiff()
868 return result; in php_handle_tiff()
878 struct gfxinfo * result; in php_handle_iff() local
912 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_iff()
913 result->width = width; in php_handle_iff()
914 result->height = height; in php_handle_iff()
915 result->bits = bits; in php_handle_iff()
916 result->channels = 0; in php_handle_iff()
917 return result; in php_handle_iff()
937 static int php_get_wbmp(php_stream *stream, struct gfxinfo **result, int check) in php_get_wbmp() argument
989 (*result)->width = width; in php_get_wbmp()
990 (*result)->height = height; in php_get_wbmp()
1001 struct gfxinfo *result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_wbmp() local
1003 if (!php_get_wbmp(stream, &result, 0)) { in php_handle_wbmp()
1004 efree(result); in php_handle_wbmp()
1008 return result; in php_handle_wbmp()
1014 static int php_get_xbm(php_stream *stream, struct gfxinfo **result) in php_get_xbm() argument
1022 if (result) { in php_get_xbm()
1023 *result = NULL; in php_get_xbm()
1060 if (result) { in php_get_xbm()
1061 *result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_get_xbm()
1062 (*result)->width = width; in php_get_xbm()
1063 (*result)->height = height; in php_get_xbm()
1076 struct gfxinfo *result; in php_handle_xbm() local
1077 php_get_xbm(stream, &result); in php_handle_xbm()
1078 return result; in php_handle_xbm()
1086 struct gfxinfo *result = NULL; in php_handle_ico() local
1098 result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); in php_handle_ico()
1105 if ((((unsigned int)dim[7]) << 8) + ((unsigned int)dim[6]) >= result->bits) in php_handle_ico()
1107 result->width = (unsigned int)dim[0]; in php_handle_ico()
1108 result->height = (unsigned int)dim[1]; in php_handle_ico()
1109 result->bits = (((unsigned int)dim[7]) << 8) + ((unsigned int)dim[6]); in php_handle_ico()
1114 return result; in php_handle_ico()
1303 struct gfxinfo *result = NULL; in php_getimagesize_from_stream() local
1312 result = php_handle_gif(stream); in php_getimagesize_from_stream()
1316 result = php_handle_jpeg(stream, info); in php_getimagesize_from_stream()
1318 result = php_handle_jpeg(stream, NULL); in php_getimagesize_from_stream()
1322 result = php_handle_png(stream); in php_getimagesize_from_stream()
1325 result = php_handle_swf(stream); in php_getimagesize_from_stream()
1329 result = php_handle_swc(stream); in php_getimagesize_from_stream()
1335 result = php_handle_psd(stream); in php_getimagesize_from_stream()
1338 result = php_handle_bmp(stream); in php_getimagesize_from_stream()
1341 result = php_handle_tiff(stream, NULL, 0); in php_getimagesize_from_stream()
1344 result = php_handle_tiff(stream, NULL, 1); in php_getimagesize_from_stream()
1347 result = php_handle_jpc(stream); in php_getimagesize_from_stream()
1350 result = php_handle_jp2(stream); in php_getimagesize_from_stream()
1353 result = php_handle_iff(stream); in php_getimagesize_from_stream()
1356 result = php_handle_wbmp(stream); in php_getimagesize_from_stream()
1359 result = php_handle_xbm(stream); in php_getimagesize_from_stream()
1362 result = php_handle_ico(stream); in php_getimagesize_from_stream()
1369 if (result) { in php_getimagesize_from_stream()
1372 add_index_long(return_value, 0, result->width); in php_getimagesize_from_stream()
1373 add_index_long(return_value, 1, result->height); in php_getimagesize_from_stream()
1375 snprintf(temp, sizeof(temp), "width=\"%d\" height=\"%d\"", result->width, result->height); in php_getimagesize_from_stream()
1378 if (result->bits != 0) { in php_getimagesize_from_stream()
1379 add_assoc_long(return_value, "bits", result->bits); in php_getimagesize_from_stream()
1381 if (result->channels != 0) { in php_getimagesize_from_stream()
1382 add_assoc_long(return_value, "channels", result->channels); in php_getimagesize_from_stream()
1385 efree(result); in php_getimagesize_from_stream()