Commit Graph

4815 Commits

Author SHA1 Message Date
IanLilleyT 52385b5aab getting non bounded ellipsoid working 2022-04-04 20:21:37 -04:00
Sanjeet Suhag f2632d88fe Merge branch 'main' of https://github.com/CesiumGS/cesium into AtmospherePostProcessing 2022-04-03 14:47:40 -04:00
IanLilleyT 43db8c6401 merge main 2022-04-01 14:24:29 -04:00
IanLilleyT 47ca8ea7e1 pretty printing sample data 2022-04-01 09:30:52 -04:00
IanLilleyT ea60548c38 custom shader improvements and relatively large shader cleanup 2022-03-31 22:03:09 -04:00
Janine Liu 88ece227db
Merge branch 'main' into model-experimental-clipping-planes 2022-03-31 15:40:09 -04:00
Janine Liu 94b0c63bf8 Code and documentation tweaks 2022-03-31 15:33:42 -04:00
IanLilleyT 922ac41a4a voxels 2022-03-31 14:41:08 -04:00
Peter Gagliardi e653a16f6b Remove unneeded code in sandcastle 2022-03-31 08:47:59 -04:00
Peter Gagliardi 059250696b Update asset for property texture Sandcastle 2022-03-31 08:36:05 -04:00
Peter Gagliardi c24ec0eee2 Add sandcastle code 2022-03-30 16:52:11 -04:00
Janine Liu dfd5011ac5 Feedback tweaks 2022-03-25 14:49:20 -04:00
Sean Lilley d74ee83ba8 Update jsHint to esversion 11 2022-03-22 18:11:09 -04:00
Kevin Ring f13b7a7f17 Merge remote-tracking branch 'origin/main' into split-primitives 2022-03-20 11:57:50 +11:00
Janine Liu 6867fe4461 Merge with main 2022-03-18 15:22:05 -04:00
Janine Liu 1aa1d9bb07 Merge with main 2022-03-16 15:05:08 -04:00
Peter Gagliardi c584bf2254 Merge branch 'main' into sync-1.1 2022-03-16 13:08:36 -04:00
Gabby Getz 31c154a299 Remove when.js and replace with native promises
There were a few areas in Source where a function was assumed to be executed synchronously when a function was resolved. Native Promises however, by spec, will resolve at the end of a frame. There were also some strange handling of promise rejection in imagery providers that I cleaned up a bit in order to make them testable.

- In LabelCollection and EntityCluster, order of execution adjustment where made.
- Added TextureAtlas.addImageSync to support the order of execution fix in LabelCollection
- ArcGisMapServerImageryProvider.readyPromise will not reject if there is a failure unless the request cannot be retried.
- SingleTileImageryProvider.readyPromise will not reject if there is a failure unless the request cannot be retried.

