-----------------------------------------------------------------------------------
| 85 | |
| 86 | // ----------------------------------------------------------------------------------- |
| 87 | bool AssbinImporter::CanRead(const std::string &pFile, IOSystem *pIOHandler, bool /*checkSig*/) const { |
| 88 | IOStream *in = pIOHandler->Open(pFile); |
| 89 | if (nullptr == in) { |
| 90 | return false; |
| 91 | } |
| 92 | |
| 93 | char s[32]; |
| 94 | const size_t read = in->Read(s, sizeof(char), 32); |
| 95 | |
| 96 | pIOHandler->Close(in); |
| 97 | |
| 98 | if (read < 19) { |
| 99 | return false; |
| 100 | } |
| 101 | |
| 102 | return strncmp(s, "ASSIMP.binary-dump.", 19) == 0; |
| 103 | } |
| 104 | |
| 105 | // ----------------------------------------------------------------------------------- |
| 106 | template <typename T> |