Commit Graph

790 Commits

Author SHA1 Message Date
Janine Liu dff210594d Add assert in status constructor for PropertyTexturePropertyView 2023-07-05 17:27:28 -04:00
Janine Liu 047422b53d Fix nearest sampling for feature ID textures 2023-07-05 16:35:34 -04:00
Janine Liu b024fe5b8f Stricter reinforcement of unsupported properties 2023-07-03 17:26:24 -04:00
Janine Liu bb1dea3739 Consolidate CI fixes 2023-07-03 16:27:43 -04:00
Janine Liu f3ecde1681 Add callbacks and tests 2023-06-29 16:51:07 -04:00
Janine Liu 8155617808 Add tests for templated getPropertyView 2023-06-29 14:49:12 -04:00
Janine Liu 76d5d26051 Rework PropertyTexturePropertyView, begin reworking PropertyTextureView 2023-06-23 12:06:25 -04:00
Janine Liu 73ea6a1cc9 Merge branch 'upgrade-feature-metadata' into fix-property-texture-view 2023-06-20 13:50:38 -04:00
Janine Liu 1694a9ad3e Fix typo 2023-06-20 10:26:32 -04:00
Janine Liu 59549893c7 Formatting 2023-06-16 17:35:26 -04:00
Janine Liu ffc1ca8f65 Use helper function in PropertyTableView tests 2023-06-16 17:33:40 -04:00
Janine Liu c329a8d407 Replace class names in metadata implementation files 2023-06-16 16:25:39 -04:00
Janine Liu 55ed63a945 Regenerate EXT_structural_metadata classes without prefix 2023-06-16 16:08:35 -04:00
Janine Liu e0f49321c5 Prefix EXT_feature_metadata files, rename EXT_mesh_features files 2023-06-16 15:16:05 -04:00
Janine Liu b25ad79bdc Start reworking property texture view 2023-06-16 13:55:43 -04:00
Janine Liu c34b321b30 Add changelog and delete unused files 2023-06-06 12:10:02 -04:00
Janine Liu bc67ba8490 Fix other files 2023-06-06 11:37:35 -04:00
Janine Liu a50093c460 Rename files and take classes out of separate namespaces 2023-06-06 11:28:24 -04:00
Janine Liu bf8033d2ba Fix last CI error 2023-06-05 10:09:47 -04:00
Janine Liu 2744abd7fe Fix CI errors 2023-06-05 10:04:28 -04:00
Janine Liu d9f330c3ef Fix formatting and wrong file names 2023-06-02 14:43:14 -04:00
Janine Liu 7e0cd8a055 Add tests for feature ID texture view 2023-06-02 14:23:15 -04:00
Janine Liu 4644086f65 Create feature ID texture views for EXT_mesh_features 2023-06-02 14:00:54 -04:00
Janine Liu 60a528a19b Last formatting fix 2023-05-30 20:28:42 -04:00
Janine Liu db0f1734d1 Fix formatting 2023-05-30 20:26:14 -04:00
Janine Liu 44b829a081 Add PropertyTextureProperty tests, fix formatting 2023-05-30 11:11:06 -04:00
Janine Liu 619faea5b7 Add PropertyTextureView and rename PropertyTable classes 2023-05-30 10:27:21 -04:00
Janine Liu b5fb7302e3 Fold helper functions into findCompatibleTypes, fix formatting 2023-05-25 14:43:43 -04:00
Janine Liu 219da88a0a Use pointers in MetadataPropertyTableView 2023-05-25 10:22:13 -04:00
Janine Liu 7f2ea49940 Minor whitespace nitpicks 2023-05-24 12:42:07 -04:00
Janine Liu bae45489ed Add tests 2023-05-24 12:36:28 -04:00
Janine Liu d9e234ab5f Refactor error handling in MetadataPropertyTableView 2023-05-24 11:48:13 -04:00
Janine Liu 1cce7f8202 Use references instead of pointers, add missing doc links 2023-05-24 11:04:45 -04:00
Janine Liu b8b3edea51 Code cleanup 2023-05-23 11:42:34 -04:00
Janine Liu 7e08eadf07 Remove final unused variable 2023-05-23 10:39:26 -04:00
Janine Liu 5513169280 Remove unused variables 2023-05-22 17:50:38 -04:00
Janine Liu 64b8378019 Add tests for callback on array property 2023-05-22 17:46:34 -04:00
Janine Liu 3dd83ab8d0 Add callback tests 2023-05-22 17:26:11 -04:00
Janine Liu efb95c5659 Verify that callbacks work with unit tests 2023-05-22 15:29:14 -04:00
Janine Liu d7f58dab33 Rewrite how vecN / matN are handled 2023-05-22 11:58:37 -04:00
Janine Liu 352d0d20bb Try to fix compile errors 2023-05-19 16:20:38 -04:00
Janine Liu 2b8e5349fa Add tests for StructuralMetadataPropertyTableView 2023-05-19 15:41:54 -04:00
Janine Liu 5e999deef4 Add StructuralMetadataPropertyTableView 2023-05-18 11:18:33 -04:00
Janine Liu 9f7b66c7bb Fix enum names 2023-05-17 15:14:35 -04:00
Janine Liu f52e1bab01 Fix incorrect variable names 2023-05-17 14:52:38 -04:00
Janine Liu 2228f75d6c Rename enums and fix documentation 2023-05-17 14:50:59 -04:00
Janine Liu e1305361b4 Add tests for new property view 2023-05-17 14:01:40 -04:00
Janine Liu 5018b91555 Merge branch 'new-metadata-property-types' into new-metadata-property-view 2023-05-17 11:12:42 -04:00
Kevin Ring c0c8e3a619 Formatting. 2023-05-17 08:44:39 +10:00
Kevin Ring 2b46d1454f Merge remote-tracking branch 'origin/new-metadata-property-types' into specialize-traits 2023-05-17 08:16:43 +10:00
Janine Liu 25a3320be0 Add missing file 2023-05-16 18:15:05 -04:00
Kevin Ring 244e11f92c Merge remote-tracking branch 'origin/new-metadata-property-types' into specialize-traits 2023-05-17 07:44:50 +10:00
Kevin Ring dccb99e666 Formatting. 2023-05-17 07:38:44 +10:00
Kevin Ring 72fe4a960e Fix test failures on GCC9. 2023-05-17 07:37:26 +10:00
Janine Liu 671033c1e1 Add StructuralMetadataPropertyView 2023-05-16 15:53:40 -04:00
Janine Liu da5355387c Fix formatting and minor changes 2023-05-16 15:52:39 -04:00
Janine Liu 90377e8f6c Fix formatting and move pragma 2023-05-16 11:23:10 -04:00
Kevin Ring cd9c32b591 More partial specialization. 2023-05-16 22:25:09 +10:00
Kevin Ring cf7c8bdd38 Use partial specialization to reduce code duplication. 2023-05-16 22:18:37 +10:00
Janine Liu 1433243c3d Add StructuralMetadataPropertyTypeTraits 2023-05-15 18:13:47 -04:00
Janine Liu 14997fb031 Add property types for structural metadata 2023-05-15 16:58:17 -04:00
Marco Hutter 8ffbbbab46 Update class names for materials variants extension 2023-05-02 02:05:04 +02:00
Marco Hutter 18dbbfde54 Add generated classes for `KHR_materials_variants` 2023-05-01 21:45:28 +02:00
Zackery Grizzle ea5bff2026 re-format again 2023-03-06 10:12:32 -06:00
Zackery Grizzle cf86ae3260 reformat with clang, add entry to changes.md 2023-03-03 11:16:07 -06:00
ZackOfAllTrades 4205f15b61
Update CesiumGltf/include/CesiumGltf/AccessorView.h
Co-authored-by: Kevin Ring <kevin@kotachrome.com>
2023-03-03 10:39:01 -06:00
ZackOfAllTrades fd13b00b86
Update CesiumGltf/include/CesiumGltf/AccessorView.h
Co-authored-by: Kevin Ring <kevin@kotachrome.com>
2023-03-03 10:38:55 -06:00
ZackOfAllTrades 159d9553c0
Update CesiumGltf/include/CesiumGltf/AccessorView.h
Co-authored-by: Kevin Ring <kevin@kotachrome.com>
2023-03-03 10:38:47 -06:00
Zackery Grizzle 995ed04a62 expose the bufferStart and stride of the accesorview's buffer
* giving access to these properties would allow more flexibility to the developers
2023-03-02 15:58:20 -06:00
Kevin Ring c4ad8721c7 Include string header for string enums. 2022-12-23 14:44:26 +11:00
Nithin Pranesh 30a16320e7 regenerate webp extension 2022-08-31 12:34:43 -04:00
Nithin Pranesh 320ffa91d9 add webp extension 2022-08-31 12:06:11 -04:00
Sean Lilley 5ba6cb6535 Add KHR_texture_transform extension 2022-08-28 13:32:20 -04:00
Sean Lilley ac60e58fc6 Remove unused file ExtensionTextureBasisU 2022-04-15 13:50:54 -04:00
Sean Lilley 67462c0eaa Merge branch 'main' into 3dtiles-1.1 2022-03-22 08:19:34 -04:00
Kevin Ring 5e4e34d2bd Merge remote-tracking branch 'origin/main' into 3dtiles-1.1 2022-03-22 15:45:38 +11:00
Nithin Pranesh c17a928c2f Merge branch 'is-metadata-array' into node-variants 2022-03-21 16:13:41 -04:00
Nithin Pranesh c3b8838151 call it "textureCoordinateAttributeId" instead of "textureCoordinateIndex", makes it much less confusing in c4u 2022-03-17 12:07:54 -04:00
Nithin Pranesh d4e8c7e798 Add property trait that checks whether a type is a metadata array 2022-03-17 00:03:00 -04:00
Sean Lilley 00eab5bed7 Update 3D Tiles and glTF extensions 2022-03-16 09:15:02 -04:00
Nithin Pranesh b2813d97aa expose feature texture swizzle string 2022-03-15 09:45:54 -04:00
Nithin Pranesh 027fb29bc5 Merge branch 'main' into node-variants 2022-03-02 11:24:32 -05:00
Sean Lilley be3f18cf9b Support optional JsonValue properties 2022-02-27 17:58:43 -05:00
Sean Lilley 7235ce8f69 Rerun with different names 2022-02-27 17:17:43 -05:00
Sean Lilley b76468a278 Remove old files 2022-02-27 17:12:41 -05:00
Sean Lilley 3ee7e19399 Merge branch 'main' into 3dtiles-1.1 2022-02-27 11:21:29 -05:00
Kevin Ring 0dc0e37fd1 Merge remote-tracking branch 'origin/main' into ue5 2022-02-25 09:31:47 +11:00
Kevin Ring 11e7f08b4b
Merge branch 'main' into metadata-textures 2022-02-24 16:36:11 +11:00
Kevin Ring 7efd09db05 Merge remote-tracking branch 'origin/main' into ue5 2022-02-24 10:48:11 +11:00
Nithin Pranesh 8adcf6e67f removed todos, more descriptive comments about 8-byte alignment 2022-02-21 10:28:22 -05:00
IanLilleyT 21904215dd updated generator for 3d tiles 1.1 schemas 2022-02-18 18:06:14 -05:00
Nithin Pranesh 847e0009ce
Merge branch 'main' into ktx2-nithin 2022-02-18 14:33:07 -05:00
Nithin Pranesh ea8521747f safer initialization for supported formats struct 2022-02-18 14:17:11 -05:00
Nithin Pranesh 38cb5bdf0d
Update CesiumGltf/include/CesiumGltf/Ktx2TranscodeTargets.h
Co-authored-by: Kevin Ring <kevin@kotachrome.com>
2022-02-18 14:01:25 -05:00
Kevin Ring 966aba6089 Fix code generation for MAXAR_mesh_variants. 2022-02-17 19:30:51 +11:00
Nithin Pranesh c720dbbfbe add MAXAR_mesh_variants, fix generator trying to generate manually-defined classes (like glTF Property) 2022-02-16 09:40:55 -05:00
Nithin Pranesh a312bf42d6 Revert "add MAXAR_mesh_variants, fix generator trying to generate manually-defined classes (like glTF Property)"
This reverts commit 26ad9be905.
2022-02-16 09:34:12 -05:00
Nithin Pranesh 26ad9be905 add MAXAR_mesh_variants, fix generator trying to generate manually-defined classes (like glTF Property) 2022-02-16 09:32:18 -05:00
Nithin Pranesh be511d202b add option to preserve texture quality during ktx2 texture transcode 2022-02-14 16:53:45 -05:00
Nithin Pranesh 30089bcbfa fix comments, remove redundant namespace qualifiers 2022-02-14 10:42:27 -05:00
Nithin Pranesh 7a088d5165 enum -> enum class 2022-02-12 14:22:32 -05:00
Nithin Pranesh eee9351c87 use extra enum for uncompressed images rather than std::nullopt 2022-02-11 17:18:55 -05:00
Nithin Pranesh 21e83e0367 add mipmap capability to image api, pass through mipmaps from ktx2 images 2022-02-07 22:53:49 -05:00
Nithin Pranesh b3eb40e4c6 more descriptive name for struct that lists support for compressed formats 2022-02-03 21:53:54 -05:00
Nithin Pranesh f7c0c21208 added api for clients to report supported compressed formats
added logic to autoselect ideal compressed format based on the reported supported formats
2022-02-03 21:40:31 -05:00
Nithin Pranesh 1a08065023 fix khr_texture_basisu extension generation 2022-02-01 14:35:47 -05:00
Nithin Pranesh ca963694e6 regenerate gltf files 2022-02-01 12:45:28 -05:00
Nithin Pranesh e0b6344933 Merge branch 'main' into ktx2-nithin 2022-02-01 12:19:55 -05:00
Joseph Kaile 62fc7905b7 generate Cesium RTC extension using generate-tools 2022-01-31 14:18:51 -05:00
Nithin Pranesh 89282b1dc4 fix incorrect return value in feature texture sampler 2022-01-26 15:03:46 -05:00
Nithin Pranesh ea235668bb attempt to fix gcc/clang warnings 2022-01-26 14:39:32 -05:00
Nithin Pranesh 89e0c8afc8 make metadata texture sample safer, doxygen improvement 2022-01-26 14:19:04 -05:00
Nithin Pranesh f3bfc1551b doxygen comments for all API additions 2022-01-26 13:52:44 -05:00
Nithin Pranesh 81f6fa5efa remove useless constexprs 2022-01-26 11:03:47 -05:00
Nithin Pranesh c97b384bb3 move implementations to cpp files, add extra check for empty images 2022-01-26 10:58:43 -05:00
Kevin Ring a5e3f11846 Impl->CesiumImpl, TWO_PI->TwoPi. 2022-01-25 11:55:43 +11:00
Sean Lilley 5e78d1d72a Added more gltf and 3d tiles extensions 2022-01-21 14:25:35 -05:00
Nithin Pranesh 122c9bcfdf fix tests, for now we will stop enforcing 8-byte alignment for metadata buffers 2022-01-10 10:44:46 -05:00
Nithin Pranesh 9c5b69e303 Merge branch 'main' into metadata-textures 2022-01-10 09:44:15 -05:00
Nithin Pranesh e6a8be9acc expose FeatureTexturePropertyView::channelOffsets 2022-01-07 17:23:13 -05:00
Nithin Pranesh b267a27588 small FeatureTexturePropertyView and FeatureTextureView improvements 2022-01-06 14:06:05 -05:00
Nithin Pranesh 355001f441 expose whether feature texture pixel values should be normalized 2021-12-20 11:44:08 -05:00
Nithin Pranesh 1906b68bc6 fix ext_feature_metadata schema url + regenerate 2021-12-19 18:34:30 -05:00
Nithin Pranesh 6e4b4b9faa regenerate gltf classes 2021-12-19 17:49:39 -05:00
Nithin Pranesh 53b828a9ca Merge remote-tracking branch 'origin/main' into ktx2-nithin 2021-12-19 17:23:39 -05:00
Nithin Pranesh 70f90921a6 remove extraneous public label 2021-12-15 13:50:35 -05:00
Nithin Pranesh e22c9d31d6 small fixes 2021-12-15 10:30:01 -05:00
Nithin Pranesh 72f89c5d06 moved new file to right place 2021-12-15 01:22:06 -05:00
Nithin Pranesh 47d20a08c5 add views for feature textures 2021-12-15 01:15:05 -05:00
Nithin Pranesh 47cfb28495 surfaces whether integer properties are to be normalized 2021-12-14 12:07:29 -05:00
Nithin Pranesh 56b60e7add temporary workaround for non-8byte-aligned metadata buffers 2021-12-09 13:23:00 -05:00
Nithin Pranesh a8b637662c expose more values in metadata views 2021-12-08 01:15:52 -05:00
Sean Lilley 21c65ddac8 Change folder structure for src folders 2021-12-03 11:11:41 -05:00
Sean Lilley 2cdcb92e20 Namespace cleanup 2021-12-02 18:34:22 -05:00
Nithin Pranesh b5079e40d0 fix more issues 2021-12-02 16:36:38 -05:00
Nithin Pranesh ef797f3cfb fix FeatureIDTextureView 2021-12-01 16:12:22 -05:00
Nithin Pranesh dfa5d8fcc0 add FeatureIDTextureView 2021-12-01 08:55:29 -05:00
Nithin Pranesh 55c12d0861 add support for transcoding to more formats 2021-11-27 17:53:27 -05:00
Nithin Pranesh 976d2d4d05 cleaner ImageCesium api 2021-11-22 18:03:34 -05:00
Nithin Pranesh 57f9c69e9b add KHR_texture_basisu extension support 2021-11-22 04:49:44 -05:00
Nithin Pranesh 042221aac6 oof forgot to format after generate-gltfs 2021-11-22 03:52:54 -05:00
Nithin Pranesh a2efbf8e8d rerun generate-gltf 2021-11-22 03:51:54 -05:00
Nithin Pranesh bc019173eb format 2021-11-22 03:47:19 -05:00
Sean Lilley a9110dbb74 Initial KTX2
(cherry picked from Sean's hackathon project)
2021-11-22 03:45:23 -05:00
Kevin Ring 4dac37ceb0
Merge pull request #377 from CesiumGS/extension-class-rename
Rename generated extension classes (targeting `main`)
2021-11-01 11:02:01 +11:00
Sean Lilley 9acc5ac71a Rename Primitive back to MeshPrimitive 2021-10-30 14:56:43 -04:00
Sean Lilley 6fd48d8735 Use different naming convention for extension classes 2021-10-30 14:55:40 -04:00
Nithin Pranesh 95051aa2b5 fixed handling of reserved c++ keywords in gltf reader generator 2021-10-29 17:37:57 -04:00
Sean Lilley 711114a344 Fix formatting 2021-10-18 19:04:57 -04:00
Sean Lilley 066b3df5a5 Use strict types 2021-10-18 18:47:02 -04:00
Sean Lilley f9b48fbe0e Renegerate glTF classes 2021-10-18 18:46:58 -04:00
Sean Lilley 8453d760e7 Rename generate-gltf-classes to generate-classes 2021-10-12 12:51:55 -04:00
Sean Lilley 78224b11e5 Merge branch 'main' into fix-includes 2021-10-12 11:59:32 -04:00
Sean Lilley 1a31661fa1
Merge pull request #362 from CesiumGS/add-cesium3dtiles
Add Cesium3DTiles project
2021-10-12 11:57:09 -04:00
Kevin Ring 439e37afda Merge remote-tracking branch 'origin/add-cesium3dtiles' into fix-includes 2021-10-12 21:45:12 +11:00
Kevin Ring 3443bbf130 Remove using in header, remove redundant code. 2021-10-12 17:47:35 +11:00
Sean Lilley 715eebc945 Fix class description when schema is missing description 2021-10-11 19:02:36 -04:00
Sean Lilley 52283f3359 Fix includes 2021-10-11 17:28:44 -04:00
Sean Lilley 7dad7003bb One ExtensibleObject 2021-10-11 16:47:49 -04:00
Sean Lilley ef9d5c8e43 Merge branch 'main' into gltf-no-defaults-for-optional 2021-10-11 12:33:08 -04:00
Marco Hutter 293095c9c2 Do not initialize optional enum-typed properties 2021-10-11 17:16:30 +02:00
Sean Lilley 47a4733090 Update generate-gltf-classes to support 3D Tiles 2021-10-10 17:39:22 -04:00
Kevin Ring ee5c9f0857
Merge pull request #351 from CesiumGS/gltf-schema-updates
Update generated files with newer glTF schema
2021-10-06 12:41:10 +11:00
Sean Lilley 525f8e15be Support const property in anyOf elements 2021-10-03 14:19:14 -04:00
Sean Lilley 4f2bad8ab6 Fix accidental copy-paste 2021-10-03 12:06:13 -04:00
Kevin Ring c1b9096abc Merge remote-tracking branch 'origin/main' into gltf-generator-enum-fixes 2021-10-02 01:10:06 +10:00
Marco Hutter 9855400417 Use proper relative paths in all public headers 2021-09-28 17:23:07 +02:00
Marco Hutter 27fdd26e27 Merge remote-tracking branch 'origin/main' into include-style-fixes
# Conflicts:
#	Cesium3DTilesSelection/include/Cesium3DTilesSelection/GltfContent.h
#	Cesium3DTilesSelection/src/Batched3DModelContent.cpp
#	Cesium3DTilesSelection/src/CompositeContent.cpp
#	Cesium3DTilesSelection/src/ExternalTilesetContent.cpp
#	Cesium3DTilesSelection/src/GltfContent.cpp
#	Cesium3DTilesSelection/src/QuantizedMeshContent.cpp
#	Cesium3DTilesSelection/src/Tile.cpp
#	Cesium3DTilesSelection/src/TileContentFactory.cpp
#	Cesium3DTilesSelection/src/calcQuadtreeMaxGeometricError.h
2021-09-28 14:38:33 +02:00
Sean Lilley cf5f3b24c1 Merge branch 'gltf-generator-enum-fixes' into gltf-schema-updates 2021-09-26 13:32:30 -04:00
Sean Lilley ae7d9e70a8 Merge branch 'main' into gltf-generator-enum-fixes 2021-09-26 13:24:10 -04:00
Marco Hutter 175b7eec9a Also format the auto-generated code
This will sort itself out at some point...
2021-09-26 17:57:48 +02:00
Marco Hutter 0e827f7afd Updated includes based on clang-format with Regroup
This MAINLY inserted some blank lines between
the blocks.
2021-09-26 17:46:27 +02:00
Sean Lilley 8dfa62a73e Changes to generated files 2021-09-26 11:39:10 -04:00
Marco Hutter 5519532b1e Initialize members to proper (non-default) values. 2021-09-26 16:52:54 +02:00
Marco Hutter 486eb57a93 Update for glTF enums in other classes - WIP
This updates the non-auto-generated classes based on
the changes of the auto-generated ones.
2021-09-26 15:06:10 +02:00
Marco Hutter f63c0e5265 Update of auto-generated classes - WIP
This does not compile. It is only the update of the
auto-generated classes, without the corresponding
updates in the non-auto-generated classes.
2021-09-26 14:44:29 +02:00
Marco Hutter 6a5e0d3d48 Added missing const for reference parameters
C26460: The reference argument ... for function ... can be marked as const
2021-09-15 17:43:42 +02:00
Marco Hutter 106c3065ad Formatting after adding noexcept specifiers 2021-09-15 17:03:56 +02:00
Marco Hutter 3e75d1fc6b Added further missing noexcept specifiers
C26440: Function ... can be declared noexcept
2021-09-15 17:03:15 +02:00
Marco Hutter 46c9c7ec7d Formatting after adding const 2021-09-15 15:38:06 +02:00
Marco Hutter de8145ab9e Added missing const keyword
C26496: The variable ... is assigned only once, mark it as const
2021-09-15 15:37:29 +02:00
Marco Hutter a84b09c238 Added further noexcept specifiers 2021-09-15 02:35:40 +02:00
Nithin Pranesh e06cc3afbf replace getIndex std::function with templates 2021-08-27 13:59:13 -04:00
Nithin Pranesh f9d769371e fix unsafe normalization 2021-08-27 11:43:19 -04:00
Marco Hutter 8ddb163f6d Perform component-wise vector comparison 2021-08-23 21:04:42 +02:00
Nithin Pranesh 08e56e68b6 more gcc/clang fixes 2021-08-23 13:33:36 -04:00
Nithin Pranesh 34e4a14120 replace local std::function parameters with template 2021-08-23 13:12:37 -04:00
Nithin Pranesh 6d3f8ee262 attempt to fix gcc/clang errors 2021-08-23 13:12:21 -04:00
Nithin Pranesh 24e9acb1ed add tests for triangle strips and fans 2021-08-23 12:22:06 -04:00
Nithin Pranesh e7932e0ce4 add tests for smooth normals and forEachPrimitive 2021-08-21 12:15:29 -04:00
Nithin Pranesh e5a59f85ee parse alternative node transform format 2021-08-18 12:48:30 -04:00
Nithin Pranesh 913190c273 move addTriangleNormalToVertexNormals into standalone function, instead of lambda 2021-08-18 12:00:46 -04:00
Nithin Pranesh 8cc6a1d064 only need unsigned index types 2021-08-18 11:50:42 -04:00
Nithin Pranesh 02430a1643 remove flat normal generation from cesium-native 2021-08-17 16:57:25 -04:00
Nithin Pranesh d769b17fda add generate missing flat normals options 2021-08-16 12:26:50 -04:00
Nithin Pranesh 32d1352fb5 reuse existing position buffer when flattening indices 2021-08-16 10:46:52 -04:00
Nithin Pranesh b136045efc fix gcc/clang warnings 2021-08-16 09:17:51 -04:00
Nithin Pranesh c17b8bc9a4 WIP generate missing flat normals in cesium-native 2021-08-15 21:26:37 -04:00
Nithin Pranesh 19f55611dc apply review suggestion 2021-08-15 13:27:22 -04:00
Nithin Pranesh 6a4477136d WIP move code to CesiumGltf::Model 2021-08-15 12:57:35 -04:00
Kevin Ring 9b7539d013 PropertyType doesn't need to be a bitmask. 2021-07-28 15:19:52 +10:00
Kevin Ring 3c6185f278 Formatting. 2021-07-28 12:34:25 +10:00
Kevin Ring 8a18a473f7 Default constructors for views, IsMetadataInteger/Floating. 2021-07-27 17:25:56 +10:00
Kevin Ring 449068c3d6
Merge pull request #281 from CesiumGS/feature-metadata-extension
Upgrade batch table to EXT_feature_metadata extension
2021-07-24 21:32:14 +10:00
Kevin Ring 52c52984b5 ReinterpretCastSpan -> reinterpretCastSpan. 2021-07-24 20:50:15 +10:00
Bao Tran 303bc24f4f add reintepret_cast for span 2021-07-23 13:23:24 -04:00
Bao Tran c7906e2a94 use span byte for numeric MetadataArrayView 2021-07-23 11:36:48 -04:00
Bao Tran ca0b853b73 add comment about the status of property view 2021-07-20 12:36:02 -04:00
Bao Tran 8ccd633dfb add status for property view 2021-07-20 12:15:13 -04:00
Bao Tran 31d85a358d add status for property view 2021-07-19 12:17:54 -04:00
Bao Tran 3d9e0c13bd convert type to PropertyType instead of uint32 2021-07-17 23:55:04 -04:00
Bao Tran 2e7d9b8c97 fix compiler warning 2021-07-15 20:11:16 -04:00
Bao Tran 5f4add636a fix more compiler warning 2021-07-15 19:52:20 -04:00
Bao Tran a6d8f69e57 fix compiler warning 2021-07-15 19:49:29 -04:00
Bao Tran eca0952eb2 add assertion when converting binary metadata 2021-07-15 19:25:42 -04:00
Bao Tran e420e729ec fix compiler warning 2021-07-15 19:10:59 -04:00
Bao Tran 1185d2e78f use int64 for meta array 2021-07-15 17:17:30 -04:00
Bao Tran c19b847261 fix test 2021-07-15 17:00:31 -04:00
Bao Tran dab9312560 use int64_t for property view 2021-07-13 13:47:01 -04:00
Bao Tran e709e8fc34 add float and double type to comment for feature table view and property view 2021-07-13 11:38:29 -04:00
Bao Tran ced959eccb add p prefix for pointer 2021-07-13 11:30:08 -04:00
Bao Tran fb24d8d6ca add comment to FeatureTableView 2021-07-08 18:29:38 -04:00
Kevin Ring 4e45bab460 Use angle brackets to #include catch2. 2021-07-04 22:57:11 +10:00
Bao Tran e1eb2d1f84 Merge branch 'main' into feature-metadata-extension 2021-07-02 10:50:43 -04:00
Bao Tran e8521c280a retrieve property by using callback 2021-06-28 18:52:02 -04:00
Bao Tran 380697c6c9 add document for PropertyTypeTrait 2021-06-20 19:31:15 -04:00
Bao Tran 4ecf9af04d add documentation for FeatureTableView 2021-06-20 19:03:35 -04:00
Bao Tran 78719b60df add comment for PropertyView 2021-06-20 17:45:23 -04:00
Bao Tran 3091533ef6 change PropertyView to MetadataPropertyView 2021-06-20 15:58:08 -04:00
Bao Tran 3846381cc9 change names of property type trait 2021-06-20 15:56:06 -04:00
Bao Tran c64fea091e test property trait and format 2021-06-20 15:51:53 -04:00
Bao Tran 3243f9c4ed test property type 2021-06-20 15:14:34 -04:00
Bao Tran c0faaf18dc change file name for batch table to EXT_feature_metadata 2021-06-20 14:51:15 -04:00
Bao Tran 951cb7a23e pass rapidjson::Document for batch table json to metadata upgrader 2021-06-20 14:47:36 -04:00
Bao Tran 6035cc8387 clean up unused headers 2021-06-20 12:11:18 -04:00
Bao Tran 0e1d188636 remove bool getter in feature table view 2021-06-20 11:54:02 -04:00
Bao Tran e1909b3bf7 remove getter for bool array in feature table view 2021-06-20 11:44:15 -04:00
Bao Tran 661db543d2 replace operator[] with get() for PropertyView 2021-06-20 01:40:27 -04:00
Bao Tran 76f2d10ccb test to validate dynamic array of string 2021-06-18 18:44:41 -04:00
Bao Tran 96c49c4529 test fixed array of string 2021-06-18 14:48:29 -04:00
Bao Tran 9a68718dc6 test for dynamic bool array 2021-06-18 11:41:46 -04:00
Bao Tran b6c8047c18 add test to validate fixed bool array 2021-06-17 17:00:49 -04:00
Bao Tran 6300cae267 test to validate dynamic numeric array 2021-06-17 15:26:31 -04:00
Bao Tran 47b891fac8 fix compiler warning 2021-06-17 13:28:02 -04:00
Bao Tran 7ac819dcf5 add test to validate fixed numeric array 2021-06-17 13:07:28 -04:00
Bao Tran 21f44e7a29 test to make sure offset values are sorted 2021-06-16 16:43:35 -04:00
Bao Tran d7c42c559d add test for string validation 2021-06-16 16:11:20 -04:00
Bao Tran 0506eed5c3 add test validation for bool property 2021-06-15 17:11:28 -04:00
Bao Tran 1c2a758274 add more tests to validate metadata bufferview 2021-06-15 15:15:40 -04:00
Bao Tran 3288dc5bca fix compiler warning 2021-06-15 14:51:30 -04:00
Bao Tran 62b89c365d WIP test feature table view to read property correctly 2021-06-15 14:05:26 -04:00
Bao Tran 3363cee7e8 change MetadataPropertyView to PropertyView 2021-06-14 18:35:36 -04:00
Bao Tran bc8dd36951 impl FeatureTableView 2021-06-14 18:30:01 -04:00
Bao Tran 774730381e fix property view when accessing fixed array of boolean 2021-06-08 18:53:11 -04:00
Bao Tran 4ee41a8bf5 fix property view for array of boolean 2021-06-08 18:17:11 -04:00
Bao Tran 15fcfbf7a2 fix compiler error 2021-06-08 11:41:49 -04:00
Bao Tran b1bcfd46c8 fix dynamic array of string 2021-06-07 02:20:40 -04:00
Bao Tran ab56949efa fix string offset array 2021-06-07 00:20:29 -04:00
Bao Tran 5ef1e6b2db upgrade json array of string 2021-06-06 23:11:46 -04:00
Bao Tran b1546b0d7b change order of property type enum 2021-06-03 09:21:13 -04:00
Bao Tran a4a4068e78 add test for upgrading batch table 2021-06-01 19:37:46 -04:00
Bao Tran 8d6d46ef30 test dynamic array of bool 2021-06-01 01:39:00 -04:00
Bao Tran f2e6dfed59 test fixed array of bool 2021-06-01 01:09:36 -04:00
Bao Tran a750fc2f9f impl dynamic array of string test 2021-05-31 20:25:32 -04:00
Bao Tran b9c5c77ed6 WIP template property view 2021-05-31 00:12:31 -04:00
Bao Tran 3dff283062 custom meta array view for property 2021-05-29 21:42:03 -04:00
Bao Tran 3cc40b6ed1 add boolean property view 2021-05-27 18:12:31 -04:00
Bao Tran b457b7db3c format 2021-05-27 15:41:11 -04:00
Bao Tran b7a84cfb61 fix string test 2021-05-27 14:23:55 -04:00
Bao Tran 2b79291e43 fix dynamic array tests 2021-05-27 14:15:57 -04:00
Bao Tran df7427ad2d add tests back again 2021-05-27 13:39:02 -04:00
Bao Tran 077680acae fix out of bound tests 2021-05-27 13:25:10 -04:00
Bao Tran 524306a68c isolate more failed tests 2021-05-27 13:00:47 -04:00
Bao Tran f108442a7f simplify getter for scalar 2021-05-27 12:48:51 -04:00
Bao Tran 6bdaa7d563 isolate failed tests 2021-05-27 12:12:36 -04:00
Bao Tran 9ca931c455 uncomment some failed tests 2021-05-27 11:52:37 -04:00
Bao Tran 5896978de3 isolate failed test 2021-05-27 11:36:17 -04:00
Bao Tran ca668bba47 test for string 2021-05-26 18:25:25 -04:00
Bao Tran f00bb6436e add double dynamic array test 2021-05-26 16:20:16 -04:00
Bao Tran 24b9119169 test dynamic array 2021-05-26 16:17:49 -04:00
Bao Tran e623ca7f54 format 2021-05-26 14:54:50 -04:00
Bao Tran 9634eddeb9 add test for fixed array of other numeric type 2021-05-26 14:53:58 -04:00
Bao Tran 84a01ecd21 format 2021-05-26 14:05:06 -04:00
Bao Tran 3dec7b9c8c fix fixed array doesn't have correct stride 2021-05-26 14:01:48 -04:00
Bao Tran c26a8c065b fix array property getter 2021-05-26 13:18:06 -04:00
Bao Tran e1829afb3a impl fixed and dynamic array 2021-05-26 11:23:24 -04:00
Bao Tran fd2ef64614 default offset buffer type to be uint32_t 2021-05-26 01:30:23 -04:00
Bao Tran 47a120d344 get array and string offset buffer 2021-05-26 01:09:28 -04:00
Bao Tran 474cf356ed format 2021-05-25 23:54:56 -04:00
Bao Tran 5af1880c49 test wrong property format 2021-05-25 23:53:13 -04:00
Bao Tran 40b0bca1f5 test with buffer view stride 2021-05-25 23:21:54 -04:00
Bao Tran b82d1399de check buffer stride 2021-05-25 21:55:15 -04:00
Bao Tran 34a022780b clean up interface 2021-05-25 21:47:46 -04:00
Bao Tran 058da9bd3c simplify PropertyAccessorView 2021-05-25 20:37:20 -04:00
Bao Tran 1c8b6216ab WIP initial support for scalar property type 2021-05-25 18:50:55 -04:00
Bao Tran 5a2b91e853 WIP PropertyView 2021-05-25 16:39:20 -04:00
Kevin Ring 7ec6bdfb80 Formatting. 2021-05-21 09:30:13 +10:00
Kevin Ring 04149ee0c4 Improve test, and hopefully fix Linux compile problems. 2021-05-21 09:28:46 +10:00
Kevin Ring b429342b81 Fix return type. 2021-05-21 08:42:57 +10:00
Kevin Ring b275392038 Formatting. 2021-05-20 21:50:19 +10:00
Kevin Ring 7315cb6e4b Allow use of createAccessorView with a simple lambda. 2021-05-20 21:37:31 +10:00
Kevin Ring 30f22898b1 Feature metadata working well for simple case. 2021-05-17 12:30:09 +10:00
Kevin Ring 8f85fd8bbe WIP conversion of b3dm batch table to EXT_feature_metadata. 2021-05-14 22:28:31 +10:00
Kevin Ring ed42e46d5f Add support for EXT_feature_metadata on Primitives. 2021-05-07 16:18:13 +10:00
Kevin Ring b29b8c64ad EXT_feature_metadata progress. 2021-05-07 15:34:16 +10:00
Kevin Ring 527e6051c1 Fix more code gen problems. 2021-05-06 17:30:39 +10:00
Kevin Ring 8762721d03 Regenerated glTF classes and re-run the formatter.
The only changes are to incorrectly-wrapped comments, now that comments
no longer get incorrectly wrapped.
2021-05-05 16:38:35 +10:00
Marco Hutter 51e43bbd49 Comment fixes for clang formatting 2021-04-29 17:06:34 +02:00
Kevin Ring acd13e2992
Merge pull request #219 from CesiumGS/gltf-writer-tech-debt
Address technical debt in CesiumGltfWriter
2021-04-22 10:27:21 +10:00
Samuel Vargas 00870929ee
Remove extraneous CESIUM_NATIVE_GSL_INCLUDE_DIR from CMakeLists.txt 2021-04-21 16:03:36 -04:00
Kevin Ring 10b0f92a64 Use std::as_const instead of const_cast. 2021-04-20 21:00:36 +10:00
Kevin Ring 3df9f5ef32 Fix test failure. 2021-04-19 10:35:21 +10:00
Kevin Ring 999c382cc1 Merge remote-tracking branch 'origin/main' into gltf-extensions 2021-04-16 16:07:23 +10:00
Kevin Ring e5c5408804 More constier. 2021-04-16 13:18:25 +10:00
Kevin Ring 8aab8bbec2 Don't construct so many GltfReaders.
Also switch to constexpr char* for extension and type names to avoid
static initializer ordering problems.
2021-04-16 12:52:29 +10:00
Samuel Vargas 8070d85023
Merge remote-tracking branch 'origin/main' into gltf-writer 2021-04-15 13:49:04 -04:00
Kevin Ring 02e3be9b03 Merge remote-tracking branch 'origin/main' into gltf-extensions 2021-04-15 21:54:03 +10:00
Kevin Ring 940d8fc8f2 Merge remote-tracking branch 'origin/main' into gltf-extensions 2021-04-15 09:58:01 +10:00
Kevin Ring 94ea03847c Move CesiumJsonReader stuff to the right namespace. 2021-04-14 14:22:22 +10:00
Kevin Ring 88795c0045 Move JsonValue to CesiumUtility. 2021-04-13 23:24:53 +10:00
Jordi Torres 6333b1cb0a First pass of clang tidy
Mainly caching else after return, not using empty() instead of size() == 0, missing const references to avoid copies and removing redundant initializations
2021-04-12 13:22:03 +02:00
Kevin Ring b2d278972a Use ExtensionName, cause it might be different from the type name. 2021-04-08 21:18:02 +10:00
Samuel Vargas dbd975f6d7
Run clang-format on `JsonValue.h` 2021-04-06 14:28:45 -04:00
Samuel Vargas b2ba45f5c1
Add comment explaining std::enable_if 2021-04-06 13:41:56 -04:00
Samuel Vargas b03dac82af
Add trailing newline to misc files [ skip ci ] 2021-04-06 13:07:48 -04:00
Kevin Ring 987ca69614 Support for external glTF extensions. 2021-04-06 21:49:12 +10:00
Kevin Ring 0884fdba27 Don't always report zero-length images as errors. 2021-04-02 12:10:30 +11:00
Samuel Vargas 94c77dd89e
Merge tag 'post-clang-format' into gltf-writer-clang-format
The commit that ran clang-format on the entire codebase and made no other changes.
2021-03-09 16:36:39 -05:00
Shehzan Mohammed 8a2957d32f Run clang format 2021-03-08 20:39:46 -05:00
Samuel Vargas 506f76c34b
Use std::byte for image.cesium.pixelData 2021-03-05 10:04:10 -05:00
Samuel Vargas e5f90d3b16
Add GSL_INCLUDE_DIR to target_include_directories
This is necessary to link against CesiumGltf as we use
gsl/narrow in JsonValue.h
2021-03-05 07:41:24 -05:00
Samuel Vargas 7c19d7d828
Add unittests for JsonValue 2021-03-05 07:41:17 -05:00
Samuel Vargas f1076ea0ee
Rename getNumberOrDefault to getSafeNumberOrDefault 2021-03-05 07:41:17 -05:00
Samuel Vargas c4f6025420
Add integer support to JsonValue
This also fixes a narrowing conversion bug. Previously if
a type that was larger than 2^53 was stored in a JsonValue
it would be silently casted into a double, causing an unexpected
precision loss. This changes JsonValue to use the largest signed,
unsigned, or floating point value available to support both types
of Numbers.

Also updates GSL version because they added a narrowing cast
function and we use that for safe type casting.
2021-03-05 07:41:15 -05:00
Kevin Ring 589a0098fc
Merge pull request #145 from CesiumGS/install
Add ability to CMake install cesium-native
2021-03-05 16:03:29 +11:00
Marco Hutter 10efc9e894 Fixed the expected CLang error 2021-03-04 17:36:27 +01:00
Marco Hutter f1078aeb4c Use bytes for raw data 2021-03-04 17:22:38 +01:00
Shehzan Mohammed 3faff010d7 Installing thirdparty deps working on linux 2021-03-03 20:47:31 -05:00
Kevin Ring 34bbd2aa31 WIP cmake install. 2021-03-04 09:48:09 +11:00
Samuel Vargas 5d03477551
Rearchitecture cesium-native's CMake structure
This is necessary to support using cesium-native as submodule in
in asset-pipeline

- `draco` and `sqlite3` are guarded with if target blocks to allow
  asset-pipeline to provide their own version of the targets.
- Tests are now a dedicated target that clients don't have to build
- Test sources / headers are now a target property instead of using the $<BUILD_INTERFACE... hack
- Added common include variables in extern/CMakeLists.txt
- Defined `RAPIDJSON_HAS_CXX11_RVALUE_REFS` for move support for RapidJson
- Private include directories are automatically extracted via CMake magic
  for use in catch tests
- Globbing is now wrapped in a dedicated function that allows one to use
  CONFIGURE_DEPENDS depending on their preferences (defaults to OFF)
  to retain the old behavior.
2021-03-02 14:28:04 -05:00
Kevin Ring a21fd37719 And yet more clang warning fixes. 2021-02-26 17:25:11 +11:00
Kevin Ring 1e2ceaf2bf Another clang error. 2021-02-26 17:17:44 +11:00
Kevin Ring b1f5cf949a Better fix for clang warning. 2021-02-26 17:11:53 +11:00
Kevin Ring 126cea4b76 Fix clang warning. 2021-02-26 17:10:31 +11:00
Kevin Ring a69628b785 Merge remote-tracking branch 'origin/master' into ion-ui 2021-02-24 12:59:44 +11:00
Marco Hutter 613245fe80 Tabs to spaces...
... not consistent globally, but locally, at least.
2021-02-21 17:32:47 +01:00
Marco Hutter 8babc264aa Comments for local glTF classes 2021-02-21 17:27:14 +01:00
Marco Hutter ce41c77d6a Added missing documentation for glTF classes
Even though many of the comments are trivial, the
documentation now is no longer empty...
2021-02-16 01:06:59 +01:00
Kevin Ring d10bd2a16d Move JsonHelps to CesiumUtility, at ion "me" service. 2021-02-09 22:50:18 +11:00
Kevin Ring 13ce898f6f Fix copy/paste fail. 2021-02-02 11:47:13 +11:00
Kevin Ring 8bc5d73959 Fix gcc/clang build errors. 2021-01-29 13:34:48 +11:00
Kevin Ring 358e2a5b2d Remove AccessorView, replace with an AccessorView helper. 2021-01-25 23:56:38 +11:00
Kevin Ring 05d626285b Add AccessorVisitor.
I'm not quite convinced this is the right approach yet.
2021-01-25 22:43:34 +11:00
Kevin Ring dccfcf0a23 More picky clang signedness warnings. 2021-01-25 14:53:28 +11:00
Kevin Ring f11089f5c9 Fix warnings. 2021-01-25 14:43:46 +11:00
Kevin Ring 28b64347b7 Incorporate changes from review and from the cmpt branch. 2021-01-25 12:17:13 +11:00
Kevin Ring 8d0b1f9210 Move and rename test. 2021-01-20 19:55:34 +11:00
Kevin Ring 8fdc7518b9 Fix Clang problems. 2021-01-20 17:25:00 +11:00
Kevin Ring 5b1550da39 Remove another "default". 2021-01-20 15:28:01 +11:00
Kevin Ring 168798fe4a Don't use a C++ reserved word as a parameter name. 2021-01-20 15:19:42 +11:00
Kevin Ring 614b59db21 Remove GltfAccessor and GltfWriter. 2021-01-20 00:15:57 +11:00
Kevin Ring 3bd988f0e4 Remove Helpers entirely. 2021-01-18 23:22:12 +11:00
Kevin Ring c36a2710c3 Allow for augmentation of generated classes via inheritance. 2021-01-18 22:51:20 +11:00
Kevin Ring 11ea3103b0 Optional properties, thorough initialization. 2021-01-17 00:18:00 +11:00
Kevin Ring 6d9e83447b Merge remote-tracking branch 'origin/master' into gltf 2021-01-14 23:46:26 +11:00
Kevin Ring edb8fe209b Add extras, reactivate support for RTC_CENTER. 2021-01-14 17:44:19 +11:00
Kevin Ring cb297c4db6 More defaults. 2021-01-13 17:47:08 +11:00
Kevin Ring 082087551e Default glTF IDs to -1. 2021-01-13 17:16:06 +11:00
Kevin Ring c999c7628b Load embedded images. 2021-01-12 21:57:42 +11:00
Kevin Ring 6a6d2d94de Draco loading. 2021-01-12 21:40:35 +11:00
Kevin Ring 2b2c4a8b16 Add support for extensions, especially Draco. 2021-01-11 18:05:02 +11:00
Kevin Ring 08d173d573 Use CesiumGltf instead of tinygltf. 2021-01-08 14:09:08 +11:00
Kevin Ring 3f6e301acf GLB support. 2021-01-07 22:17:55 +11:00
Kevin Ring bd0290bec8 Generated doc improvements. 2021-01-07 13:54:25 +11:00
Kevin Ring c153c4c0bb Fix test failure. 2021-01-06 22:44:42 +11:00
Kevin Ring 32dca3f5d8 Improved error reporting. 2021-01-06 20:56:53 +11:00
Kevin Ring 068df1c3ef Improve error handling. 2021-01-06 13:00:54 +11:00
Kevin Ring 87a030abe3 Generated classes now compiling. 2021-01-06 11:57:32 +11:00
Kevin Ring e49e6552a9 Deserialize materials. 2021-01-04 23:26:47 +11:00
Kevin Ring 1504ed3d90 Add materials. 2021-01-04 22:54:54 +11:00
Kevin Ring a67ed6a6ca Add support for primitive targets. 2021-01-04 22:32:35 +11:00
Kevin Ring e4a69c6559 Support attributes, names. 2021-01-04 22:21:54 +11:00
Kevin Ring ae16a4888f Separate files for glTF reader PoC. 2021-01-04 17:41:37 +11:00
Kevin Ring 0d7d7d0414 Add Mesh and Primitve to POC. 2021-01-04 13:36:34 +11:00
Kevin Ring a72c111c0f Another experiment. 2021-01-03 00:15:47 +11:00
Kevin Ring c29069f613 Some very broken experiments. 2021-01-02 22:23:04 +11:00
Kevin Ring 767b5d3a6d WIP glTF 2020-12-27 23:11:01 +11:00
Kevin Ring 72b07bc8d2 WIP glTF wrapper 2020-12-23 21:23:53 +11:00
Kevin Ring 6cb6cddac0 Add simdjson. 2020-12-19 22:26:09 +11:00
Kevin Ring 7a0f1907af WIP transition to cgltf. 2020-12-08 14:02:09 +11:00