The majority of the changes lie in the Specs, where unresolved promises weren’t being awaited before finishing executions, and where resolved promises are assumed to be synchronous all over the place and needed a good amount of fixes. Another issue which came up was calling Promise.reject in the body of a spec can cause node to halt execution when running via the command line.
2022-03-16 09:38:39 -04:00
Kevin Ring 4ca71a3351 Add Sandcastle image, update CHANGES.md. 2022-03-13 22:25:46 +11:00
Janine Liu 0f86768337 Merge with main 2022-03-10 13:38:51 -05:00
Peter Gagliardi 3807829d37 Update selected feature ID stage 2022-03-08 16:29:53 -05:00
Peter Gagliardi 4e700f0344 replace featureIdIndex with featureIdLabel 2022-03-08 16:29:53 -05:00
Kevin Ring 6caf382c78 Finish Melbourne Photogrammetry / Cesium OSM Buildings comparison demo. 2022-03-06 11:57:15 +11:00
Kevin Ring 46024c5f95 WIP compare demo. 2022-03-06 11:15:14 +11:00
Kevin Ring 0c5931dd57 imagerySplitPosition -> splitPosition. 2022-03-06 10:43:47 +11:00
jeffechua d1bf81784c
Merge branch 'main' into custom-texture-coordinates 2022-03-05 16:14:14 +00:00
Jefferson Chua 516e138fbb Improved documentation and Sandcastle example. 2022-03-05 16:06:23 +00:00
Jefferson Chua 036fd9543f Converted texture coordinate input from flattened list to Cartesian2 polygon hierarchy structure, and modified PolygonGeometryLibrary's PolygonHierarchy packing methods to allow specification of what Cartesian to use to enable this. As a result, holes in holes can now be properly texture-mapped. 2022-03-05 00:49:07 +00:00
Jefferson Chua a0b230fa5b Merge branch 'custom-texture-coordinates' of https://github.com/jeffechua/cesium into custom-texture-coordinates 2022-03-03 15:06:38 +00:00
Peter Gagliardi dde7fd743e Merge branch 'extension-revisions' into buffer-view-renaming 2022-03-02 13:40:27 -05:00
Peter Gagliardi 0c1264e00a First pass at updating unit test data 2022-02-28 10:33:42 -05:00
IanLilleyT 3075cd4399 merge with origin/main 2022-02-28 09:30:48 -05:00
Kevin Ring ad72652f73 Set split direction when selecting new tileset. 2022-02-26 15:40:56 +11:00
Kevin Ring a49b0b8ce0 Splitter logic in Model instead of Scene. 2022-02-26 15:35:01 +11:00
Kevin Ring 2951cc8b22 Merge remote-tracking branch 'origin/main' into split-primitives 2022-02-26 14:04:25 +11:00
IanLilleyT 11ba5a917c fixed some old vars 2022-02-23 15:49:52 -05:00
Peter Gagliardi 2885188997 Update test data 2022-02-22 14:48:40 -05:00
Sean Lilley 54b9431d89
Merge pull request #10119 from CesiumGS/split-metadata-extensions
glTF metadata extensions were split into 3 extensions
2022-02-22 10:38:10 -05:00
Peter Gagliardi fbd2d5c571 Update CDB sandcastle 2022-02-22 08:28:23 -05:00
Peter Gagliardi 0fd0c3532f Metadata is now split into 3 extensions 2022-02-21 15:13:14 -05:00
Peter Gagliardi 015666a772 [skip ci] Overlooked a sample model 2022-02-21 14:09:26 -05:00
Peter Gagliardi ef73bd0ace Merge branch 'main' into extension-revisions 2022-02-18 15:07:37 -05:00
Sean Lilley 6f4e4807a7
Merge pull request #10052 from CesiumGS/manager-msaa
Add MSAA option for Webgl2
2022-02-17 19:17:41 -05:00
Eli Bogomolny a2fa0e44b9 Move MSAA Sandcastle to Showcases, change balloon view, fix MSAA getter docs 2022-02-17 15:35:21 -05:00
Kevin Ring d5329d0e2e Merge remote-tracking branch 'origin/command-flags' into split-primitives 2022-02-13 21:27:07 +11:00
Daniel Krupka 450216e590 Documentation and property declaration fixes 2022-02-11 14:27:46 -05:00
Daniel Krupka a765354f68 Add minimumPixelSize to ModelExperimental sandcastle 2022-02-11 07:40:30 -05:00
Kevin Ring 081ca95b90 Merge remote-tracking branch 'origin/main' into split-primitives 2022-02-11 22:38:53 +11:00
Peter Gagliardi b4b4aacb82 Fix custom shader 2022-02-10 16:01:00 -05:00
Peter Gagliardi 25c229404f Update for propertyTable schema changes 2022-02-10 15:55:04 -05:00
Daniel Krupka 4a6b90248e Fix ModelExperimental scale/maximumScale and add tests 2022-02-10 09:59:20 -05:00
Peter Gagliardi 624b58ce06 Change feature ID packing to return an int 2022-02-09 17:24:44 -05:00
Sanjeet Suhag 674ae4f49f Fixes Sandcastle 2022-02-07 20:28:58 -05:00
Peter Gagliardi 2a70f4bf72 rename FEATURE_ID -> _FEATURE_ID 2022-02-07 14:43:20 -05:00
Sanjeet Suhag e0251c6bd3 Merge branch 'main' of https://github.com/CesiumGS/cesium into feature/rebased-gpx 2022-02-07 10:33:05 -05:00
Gabby Getz eb7d802e53
Merge pull request #10041 from TheMagicNacho/quickstart-2
Add Quickstart
2022-02-04 09:31:18 -05:00
Gabby Getz 24b17c7928
Merge pull request #10068 from CesiumGS/custom-shader-template-literals
Simplify Custom Shader Sandcastle examples
2022-02-04 09:09:59 -05:00
Eli Bogomolny 4c2d6f6a0b Sandcastle prettier 2022-02-03 17:43:05 -05:00
Eli Bogomolny fd84fd9584 Update CHANGES.md and add Sandcastle example 2022-02-03 17:41:54 -05:00
Peter Gagliardi 42ca579f76 Update other sandcastles 2022-02-03 11:22:49 -05:00
Gabby Getz 6bbf84b7d0
Merge pull request #10067 from CesiumGS/enable-template-literals
Use ES6 template literals instead of string concatenation
2022-02-03 09:08:47 -05:00
Xavier Tassin 0574bca14d
Update Apps/Sandcastle/gallery/AtmospherePostProcessing.html
Co-authored-by: Gabby Getz <gabby@cesium.com>
2022-02-03 08:44:49 +01:00
Xavier Tassin 8b244994fe Removed optional rendering effect to focus on the post processing stage only. 2022-02-03 08:34:17 +01:00
Xavier Tassin 5d59b672ad
Update Apps/Sandcastle/gallery/AtmospherePostProcessing.html
Co-authored-by: Sam Suhag <sanjeetsuhag@users.noreply.github.com>
2022-02-03 08:08:01 +01:00
Xavier Tassin 2cbb9d7ce9
Update Apps/Sandcastle/gallery/AtmospherePostProcessing.html
Co-authored-by: Sam Suhag <sanjeetsuhag@users.noreply.github.com>
2022-02-03 08:07:38 +01:00
Peter Gagliardi ee6ee76dc2 Use template literals instead of string join 2022-02-02 15:59:07 -05:00
Peter Gagliardi 2fa7015313 string concatenation -> template literals 2022-02-02 15:40:21 -05:00
Xavier Tassin 88e6946afe Replaced let with const to fix broken build. As an other note, the sunColor variable in AtmospherePostProcessing.html is clearly a variable and is reassigned in the call to the Color.lerp method. Eslint insist on making it a const but I, as a human being, disagree, even though I am forced to comply to make the build work. 2022-02-02 14:21:03 +01:00
Xavier Tassin 3f8c64ceea Merge remote-tracking branch 'origin/AtmospherePostProcessing' into AtmospherePostProcessing 2022-02-02 13:26:11 +01:00
Xavier Tassin 7988b80718 Replaced var with let to fix broken build. As a note, my local build then fails with <code>39:9 error Parsing error: The keyword 'let' is reserved</code> 2022-02-02 13:13:01 +01:00
Xavier Tassin a419d58912
Merge branch 'main' into AtmospherePostProcessing 2022-02-02 11:42:16 +01:00
Xavier Tassin d832071991 Added a post processing stage for atmosphere light scattering
Also added a Sandcastle example for this new post processing stage
2022-02-02 11:33:56 +01:00
Sanjeet Suhag 6f15cc7a52 Sandcastle fix 2022-02-01 10:56:58 -05:00
Janine Liu 100a42bb1d Delete Gltf3DTileContent and replace with ModelExperimental3DTileContent 2022-01-31 17:01:16 -05:00
Sanjeet Suhag 0ee20739e1 Updates Gpx specific files to ES6 let/const syntax 2022-01-31 11:37:08 -05:00
Sanjeet Suhag 591b413dc4 Merge branch 'main' of https://github.com/CesiumGS/cesium into feature/rebased-gpx 2022-01-31 11:25:09 -05:00
Sam Suhag 63340e3cc3
Merge pull request #10050 from CesiumGS/let-const-code-examples
Update documentation examples to use const/let
2022-01-28 13:41:07 -05:00
Gabby Getz 1edbc265c6 Update guides 2022-01-28 12:59:08 -05:00
Sean Lilley 9855a6d8f8
Merge pull request #10018 from CesiumGS/multi-feature-ids
Handle multiple feature ID sets in `ModelExperimental`
2022-01-28 11:56:41 -05:00
Samuel Rothstein f41c31b207 updated the scope of rainGravityScratch 2022-01-27 12:00:31 -08:00
Samuel Rothstein f34a5b187c updated the scope of snowGravityScratch 2022-01-27 11:59:36 -08:00
Sam Rothstein a2b2791596
Simplify color value.
Co-authored-by: Gabby Getz <gabby@cesium.com>
2022-01-27 11:57:58 -08:00
Samuel Rothstein 5e7269393d cleaned up the use of primitives 2022-01-27 09:43:53 -08:00
Samuel Rothstein 2d7d96a92d removed unnecessary eslint-disable prefer-const 2022-01-27 08:21:41 -08:00
Peter Gagliardi 2a61e4f8f2 Simplify multi-feature ID sandcastle 2022-01-27 10:00:40 -05:00
TheMagicNacho 85ec59ba9c cleanup commit 2022-01-26 22:07:10 -05:00
Samuel Rothstein 31d226be50 cleaning up particle system weather (rain system) 2022-01-26 16:04:35 -08:00
Samuel Rothstein b788a3ab07 cleaning up particle system weather 2022-01-26 16:01:04 -08:00
Peter Gagliardi 6ff5186c3b Merge tag 'post-let-const' into lets-merge2
Post let/const transition
2022-01-26 16:07:43 -05:00
Gabby Getz 9f254c819b disbale-next-line 2022-01-26 13:40:08 -05:00
Peter Gagliardi b10e30869f Demonstrate using multiple feature ID sets 2022-01-25 15:38:47 -05:00
Peter Gagliardi d114a535eb Update feature ID in other sandcastle 2022-01-24 11:30:41 -05:00
Gabby Getz 8143df4436 var -> const/let 2022-01-21 11:26:25 -05:00
Gabby Getz 3de446615c Update eslint config 2022-01-21 11:25:54 -05:00
Peter Gagliardi 0fea72cc6f Merge branch 'main' into multi-feature-ids 2022-01-21 10:17:28 -05:00
Peter Gagliardi f74b4735f5 Add .featureId to model and tile features 2022-01-20 11:01:00 -05:00
Peter Gagliardi 9c01d4ffa0 Update photogrammetry classification sandcastle 2022-01-19 16:15:40 -05:00
Kevin Ring 0fe11e6558 Merge remote-tracking branch 'origin/main' into split-primitives 2021-12-29 16:22:32 +11:00
Sean Lilley 353c236f6a Fix for https://github.com/CesiumGS/cesium/pull/9857 2021-12-09 19:47:28 -05:00
Sean Lilley f1c22bb480
Merge branch 'main' into zgeo-tx 2021-12-09 18:35:06 -05:00
Sean Lilley ab777b3351 Updated to cloud color 2021-12-09 18:31:06 -05:00
Peter Gagliardi d311ce24d7 Fix vec3 color attributes in custom shaders 2021-12-06 11:32:47 -05:00
Peter Gagliardi 8726b3be8a Add animated point cloud to custom shaders sandcastle 2021-12-03 15:19:49 -05:00
Peter Gagliardi 8fb0fdb6f5 Add pointSize to custom vertex shaders 2021-12-03 10:40:22 -05:00
Sanjeet Suhag db478549ee Improves UX of CDB Yemen Sandcastle 2021-11-30 13:40:17 -05:00
Sanjeet Suhag 8af153e7f3 Updates asset used in S2 Sandcastle 2021-11-30 11:04:33 -05:00
Kevin Ring 3fd8320f2f Add SplitDirection, deprecate ImagerySplitDirection. 2021-11-28 22:48:11 +11:00
Peter Gagliardi c9c5443f2a Fix broken links in ModelExperimental Sandcastle 2021-11-09 16:12:32 -05:00
Sanjeet Suhag b0bd9915f3 Set default to dryground 2021-11-09 11:54:02 -05:00
Sanjeet Suhag 97726e9084 asset update 2021-11-09 11:25:12 -05:00
Sanjeet Suhag 7973dd5de4 Updates Yemen terrain ID 2021-11-09 10:57:56 -05:00
Peter Gagliardi 023f86df11 Remove unused screenshot 2021-11-09 08:51:28 -05:00
Tam 8010d82896 - Run prettier
- Removed default access tokens
2021-11-08 21:03:23 -08:00
Tam 1d575f87a7 -Removed default access tokens 2021-11-08 20:37:22 -08:00
Tam 0e566d0f25 - Updated i3s support to cesiumjs 1.87
- clamp to default min & max values in 
ArcGISTiledElevationTerrainProvider if not available
- Improved pick accuracy (Find a triangle touching the point px,py,pz, 
then return the vertex closest to the search point)
2021-11-08 20:25:45 -08:00
Sean Lilley af1057127c Remove old comment 2021-11-08 22:49:28 -05:00
Sean Lilley d8c2feb04a Demo tweaks 2021-11-08 22:46:54 -05:00
Sean Lilley 4a75b80cb6 Rename 3D Tiles Next Feature Id Textures to 3D Tiles Next Photogrammetry Classification 2021-11-08 21:52:45 -05:00
Sean Lilley de2f334499 Fixed time of day for feature id sandcastle 2021-11-08 21:52:45 -05:00
Sanjeet Suhag 9d39b06e99 Updates CDB Yemen 2021-11-08 21:42:10 -05:00
Sanjeet Suhag 86d1d9492b Merge branch 'model-experimental-sandcastle' of https://github.com/CesiumGS/cesium into model-experimental-sandcastle 2021-11-08 20:48:29 -05:00
Sanjeet Suhag 60f6a6b2e6 Feedback on Yemen Sandcastle, thumbnail size fix for F_ID_tex 2021-11-08 20:48:23 -05:00
Peter Gagliardi b114b1623c Make a different shader for the S2 globe 2021-11-08 20:30:35 -05:00
Sanjeet Suhag f8ac6ce584 Merge branch 'model-experimental-sandcastle' of https://github.com/CesiumGS/cesium into model-experimental-sandcastle 2021-11-08 17:05:54 -05:00
Sanjeet Suhag 215ff36836 Feedback 2021-11-08 17:05:47 -05:00
Peter Gagliardi 56c66b133e Add sandcastle for Feature ID textures 2021-11-08 17:03:09 -05:00
Sanjeet Suhag a11466d49c Updates to hosted yemen asset 2021-11-08 15:53:56 -05:00
Sanjeet Suhag ff1a21a8cc Adds S2 and Yemen Sandcastles 2021-11-08 13:50:50 -05:00
ZLJCTX c3f3a4ca96
Merge branch 'main' into zgeo-tx 2021-10-23 01:15:20 +08:00
Sanjeet Suhag 8e03d46b7f Adds Model Sandcastle 2021-10-18 15:18:13 -04:00
lyqh-ctx 0cf95fd13a adds color for CumulusCloud 2021-10-15 23:53:52 +08:00
Daniel Krupka ef68d58d2a Use viewer.container in demo apps 2021-10-14 13:40:11 -04:00
Daniel Krupka 043724e5bc Enable screenOverlay in demo apps 2021-10-13 11:53:09 -04:00
hpinkos 3a16cef1e0 fix model url in sandcastle example 2021-10-07 17:58:33 -04:00
Peter Gagliardi b5005d0d4e Update development sandcastles 2021-09-17 18:27:02 -04:00
Sean Lilley 22f7db3087
Merge pull request #9725 from CesiumGS/model-experimental-custom-shaders
Add custom shaders to `ModelExperimental`
2021-08-30 15:15:22 -04:00
Peter Gagliardi 4ef91b29e5 Remove stray console.log call 2021-08-30 14:38:27 -04:00
Peter Gagliardi 5f342c8fea Add a gradient example 2021-08-30 14:17:47 -04:00
Janine Liu 8579302ae5 Refine code for clouds, replace outdated code in BillboardCollection 2021-08-27 16:20:59 -04:00
Peter Gagliardi b4258fd4a8 Add CustomShader + ModelExperimental dev Sandcastle 2021-08-27 11:56:31 -04:00
Peter Gagliardi d78e5af4c5 Start working on a development sandcastle for ModelExperimental 2021-08-27 10:47:22 -04:00
Peter Gagliardi 734b81ebf5 Add simple example of styling 3D Tiles 2021-08-27 08:39:53 -04:00
Janine Liu d837d00e67 Add new sandcastle and other documentation images 2021-08-24 17:54:51 -04:00
Janine Liu 157f84530c Add cloud parameters sandcastle 2021-08-19 17:01:12 -04:00
Sean Lilley fe8fec2d51 master -> main 2021-07-16 19:01:30 -04:00
Sean Lilley b195b31395
Merge pull request #9656 from CesiumGS/primitive-example
Development Sandcastle to show how to make a Primitive from scratch
2021-07-07 10:56:36 -04:00
Peter Gagliardi a080a29247 Move initialze() call into update() 2021-07-07 10:04:55 -04:00
Peter Gagliardi 51d68bea07 Rename methods for clarity 2021-07-07 09:59:18 -04:00
Tamrat Belayneh 882b9b66a0 log clean ups 2021-07-06 13:29:47 -07:00
Peter Gagliardi 5bd9d1fe55 Fix tessellation indexing 2021-07-01 16:07:03 -04:00
Peter Gagliardi 9051710470 Make more interesting procedural waves 2021-07-01 14:55:37 -04:00
Tamrat Belayneh 37bf80a9b1 Fixed lint issues 2021-06-30 10:24:02 -07:00
ebogo1 e6b833d6be update IBL Sandcastle and shader 2021-06-25 22:13:37 -04:00
ebogo1 d20fda3603 don't use spy for CI ktx2 specs 2021-06-24 19:17:20 -04:00
Tamrat Belayneh 4b7c081754 Fixes for travis-ci issues 2021-06-23 17:26:03 -07:00
ebogo1 c1ac0daa66 Merge branch 'master', remote-tracking branch 'origin' into add-ktx2 2021-06-23 14:36:26 -04:00
Tamrat Belayneh 7b01bde92f Added I3S data source support in Cesium 2021-06-22 23:21:36 -07:00
Sean Lilley 131280f2e8 Merge branch 'master' into dynamicTerrainExaggeration 2021-06-18 14:48:44 -04:00
Ian Lilley 672cbed438 Added procedural terrain sandcastle 2021-06-18 09:59:17 -04:00
ebogo1 d9f50b27dc merge master 2021-06-16 22:02:59 -04:00
ebogo1 21daf50fed first pass PR feedback 2021-06-16 18:18:08 -04:00
Peter Gagliardi c8723f43d0 Add texture and animation to the custom primitive 2021-06-16 14:57:48 -04:00
Peter Gagliardi 45872b0c6b Create a Sandcastle to demonstrate making a custom primitive 2021-06-14 17:08:05 -04:00
Ian Lilley cfe61930e4 Added CustomHeightmapTerrainProvider 2021-06-08 23:02:31 -04:00
Ian Lilley ad9da87992 Dynamic terrain exaggeration 2021-06-08 20:07:45 -04:00
Janine Liu 8418eb5ac7 Fix broken image in KML Sandcastle 2021-06-01 15:42:29 -04:00
ebogo1 eefbeee9f9 update KTX2 glTF/glb to KHR_texture_basisu spec 2021-05-20 15:11:11 -04:00
ebogo1 da30ff79a3 UASTC support 2021-05-06 14:46:09 -04:00
ebogo1 8e708d13de fix parseKTX2 logic and add mip level support to Material.js 2021-05-04 11:32:07 -04:00
ebogo1 3d6962dfcb first pass PR feedback 2021-05-01 23:29:26 -04:00
ebogo1 681f952ebe remove unused .ktx2 files 2021-04-30 14:56:14 -04:00
ebogo1 0ba051843f fix Sandcastles 2021-04-30 14:55:28 -04:00
ebogo1 864acae71b add missing specs and sample data 2021-04-29 22:39:39 -04:00
ebogo1 e5ecf33369 update sandcastles 2021-04-27 16:57:20 -04:00
ebogo1 f56d0dba05 first ktx2 pass 2021-04-25 16:56:26 -04:00
Hannah bc49ca8a75
Merge pull request #9463 from CesiumGS/fix-mantle-radius
Fix artifacts in Globe Interior sandcastle
2021-04-01 15:46:53 -04:00
Sean Lilley 1d22bc9e5e Shrink mantle radius to avoid z-fighting with low LOD terrain tiles 2021-04-01 15:41:29 -04:00
hpinkos a30566311d update sandcastle assets 2021-04-01 14:18:07 -04:00
hpinkos 33730e64bf use new icon and social card 2021-03-30 17:56:24 -04:00
Kevin Ring 246bbea7a2
Merge pull request #9294 from CesiumGS/eslint-gulpfile
Run eslint on cjs files
2021-03-01 09:41:58 +11:00
Kevin Ring 25585356e8 Merge remote-tracking branch 'origin/master' into eslint-gulpfile 2021-03-01 08:57:44 +11:00
Kevin Ring 4dceccf0ed Merge remote-tracking branch 'origin/master' into polylineVolumeCzml 2021-03-01 08:31:58 +11:00
Ian Lilley 3bb6330d36 fixed changes.md and added arcgis to terrain sandcastle 2021-02-28 14:52:48 -05:00
Scott Hunter 783582c532
Prefer `cartesian2` representation in CZML for `PolylineVolume.shape`.
In CZML, `cartesian` always means a three-dimensional `Cartesian3`.
`shape` is a list of two-dimensional `Cartesian2` values, which should be specified as `cartesian2`.

