This is a follow-up to PR #3024, in which I explained that I would then change the version of CMake to 3.0 in several files to match the changes that were originally made by OP in PR #3008.
The minimum CMake version have been raised to 3.0 in both assimp_cmd and assimp_view projects.
The same CMake configuration as in PR #3024 was used. All projects from PR #3024 are found in the solution with the current changes. All projects built. All tests were run.
The following changes were tested with the following projects:
- assimp DLL
- unit tests
- tools/assimp_cmd
- tools/assimp viewer
- samples/SimpleOpenGL
- samples/SimpleTexturedDirectx11
- samples/SimpleTexturedOpenGL
For each program listed above, the results were tested when (CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR) is true and false.
Also, the "lib" in SET (CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_HOME_DIRECTORY}/lib") was changed to "bin" to allow DLLs to be written to executables/launchables programs directory.
- Moved TextureTypeToString to it's own file.
- Added new file to CMakeLists.txt.
- Added 6 missing values in TextureTypeToString.
- Added 6 missing aiTextureType enum values in assimp_cmd/Info.cpp.
- Moved AssxmlExporter serialization code in a new file AssxmlFileWriter.cpp/h
- Added new files to CMakeLists.txt
- Replaced string format specifiers %i by %u to match argument type.
- Made a few changes in WriteDumb.cpp to call the new DumpSceneToAssxml function.
- Renamed AssimpExport to AssimpFileWriter.
- Moved AssimpFileWriter to it's own file.
- Added a try catch in WriteBinaryDump to fix a case with memory leak.
- Replaced calls to WriteBinaryDump with AssimpFileWriter.
- Added new AssimpFileWriter files to CMakeLists.txt.