diff --git a/README.md b/README.md index 6d215a3..6297778 100644 --- a/README.md +++ b/README.md @@ -170,6 +170,7 @@ if (!ret) { * `TINYGLTF_ANDROID_LOAD_FROM_ASSETS`: Load all files from packaged app assets instead of the regular file system. **Note:** You must pass a valid asset manager from your android app to `tinygltf::asset_manager` beforehand. * `TINYGLTF_ENABLE_DRACO`: Enable Draco compression. User must provide include path and link correspnding libraries in your project file. * `TINYGLTF_NO_INCLUDE_JSON `: Disable including `json.hpp` from within `tiny_gltf.h` because it has been already included before or you want to include it using custom path before including `tiny_gltf.h`. +* `TINYGLTF_NO_INCLUDE_RAPIDJSON `: Disable including RapidJson's header files from within `tiny_gltf.h` because it has been already included before or you want to include it using custom path before including `tiny_gltf.h`. * `TINYGLTF_NO_INCLUDE_STB_IMAGE `: Disable including `stb_image.h` from within `tiny_gltf.h` because it has been already included before or you want to include it using custom path before including `tiny_gltf.h`. * `TINYGLTF_NO_INCLUDE_STB_IMAGE_WRITE `: Disable including `stb_image_write.h` from within `tiny_gltf.h` because it has been already included before or you want to include it using custom path before including `tiny_gltf.h`. * `TINYGLTF_USE_RAPIDJSON` : Use RapidJSON as a JSON parser/serializer. RapidJSON files are not included in TinyGLTF repo. Please set an include path to RapidJSON if you enable this featrure. diff --git a/tiny_gltf.h b/tiny_gltf.h index 2fd3e90..3ce808d 100644 --- a/tiny_gltf.h +++ b/tiny_gltf.h @@ -1538,6 +1538,7 @@ class TinyGLTF { #ifndef TINYGLTF_USE_RAPIDJSON #include "json.hpp" #else +#ifndef TINYGLTF_NO_INCLUDE_RAPIDJSON #include "document.h" #include "prettywriter.h" #include "rapidjson.h" @@ -1545,6 +1546,7 @@ class TinyGLTF { #include "writer.h" #endif #endif +#endif #ifdef TINYGLTF_ENABLE_DRACO #include "draco/compression/decode.h"