For backwards compatibility, the out-of-spec `cartesian` representation is still accepted.

Also adds `polylineVolume` to the CZML validation document assertions.
2021-02-16 16:36:50 -05:00
Ian Lilley b3334483f6 set exact camera position for disable depth test when clamped to ground sandcastle 2021-02-01 14:45:25 -05:00
Ian Lilley b6a7bcdd32 make BIM not float in sandcastle clipping plane demo 2021-02-01 13:05:41 -05:00
hpinkos 2e13fb60db reconfigure eslint 2021-01-25 11:00:37 -05:00
Ian Lilley 8e2980bdd4 fixed gradient checkbox 2020-12-16 13:47:11 -05:00
Ian Lilley 8d592d4cbf another layering fix 2020-12-15 18:02:41 -05:00
Ian Lilley 0baf49521c Merge branch 'master' into elevationBand 2020-12-14 12:14:55 -05:00
Mac Clayton 9b206b0171 Switch USGS sandbox sample to be https so that it will function correctly 2020-12-12 09:30:08 -06:00
Nithin Pranesh 291de01b4f Added warning for unsupported ground primitive texture materials in Sandcastle for Internet Explorer. 2020-11-30 17:13:31 -05:00
Hannah a70d8dd963
Merge branch 'master' into chrome-79-bug-fix/contrib 2020-11-24 11:50:44 -05:00
Ed Mackey e5bb76bac3 prettier 2020-10-27 21:18:58 -04:00
Ed Mackey 171498f00f Added CesiumDrone model, optimize GroundVehicle. 2020-10-27 14:57:38 -04:00
Sean Lilley 2158ea9e97 Change vctr and geom branch name 2020-10-09 15:00:23 -04:00
Sean Lilley c48aadcf51
Merge branch 'master' into elevationBand 2020-09-25 19:42:33 -04:00
Omar Shehata 306954f71a Tweak comments in sandcastle [ci skip] 2020-09-21 15:35:53 -04:00
jtorresfabra bc9ff88ebc Add missing documentation and improves the SandCastle
SandCastle includes a new example on how to use different symbology options
2020-09-21 11:18:17 +02:00
Dzung a05c963556 Overrode 3D Tiles Styling with OSM Styling; fixed toolbar menu 2020-09-18 09:35:25 -04:00
jtorresfabra dc1a79a270 Rebase gpx branch 2020-09-17 10:08:55 +02:00
Dzung 0e59bfd12c Added picking central location for color by distance function 2020-09-16 14:34:23 -04:00
Omar Shehata 5b048d879f Fix Sandcastle image, tweak styling Sandcastle 2020-09-15 21:03:53 -04:00
Dzung 423ed40606 Updated code to include important features and make it easier to understand 2020-09-15 15:55:29 -04:00
andre-nunes f9f1b630f5 Add GPX Demo to Sandcastle 2020-09-15 12:26:40 +02:00
andre-nunes 06470eff0f Add example gpx file 2020-09-15 12:26:39 +02:00
andre-nunes b790266b02 Add tests 2020-09-15 12:26:39 +02:00
andre-nunes 96fa24fc4a Add GpxDataSource to CesiumViewer 2020-09-15 12:26:39 +02:00
andre-nunes 1a12687751 Add gpx sample files 2020-09-15 12:26:39 +02:00
Dzung fc3b8e8a47 Added sandcastle tutorial for styling Cesium OSM buildings 2020-09-11 16:55:11 -04:00
Ian Lilley 507e470d34 Fixed premultiplied alpha bug and some cleanup 2020-09-03 12:00:22 -04:00
Ian Lilley 2f457f3e9e initial implementation of ElevationBandMaterial 2020-09-03 11:59:01 -04:00
Frederic Junod 241a27edf8 Update prettier to version ^2.1.1 2020-08-28 10:15:42 +02:00
willjad 3bae221214 remove chrome 79 workaround 2020-07-25 13:26:31 -05:00
Bao Tran 3fce5665e5 change asset id for san-miguel example 2020-07-21 16:15:46 -04:00
hpinkos 64e1051247 renames 2020-06-15 14:17:30 -04:00
Hannah 8f31d68fdb
Merge branch 'master' into jr/czml-polyline-volume 2020-06-15 11:47:50 -04:00
Ian Lilley a23f6e1216
Merge pull request #8939 from SambaLim/feature-SandBox-Camera
Add new buttons for Sandcastle-Camera
2020-06-12 10:39:06 -04:00
Ian Lilley 49fb164110 calling reset manually in toolbar options to avoid complete and cancel calling reset 2020-06-12 10:29:39 -04:00
Omar Shehata ebd4496e4e Ignore non-existant labels (like 'New in 1.XX') 2020-06-11 15:23:06 -04:00
Sambalim a45af53f6c fix: Accidentally adding lines 2020-06-09 22:42:44 +09:00
Sambalim f4b1110972 feature: Add new buttons 2020-06-09 22:33:12 +09:00
jrafidi a1f395fe62
Merge branch 'master' into jr/czml-polyline-volume 2020-06-02 14:44:18 -07:00
Sean Lilley 9a79ec04b3 Fix variable naming in fog sandcastle 2020-06-01 22:05:27 -04:00
Eli Bogomolny 9c96bb6aae removed extra whitespace line 2020-06-01 13:28:40 -04:00
Eli Bogomolny 3b29c1abd2 Fixed Bing Maps Road option in sandcastle example 2020-06-01 13:03:37 -04:00
Ian Lilley 7abebc1f7b
Merge branch 'master' into day-night-textures 2020-06-01 09:09:21 -04:00
Matthew Amato ac504a4cfc Merge remote-tracking branch 'origin/master' into typescript-definitions 2020-05-31 12:45:37 -04:00
Hannah d01584abea
Merge pull request #8847 from CesiumGS/sandcastleSearchFix
Make entire sandcastle code searchable
2020-05-29 11:14:28 -04:00
Hannah 92b6bb0124
Merge branch 'master' into day-night-textures 2020-05-29 10:44:11 -04:00
Hannah 72dc2cb29f
Update CesiumSandcastle.js 2020-05-29 10:41:31 -04:00
Matthew Amato 43c6aece88
Merge pull request #8714 from CesiumGS/sandcastle-error
Fix export KML Sandcastle
2020-05-29 10:33:23 -04:00
Hannah fffeeeaea7
Merge pull request #8798 from CesiumGS/fog-post-process
Fog post process sandcastle
2020-05-29 10:26:30 -04:00
Omar Shehata 438b7ef0e7 Minor tweak to doc and Sandcastle 2020-05-27 13:36:02 -04:00
Kevin Ring 0a0f5f219c Add new Sandcastle example. 2020-05-27 18:56:41 +10:00
Matthew Amato 85c78edf31 Generate official TypeScript type definitions
It's been a long requested feature for us to have official TypeScript type
definitions.  While the community has done a yeoman's job of manually
supporting various efforts, the most recent incarnation of which is
`@types/cesium`, the sheer scale and ever-evolving nature of Cesium's code
base makes manual maintenance a Sisyphean task.

