diff --git a/Readme.md b/Readme.md index 0a04da999..917b8e8aa 100644 --- a/Readme.md +++ b/Readme.md @@ -76,10 +76,13 @@ The source code is organized in the following way: code/AssetLib/ Implementation for import and export for the format ### Where to get help ### -For more information, visit [our website](http://assimp.org/). Or check out the `./doc`- folder, which contains the official documentation in HTML format. -(CHMs for Windows are included in some release packages and should be located right here in the root folder). +To find our documentation, visit [our website](https://assimp.org/) or check out [Wiki](https://github.com/assimp/assimp/wiki) -If the docs don't solve your problem, ask on [StackOverflow with the assimp-tag](http://stackoverflow.com/questions/tagged/assimp?sort=newest). If you think you found a bug, please open an issue on Github. +If the docs don't solve your problem, you can: +- Ask on [StackOverflow with the assimp-tag](http://stackoverflow.com/questions/tagged/assimp?sort=newest). +- Ask on [Assimp-Community on Reddit](https://www.reddit.com/r/Assimp/) +- Ask a question at [The Assimp-Discussion Board](https://github.com/assimp/assimp/discussions) +- Nothing has worked? File a question or an issue-report at [The Assimp-Issue Tracker](https://github.com/assimp/assimp/issues) Open Asset Import Library is a library to load various 3d file formats into a shared, in-memory format. It supports more than __40 file formats__ for import and a growing selection of file formats for export. diff --git a/code/AssetLib/LWO/LWOAnimation.cpp b/code/AssetLib/LWO/LWOAnimation.cpp index f729f84b1..7ebbfb810 100644 --- a/code/AssetLib/LWO/LWOAnimation.cpp +++ b/code/AssetLib/LWO/LWOAnimation.cpp @@ -162,8 +162,11 @@ void AnimResolver::UpdateAnimRangeSetup() { const double my_last = (*it).keys.back().time; const double delta = my_last - my_first; + if (delta == 0.0) { + continue; + } + const size_t old_size = (*it).keys.size(); - const float value_delta = (*it).keys.back().value - (*it).keys.front().value; // NOTE: We won't handle reset, linear and constant here. @@ -176,8 +179,7 @@ void AnimResolver::UpdateAnimRangeSetup() { case LWO::PrePostBehaviour_Oscillate: { const double start_time = delta - std::fmod(my_first - first, delta); std::vector::iterator n = std::find_if((*it).keys.begin(), (*it).keys.end(), - [start_time](double t) { return start_time > t; }), - m; + [start_time](double t) { return start_time > t; }), m; size_t ofs = 0; if (n != (*it).keys.end()) { diff --git a/include/assimp/scene.h b/include/assimp/scene.h index f6dfd82b0..9b173f939 100644 --- a/include/assimp/scene.h +++ b/include/assimp/scene.h @@ -433,7 +433,7 @@ struct aiScene for (unsigned int i = 0; i < mNumTextures; i++) { const char* shortTextureFilename = GetShortFilename(mTextures[i]->mFilename.C_Str()); if (strcmp(shortTextureFilename, shortFilename) == 0) { - return std::make_pair(mTextures[i], i); + return std::make_pair(mTextures[i], static_cast(i)); } } return std::make_pair(nullptr, -1);