MCPcopy Create free account
hub / github.com/DentonW/DevIL / iCheckPic

Function iCheckPic

DevIL/src-IL/src/il_pic.cpp:99–111  ·  view source on GitHub ↗

Internal function used to check if the header is a valid .pic header.

Source from the content-addressed store, hash-verified

97
98// Internal function used to check if the header is a valid .pic header.
99ILboolean iCheckPic(PIC_HEAD *Header)
100{
101 if (Header->Magic != 0x5380F634)
102 return IL_FALSE;
103 if (strncmp((const char*)Header->Id, "PICT", 4))
104 return IL_FALSE;
105 if (Header->Width == 0)
106 return IL_FALSE;
107 if (Header->Height == 0)
108 return IL_FALSE;
109
110 return IL_TRUE;
111}
112
113
114//! Reads a .pic file

Callers 2

iIsValidPicFunction · 0.85
iLoadPicInternalFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected