- Added security flag guard:ehcont for MSVC.
- Updated wininit script to use Visual Studio 2019 as default generator.
- Re-enabled vcpkg tests now that rapidjson has been updated.
Updated rapidjson version to latest.
Updated CI and removed legacy Visual Studio 2017 integration tests (No longer supported by Azure)
Temporarily disabled vcpkg integration tests since we are currently incompatible with its version of rapidjson. Once vcpkg updates its rapid-json we should we enable vcpkg integration tests.
Fixes#93
* Change static cast from "int" to use the index type
By using "int", this produces "error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]"
Static cast is technically not needed at all here since all usages of this function specialize it with an unsigned int, but in order to be future proof static cast it to the type of indices.
Use curly braces in member initialisation.
"major" and "minor" are macros defined by the gcc compiler. The macros are defined in sys/sysmacros.h which is getting pulled in by #include <string>
Using curly braces stops the macro from being expanded.
* cmake: use find_package with VcPkg
* cmake: define macro for <experimental/filesystem>
* VC++ requires _SILENCE_EXPERIMENTAL_FILESYSTEM_DEPRECATION_WARNING
* azure: vcpkg for windows build
* provide job variable: `vcpkgRoot`
* azure: explicit use of vcpkgTriplet
* cmake: alias for googletest target
* place gitignore under Build/
* azure: copy gtest DLL files after build
* cmake: update external/ and ios.toolchain.cmake
* ios-cmake: https://github.com/leetal/ios-cmake/releases/tag/3.1.2
* external: update ref commit
* cmake: workaround find_package(RapidJSON) in IOS
* cmake: change variable usage to command
* add_compile_definitions/add_compile_options
* Delete .gitignore
The file is unnecessary change. Remove.
* Update azure-pipelines.yml for Azure Pipelines
* build: recover build jobs without VcPkg
* build: add MacOS jobs for VcPkg
* build: use macos-10.15
* build macos: change vcpkgRoot
* Add missing includes (#53)
* <algorithm> is needed for std::all_of()
* <tuple> is needed for std::tie()
* <string.h> is needed for memcpy() and strncmp()
* Update macos image to 10.14
* Fix clang warning
* ios deployment version 10
* removed min version
* 10.11 version
Co-authored-by: Gary Hsu <bghgary@users.noreply.github.com>
Co-authored-by: Cedric Guillemet <cedric.guillemet@gmail.com>
* Implement generalized float accessor data decoding
This change introduces GLTFResourceReader::ReadFloatData that, in
contrast with ReadBinaryData, doesn't require knowledge of the specific
data type and instead decodes the data into floating-point values in
accordance with ES3 rules that are used by glTF specification for
animation and geometry data.
This makes the code much more concise, because there's no need to
enumerate individual types and implement custom fragile conversions, and
trivially extends the code to support additions to the geometry
encodings provided by KHR_mesh_quantization extension.
* Fix a bug with unnormalized data decoding
We were previously assuming that the values are always normalized, but
this is obviously not true; we now correctly take into account
accessor.normalized and either do an integer->float cast or a full blown
transform.
* Add unit test coverage for ReadFloatData
Note that this change also fixes the test behavior in
AnimationUtilsTests - the tests were incorrectly creating unnormalized
accessors for animation data.
* Remove unused ComponentToFloat overload
This should fix macOS build
* Review feedback
Move ReadFloatData after ReadBinaryData
* Review feedback
Remove redundant inline and rename DecodeFloats.
* Reindent new file using spaces
* Rename ComponentToFloat to DecodeToFloat
* Remove ToUint8 that is no longer necessary.
* Remove two unused constants...
* Move ComponentToFloat and FloatToComponent
Instead of duplicating the definitions of decoding functions as
DecodeToFloat, move ComponentToFloat to ResourceReaderUtils.
This change also moves FloatToComponent for symmetry.
* Restore color and weight uint8->uint32 pack
The generic function has the exact same behavior but this is more direct
which might be a bit faster.
* Simplify DecodeToFloats a bit
There's no need to use algorithms here; as far as I can tell most other
decoding functions in the library just use for loops.
* Move PackColors(float) earlier in the file
* Restore all original validity checks
This change is now insufficient to load quantized glTF files - that can
be submitted as a separate PR.
Update and fix various unit tests that used glTF 1.0 manifest fragments as input. Also moved the Serialize specific tests from GLTFSerializerTests to SerializeTests, the Deserialize specific tests from GLTFSerializerTests to a new file called DeserializeTest, and deleted GLTFSerializerTests.
Use a utility Optional type for class member variables that are not required and have no default value specified. The following classes have been modified:
- BufferView: byteStride & target members
- Perspective: zfar & aspectRatio members
- Sampler: magFilter & minFilter members
- TextureTransform: texCoord member
* Add support for the KHR_texture_transform extension with unit tests (based on Khronos TextureTransformTest model)
* Add support for nested extension serialization/deserialization
* Allow individual schema documents to be disabled during deserialization
* Replace SchemaLocator with ISchemaLocator interface
* Update schema valiation to allow validation of glTF extensions. Added relevant unit tests.
* Add extra unit tests
* Remove ISchemaLocator parameter from Deserialize API
* Respond to PR comments
* Added a sample command line sample for deserializing glTF files
* Downgrade version of Windows platform.
* Simplify project file.
* Add Serialize sample.
* Update Serialize sample to support creation of GLBs
* Update comments for Serialize sample
* Move path sanitizing into main functions for Serializer & Deserialize samples. Made small changes to comments and error messages.
* Add Samples to cmake build
* Handle empty bin files with writing out glb's
* removing unused headers in test
* Now getting the output stream from the streamWriter directly to check the stream state
* removed white space and rename test file
* adding a default document to the test to make generate manifest data for the Flush(..) call
* Updating test to complete the round trip back to a document
* removing extra StreamReaderWriter from unit test
* removing white space