MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / stbi__jpeg_get_bit

Function stbi__jpeg_get_bit

lite/example/cpp_example/mge/cv/stb_image.h:2327–2335  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2325}
2326
2327stbi_inline static int stbi__jpeg_get_bit(stbi__jpeg* j) {
2328 unsigned int k;
2329 if (j->code_bits < 1)
2330 stbi__grow_buffer_unsafe(j);
2331 k = j->code_buffer;
2332 j->code_buffer <<= 1;
2333 --j->code_bits;
2334 return k & 0x80000000;
2335}
2336
2337// given a value that's at position X in the zigzag stream,
2338// where does it appear in the 8x8 matrix coded as row-major?

Calls 1

stbi__grow_buffer_unsafeFunction · 0.85

Tested by

no test coverage detected