Thankfully, our decision to maintain meticulous JSDoc API documentation
continues to pay dividends and is what makes automatically generating
TypeScript definitions possible. Using the excellent
https://github.com/englercj/tsd-jsdoc project we can now automatically
generate and even partially validate official definitions as part of the
build process. (Thanks to @bampakoa who contributed some early PRs to both
CesiumJS and tsd-jsdoc over a year ago and is how I learned about
tsd-jsdoc)

While tsd-jsdoc output is mostly where we need it to be, we do
post-processing on it as well. This lets us clean up the output and also
make sure these definitions work whether users include cesium via module,
i.e. `import { Cartesian3 } from 'cesium'`, or individual files, i.e.
`'import Cartesian3 from 'cesium/Source/Core/Cartesian3'`. There were also
some quirks of tsd-jsdoc output we fixed that may eventually turn into a PR
into that project from us. The post-processing is part typescript compiler
API, part string manipulation. It works and is straightforward but we might
want to go full TS api in the future if we decide we need to do more
complicated tasks. The output of tsd-jsdoc is currently a little noisy
because of some incorrect error reporting, but I'm talking with the
maintainer in https://github.com/englercj/tsd-jsdoc/issues/133 to get them
fixed. No need to hold up this PR for it though.

The definition is generated as a single `Cesium.d.ts` file in Source, so it
lives alongside Cesium.js. It is ignored by git but generated by a separate
`build-ts` task as part of CI and makeZipFile. This task also validates the
file by compiling it with TypeScript, so if a developer does anything too
egregious, the build will fail. Definitions are automatically included in
our npm packages and release zips and will be automatically used by IDEs
thanks to the `types` setting in package.json. This means that IDEs such as
VS Code will prefer these types over the existing `@types/cesium` version
by default.

