MCPcopy Create free account
hub / github.com/Kitware/VTK / IsTIFF

Function IsTIFF

ThirdParty/libproj/vtklibproj/src/grids.cpp:295–303  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

293// ---------------------------------------------------------------------------
294
295static bool IsTIFF(size_t header_size, const unsigned char *header) {
296 // Test combinations of signature for ClassicTIFF/BigTIFF little/big endian
297 return header_size >= 4 && (((header[0] == 'I' && header[1] == 'I') ||
298 (header[0] == 'M' && header[1] == 'M')) &&
299 ((header[2] == 0x2A && header[3] == 0) ||
300 (header[3] == 0x2A && header[2] == 0) ||
301 (header[2] == 0x2B && header[3] == 0) ||
302 (header[3] == 0x2B && header[2] == 0)));
303}
304
305#ifdef TIFF_ENABLED
306

Callers 1

openMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected