-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clipping Planes- Terrain & optimizations, and/or option, plane primitives, edge highlighting #5996
Merged
lilleyse
merged 42 commits into
CesiumGS:clip-planes-master
from
ggetz:clipping-planes-terrain
Dec 4, 2017
Merged
Changes from 1 commit
Commits
Show all changes
42 commits
Select commit
Hold shift + click to select a range
d188014
Add plane geometry
ggetz 8ef6754
Merge branch 'clipping-planes-tileset-traversal' into clipping-planes…
ggetz 51f28d0
Merge branch 'clipping-planes-tileset-traversal' into clipping-planes…
ggetz d142b0f
Added plane graphics and geometries, update clipping planes example
ggetz 4dfea3a
Cleanup
ggetz ee8b97a
Update sandcastle demo, colors and scenario
ggetz 33eb86a
Clipping planes on terrain
ggetz 951a33b
Modified shaders to highlight clipping edge
ggetz 8981779
Add demo
ggetz a0932d5
Merge branch 'clipping-planes-edge-styling' into clipping-planes-terr…
ggetz c0ec2c4
Add highlighting to terrain edges
ggetz 5ec1058
Multiple clipping planes && together, define terrain clipping plane o…
ggetz 48190c7
Merge branch 'clipping-planes-terrain-and-highlight-edges' into clipp…
ggetz 443f73a
Add ClippingPlaneCollection
ggetz 910e1c6
Fixed scaling in demo
ggetz 6d67925
Optimize globe tile loading with clipping planes
ggetz 086a03b
Cleanup docs
ggetz af21899
Updated CHANGES.md
ggetz 7487847
Tweak doc
ggetz ea2d8da
Merge remote-tracking branch 'cesium/clip-planes-master' into clippin…
ggetz 227698c
Update Sandcastle example, fix sandcastle images
ggetz e8e14f2
Refactor clipping planes
ggetz 4a37690
Fix Plane geometry classes
ggetz 93a2940
Fix doc
ggetz 8d41a56
Pixel width for edge highlighting, fix model transforms
ggetz b4c9a8d
Point cloud clipping fix
ggetz 627b8d4
Update clipping planes example
ggetz fd151a0
Indent includes
lilleyse 5b75ee5
Cleanup and add plane geometry sandcastle example
ggetz 92fc2bb
Fix failing tests
ggetz 0af0db6
Specs
ggetz 77457f5
Fix errors
ggetz 47e0ec3
Cleanup, update specs
ggetz 5680c34
Fix plane geometry surface
ggetz 21c96e9
Draw commands in specs
ggetz 3b069ca
Model and PlaneGeometry Specs
ggetz 82a2780
Cleanup
ggetz ca40033
i3dm tileset in specs
ggetz 31079f7
Added i3dm tilesets
ggetz b83e288
i3dm specs
ggetz 2d855b8
Add instanced tileset to sandcastle example
ggetz c8cd6fa
Tweak sandcastle example
ggetz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -172,12 +172,20 @@ define([ | |
} | ||
|
||
var length = this.planes.length; | ||
var i; | ||
if (result.planes.length !== length) { | ||
result.planes = new Array(length); | ||
|
||
for (i = 0; i < length; ++i) { | ||
result.planes[i] = new Plane(Cartesian3.UNIT_X, 0.0); | ||
} | ||
} | ||
for (var i = 0; i < length; ++i) { | ||
|
||
for (i = 0; i < length; ++i) { | ||
var plane = this.planes[i]; | ||
result.planes[i] = new Plane(plane.normal, plane.distance); | ||
var resultPlane = result.planes[i]; | ||
resultPlane.normal = plane.normal; | ||
resultPlane.distance = plane.distance; | ||
} | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I didn't notice this before - since |
||
result.enabled = this.enabled; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use
Cartesian3.clone
here, withresultPlane.normal
as theresult
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Never mind I see that this is already in.