I didn't want to slow the `build` step down, so I made this a separate
step, but in the future we could consider running it by default and we
could also unignore this file in Git so that PR reviewers can see the
impact, if any, our code changes have on the generated definitions. This
might be a good idea as an additional sanity check and should only actually
change when the public API itself changes. But the issue would be
remembering to run it before submitting the code (or we could use git hooks
I suppose?) I just don't want to slow down devs so I'm hesitant to do
anything like this out of the gate. We can definitely revisit in the
future.

A particular exciting thing about this approach is that it exposed a ton of
badness in our current JSDoc markup, which is now fixed. Previously, our
only concern was "does the doc look right" and we didn't pay attention to
whether the meta information generated by JSDoc correctly captured type
information (because up until it didn't matter). We leaned particular hard
on `@exports` which acted as a catch-all but has now been completely
removed from the codebase. All this means is that our documentation as a
whole has now improved greatly and will continue to be maintained at this
new higher level thanks to incorporating TS definition creation into our
pipeline!

One minor caveat here is that obviously we changed our JSDoc usage to both
make it correct and also accommodate TypeScript. The main drawback to these
fixes is that enums are now generated as globals in the doc, rather than
modules. This means they no longer have their own dedicated page and are
instead on the globals page, but I changed the code to ensure they are
still in the table of contents that we generate. I think this trade-off is
perfectly fine, but I wanted to mention it since it does change the doc
some. We can certainly look into whether we can generate enums on their own
page if we think that makes sense. (I actually like this approach a little
better personally).

Last major piece, the actual code. 99% of the changes in this PR only
affect the JSDoc. There are two exceptions:

A few of our enums also have private functions tacked onto them. I had to
move these functions to be outside the initializer but otherwise they are
unchanged.  This ensures that a valid TS enum is generated from our code, since you can't have functions globbed onto enums in the TS world. If we were writing TS code by hand, we could use  declaration merging with a namespace, but the toolchain we are using doesn't have a way to express that right now.  There were two cases where these extra functions weren't private, `ComponentDataType` and `IndexDataType`. That means that as far as the TS definitions goes, the helper methods don't exist.  I consder this an edge case and we can write up issues to investigate later.  I'm actually not even sure if these functions are public on purposes, @lilleyse can you confirm?

We had a few places where we had method signatures with optional parameters
that came _before_ required parameters, which is silly. This is invalid
TypeScript (and not good API design no matter the language). In 99% of
cases this was `equalsEpsilon` style functions where the lhs/rhs were
optional but the epsilon was not. I remember the discussion around this
when we first did it because we were paranoid about defaulting to 0, but
it's an edge case and it's silly so I just changed the epsilon functions
to default to zero now, problem solved.

Here's a high level summary of the JS changes:

* Use proper `@enum` notation instead of `@exports` for enums.

* Use proper `@namespace` instead of `@exports` for static classes.

* Use proper `@function` instead of `@exports` for standalone functions.

* Fix `Promise` markup to actually include the type in all cases, i.e.
`Promise` => `Promise<void>` or `Promise<Cartesian3[]>`.

* Fix bad markup that referenced types that do not exist (or no longer
exist) at the spec level, `Image` => `HTMLImageElement`,
`Canvas` => `HTMLCanvasElement`, etc.. `TypedArray` in particular does not
exist and much be expressed as a lsit of all applicable types,
`Int8Array|Uint8Array|Int16Array|Uint16Array...`.

* Use dot notation instead of tilde in callbacks, to better support
TypeScript, i.e. `EasingFunction~Callback` becomes
`EasingFunction.Callback`. The only exception is when we had a callback
type that was i.e. `exportKml~ModelCallback` becomes
`exportKmlModelCallback` (a module global type rather than a type on
exportKml). This is because it's not possible to have exportKml be both a
function and a namespace in this current toolchain.  Not a big deal either
way since these are meta-types used for defining callbacks but I wanted to
mention it.

* There were some edge cases where private types that were referenced in
the public API but don't exist in the JSDoc. These were trivial to fix by
either tweaking the JSDoc to avoid leaking the type or in some cases, just
as `PixelDataType`, simply exposing the private type as public.  I also
found a few cases where things were accidentally public, I marked these as
private (these were extreme edge cases so I'm not concerned about breaking
changes). Appearances took an optional `RenderState` in their options, I
just changed the type to `Object` which we can clean up further later if
we need to.

* Lots of other little misc JSDoc issues that became obvious once we
started to generate definitions (duplicate parameters for example).

Thanks again to the community for helping generate ideas and discussions
around TS definitions over the last few years and a big thanks to @javagl
for helping behind the scenes on this specific effort by evaluating a few
different approaches and workaround before we settled on this one (I'm
working on a blog with all of the gory details for those interested).

Finally, while I'm thrilled with how this turned out (all ~41000 lines
and 1.9MB of it), I can guarantee we will uncover some issues with the
type definitions as more people use it. The good news is that improving it
is now just a matter of fixing the JSDoc, which will benefit the community
as a whole and not just TS users.


