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

Function stbi_info

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

Source from the content-addressed store, hash-verified

8391
8392#ifndef STBI_NO_STDIO
8393STBIDEF int stbi_info(char const* filename, int* x, int* y, int* comp) {
8394 FILE* f = stbi__fopen(filename, "rb");
8395 int result;
8396 if (!f)
8397 return stbi__err("can't fopen", "Unable to open file");
8398 result = stbi_info_from_file(f, x, y, comp);
8399 fclose(f);
8400 return result;
8401}
8402
8403STBIDEF int stbi_info_from_file(FILE* f, int* x, int* y, int* comp) {
8404 int r;

Callers

nothing calls this directly

Calls 3

stbi__fopenFunction · 0.85
stbi__errFunction · 0.85
stbi_info_from_fileFunction · 0.85

Tested by

no test coverage detected