Home | History | Annotate | Download | only in gdx2d

Lines Matching defs:in

6    before you include this file in *one* C or C++ file to create the implementation.
56 With other JPEG optimizations included in this version, we see
62 is the fastest JPEG decoder in the land; rather, it brings it
70 support a context parameter, so if you need to pass a context in to
71 the allocator, you'll have to store it in a global or a thread-local
119 bugs so I can refine the built-in compile-time checking to be
125 were will find the built-in SIMD more satisfactory anyway.
129 integer precision in SIMD.) The C code has been adjusted so
135 most of the deviating values are one smaller in the G channel.)
144 removed in future versions of the library. It is only intended for
154 2.05 (2015-04-19) fix bug in progressive JPEG handling, fix warning
161 2.00b (2014-12-25) fix STBI_MALLOC in progressive JPEG
171 fix bug in interlaced PNG with user-specified channel count
219 This software is in the public domain. Where that dedication is not
247 // int *x -- outputs image width in pixels
248 // int *y -- outputs image height in pixels
249 // int *comp -- outputs # of image components in image file
250 // int req_comp -- if non-zero, # of image components requested in result
256 // pixel pointed to is top-left-most in the image. There is no padding between
262 // because e.g. there were only 3 channels in the source image.
265 // in this order in each pixel:
292 // Sometimes I let "good performance" creep up in priority over "easy to maintain",
294 // performance, in addition to the easy to use ones. Nevertheless, it's important
295 // to keep in mind that from the standpoint of you, a client of this library,
325 // (The old do-it-yourself SIMD API is no longer supported in the current
336 // difference is only +-1 in the 8-bit RGB channels, and only on a small
349 // stb_image now supports loading HDR images in general, and currently
387 // by by calling stbi_convert_iphone_png_to_rgb(0), in which case
389 // is BGR stored in RGB).
393 // says there's premultiplied data (currently only happens in iPhone images,
500 // we just return the colors as stored in the file. set this flag to force
508 // flip the image vertically, so the first pixel in the output array is the bottom left
666 // 32-bit MinGW wants ESP to be 16-byte aligned, but this is not in the
1060 // need to 'unget' all the characters in the IO buffer
1328 // generic converter from built-in img_n to req_comp
1562 // build a table that decodes both magnitude and value of small ACs in
1581 // if the result is small enough, we can fit it in fast_ac table
1633 // end; in other words, regardless of the number of bits, it
1670 sgn = (stbi__int32)j->code_buffer >> 31; // sign bit is always in MSB
1701 // given a value that's at position X in the zigzag stream,
1702 // where does it appear in the 8x8 matrix coded as row-major?
2051 // out = in << 12 (in 16-bit, out 32-bit)
2052 #define dct_widen(out, in) \
2053 __m128i out##_l = _mm_srai_epi32(_mm_unpacklo_epi16(_mm_setzero_si128(), (in)), 4); \
2054 __m128i out##_h = _mm_srai_epi32(_mm_unpackhi_epi16(_mm_setzero_si128(), (in)), 4)
2126 // rounding biases in column/row passes, see stbi__idct_block for explanation.
2432 // in each scan, we'll have scan_n components, and the order
2460 // in trivial scanline order
2486 // scan an interleaved mcu... process scan_n components in order
2517 // in trivial scanline order
2546 // scan an interleaved mcu... process scan_n components in order
2786 // use comparisons since in some cases we handle more than one case (e.g. SOF)
2873 // need to generate two samples vertically for every one in input
2883 // need to generate two samples horizontally for every one in input
2913 // need to generate 2x2 samples for every one in input
2938 // need to generate 2x2 samples for every one in input
2948 // note we can't handle the last pixel in a row in this loop
2967 // of next block of 8 pixels added in.
3007 // of next block of 8 pixels added in.
3065 // historically before the algorithm changes in 1.49
3093 // to make sure the code produces the same results in both SIMD and scalar
3128 // it's useful in practice (you wouldn't use it for textures, for example).
3188 // in this version, step=3 support would be easy to add. but is there demand?
3308 int hs,vs; // expansion factor in each axis
3322 // load a jpeg image from whichever source, but leave in YCbCr format
3452 // - all input must be provided in an upfront buffer
3460 #define STBI__ZFAST_BITS 9 // accelerate all cases in default tables
3654 if (z < 0) return stbi__err("bad huffman code","Corrupt PNG"); // error in huffman codes
3680 if (dist == 1) { // run of one byte; common in images.
3772 if (flg & 32) return stbi__err("no preset dict","Corrupt PNG"); // preset dictionary not allowed in png
4012 cur += x*out_n - img_width_bytes; // store output to the rightmost img_len bytes, so we can decode in place
4084 // intefere with filtering but will still be in the cache.
4088 stbi_uc *in = a->out + stride*j + x*out_n - img_width_bytes;
4090 // png guarante byte alignment, if width is not multiple of 8/4/2 we'll decode dummy trailing data that will be skipped in the later loop
4100 for (k=x*img_n; k >= 2; k-=2, ++in) {
4101 *cur++ = scale * ((*in >> 4) );
4102 *cur++ = scale * ((*in ) & 0x0f);
4104 if (k > 0) *cur++ = scale * ((*in >> 4) );
4106 for (k=x*img_n; k >= 4; k-=4, ++in) {
4107 *cur++ = scale * ((*in >> 6) );
4108 *cur++ = scale * ((*in >> 4) & 0x03);
4109 *cur++ = scale * ((*in >> 2) & 0x03);
4110 *cur++ = scale * ((*in ) & 0x03);
4112 if (k > 0) *cur++ = scale * ((*in >> 6) );
4113 if (k > 1) *cur++ = scale * ((*in >> 4) & 0x03);
4114 if (k > 2) *cur++ = scale * ((*in >> 2) & 0x03);
4116 for (k=x*img_n; k >= 8; k-=8, ++in) {
4117 *cur++ = scale * ((*in >> 7) );
4118 *cur++ = scale * ((*in >> 6) & 0x01);
4119 *cur++ = scale * ((*in >> 5) & 0x01);
4120 *cur++ = scale * ((*in >> 4) & 0x01);
4121 *cur++ = scale * ((*in >> 3) & 0x01);
4122 *cur++ = scale * ((*in >> 2) & 0x01);
4123 *cur++ = scale * ((*in >> 1) & 0x01);
4124 *cur++ = scale * ((*in ) & 0x01);
4126 if (k > 0) *cur++ = scale * ((*in >> 7) );
4127 if (k > 1) *cur++ = scale * ((*in >> 6) & 0x01);
4128 if (k > 2) *cur++ = scale * ((*in >> 5) & 0x01);
4129 if (k > 3) *cur++ = scale * ((*in >> 4) & 0x01);
4130 if (k > 4) *cur++ = scale * ((*in >> 3) & 0x01);
4131 if (k > 5) *cur++ = scale * ((*in >> 2) & 0x01);
4132 if (k > 6) *cur++ = scale * ((*in >> 1) & 0x01);
4208 // already got 255 as the alpha value in the output
4749 // right shift amt to put high bit in position #7
4878 // read in the TGA header stuff
4966 // if I'm in RLE mode, do I need to get a RLE stbi__pngchunk?
4990 // read in 1 byte, then perform the lookup
5004 // read in the data raw
5018 // in case we're in RLE mode, keep counting down
5105 return stbi__errpuc("wrong channel count", "Unsupported number of channels in PSD image");
5127 return stbi__errpuc("wrong color format", "PSD is not in RGB color format");
5164 // The RLE-compressed data is preceeded by a 2-byte data count for each row in the data,
5195 // Next -len+1 bytes in the dest are replicated from next source byte.
5212 // We're at the raw image data. It's each channel in order (Red, Green, Blue, Alpha, ...)
5213 // where each channel consists of an 8-bit value for each pixel in the image.
5319 // for the same channel in multiple packets.
5657 return stbi__errpuc("illegal code in raster", "Corrupt GIF");
5668 return stbi__errpuc("illegal code in raster", "Corrupt GIF");
6180 // Does not support comments in the header section
6371 2.05 (2015-04-19) fix bug in progressive JPEG handling, fix warning
6378 2.00b (2014-12-25) fix STBI_MALLOC in progressive JPEG
6388 fix bug in interlaced PNG with user-specified channel count (stb)
6390 fix broken tRNS chunk (colorkey-style transparency) in non-paletted PNG
6396 fix MSVC-only compiler problem in code changed in 1.42
6406 fix to TGA optimization when req_comp != number of components in TGA;
6407 fix to GIF loading because BMP wasn't rewinding (whoops, no GIFs in my test suite)
6420 fix bug where stbi_load_from_file no longer left file pointer in correct place
6424 use STBI_NOTUSED in stbi__resample_row_generic(), fix one more leak in tga failure case
6426 make stbi_is_hdr work in STBI_NO_HDR (as specified), minor compiler-friendly improvements
6430 a few more leak fixes, bug in PNG handling (SpartanJ)
6435 error cases in bmp and tga give messages and don't leak (Raymond Barbiero, grisha)
6436 fix inefficiency in decoding 32-bit BMP (David Woo)
6440 fix bug in GIF palette transparency (SpartanJ)
6444 fix bug in file buffering for PNG reported by SpartanJ
6452 1.23 fixed bug in iPhone support
6459 1.21 fix use of 'stbi_uc' in header (reported by jon blow)
6461 1.19 bug in interlaced PNG corruption check (found by ryg)
6470 1.12 const qualifiers in the API
6482 1.01 fix bug: possible bug in handling right-side up bmps... not sure
6485 0.99 correct handling of alpha in palette
6489 0.95 during header scan, seek to markers in case of padding
6503 0.53 fix bug in png 3->4; speedup png decoding