Fixes #2730
Fixes #5717
2020-05-26 22:40:05 -04:00
Ian Lilley e1ffa48ef6 some tweaks to day/night blending 2020-05-26 15:26:22 -04:00
Ian Lilley 3a4d413759 Merge branch 'master' into day-night-textures 2020-05-25 22:18:42 -04:00
Sean Lilley 775096ae81 Added GlobeTranslucency to group translucency options 2020-05-23 12:43:48 -04:00
Sean Lilley a20fdd61c4 Turn off globe lighting in demo 2020-05-22 21:38:05 -04:00
Sean Lilley c6bb5a1d1a Merge branch 'sky-atmosphere-per-fragment' into globe-alpha 2020-05-22 20:57:26 -04:00
Sean Lilley f57b6ad50b Updates from review 2020-05-21 14:25:30 -04:00
Sean Lilley 2bcdbac6a5 Show back faces in cartogrphic limit rectangle sandcastle 2020-05-20 00:07:36 -04:00
Sean Lilley 02792c5a74 Updates from review 2020-05-19 22:31:21 -04:00
Sean Lilley 3ac1bdffb0 Rename undergroundColorByDistance to undergroundColorAlphaByDistance 2020-05-19 22:29:14 -04:00
Edvinas Pranka a0c20811ae Added night textures showcase to the Sandcastle 2020-05-18 17:53:00 +03:00
Sean Lilley c4c635ae09 Merge remote-tracking branch 'origin/underground-color' into globe-alpha 2020-05-17 21:12:45 -04:00
Sean Lilley 1029ec9e6d Add getters/setters, Sandcastle, tests 2020-05-17 20:59:57 -04:00
Sean Lilley 9e491a09a5 Use better image for sandcastle [skip ci] 2020-05-17 10:11:15 -04:00
Ian Lilley 6cdd33b90c Changed code mirror viewport margin to Infinity for improved search 2020-05-13 10:38:50 -04:00