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

Function ilIsValidKtx

DevIL/src-IL/src/il_ktx.cpp:68–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66
67
68ILboolean ilIsValidKtx(ILconst_string FileName)
69{
70 ILHANDLE KtxFile;
71 ILboolean bKtx = IL_FALSE;
72
73 if (!iCheckExtension(FileName, IL_TEXT("ktx"))) {
74 ilSetError(IL_INVALID_EXTENSION);
75 return bKtx;
76 }
77
78 KtxFile = iopenr(FileName);
79 if (KtxFile == NULL) {
80 ilSetError(IL_COULD_NOT_OPEN_FILE);
81 return bKtx;
82 }
83
84 bKtx = ilIsValidKtxF(KtxFile);
85 icloser(KtxFile);
86
87 return bKtx;
88}
89
90
91ILboolean ilIsValidKtxF(ILHANDLE File)

Callers 1

ILAPIENTRY ilIsValidFunction · 0.85

Calls 3

iCheckExtensionFunction · 0.85
ilSetErrorFunction · 0.85
ilIsValidKtxFFunction · 0.85

Tested by

no test coverage detected