merge and update all copies of stb_image.h
This commit is contained in:
@@ -1251,3 +1251,36 @@ ASSIMP_API void aiQuaternionInterpolate(
|
||||
ai_assert(nullptr != end);
|
||||
aiQuaternion::Interpolate(*dst, *start, *end, factor);
|
||||
}
|
||||
|
||||
|
||||
// stb_image is a lightweight image loader. It is shared by:
|
||||
// - M3D import
|
||||
// - PBRT export
|
||||
// Since it's a header-only library, its implementation must be instantiated in some cpp file.
|
||||
// Don't scatter this task over multiple importers/exporters. Maintain it in a central place (here!).
|
||||
|
||||
#define ASSIMP_HAS_PBRT_EXPORT (!ASSIMP_BUILD_NO_EXPORT && !ASSIMP_BUILD_NO_PBRT_EXPORTER)
|
||||
#define ASSIMP_HAS_M3D ((!ASSIMP_BUILD_NO_EXPORT && !ASSIMP_BUILD_NO_M3D_EXPORTER) || !ASSIMP_BUILD_NO_M3D_IMPORTER)
|
||||
|
||||
#if ASSIMP_HAS_PBRT_EXPORT
|
||||
# define ASSIMP_NEEDS_STB_IMAGE 1
|
||||
#elif ASSIMP_HAS_M3D
|
||||
# define ASSIMP_NEEDS_STB_IMAGE 1
|
||||
# define STBI_ONLY_PNG
|
||||
#endif
|
||||
|
||||
#if ASSIMP_NEEDS_STB_IMAGE
|
||||
|
||||
# if _MSC_VER // "unreferenced function has been removed" (SSE2 detection routine in x64 builds)
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable: 4505)
|
||||
# endif
|
||||
|
||||
# define STB_IMAGE_IMPLEMENTATION
|
||||
# include "../contrib/stb_image/stb_image.h"
|
||||
|
||||
# if _MSC_VER
|
||||
# pragma warning(pop)
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user