Skip to content
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

Generate tighter near far bounds in View.js #8850

Merged
merged 15 commits into from
Jun 28, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
- Fixed a bug where certain rhumb arc polylines would lead to a crash. [#8787](https://github.com/CesiumGS/cesium/pull/8787)
- Fixed handling of Label's backgroundColor and backgroundPadding option [#8949](https://github.com/CesiumGS/cesium/8949)
- Fixed several bugs when rendering CesiumJS in a WebG 2 context. [#797](https://github.com/CesiumGS/cesium/issues/797)
- Fixed a bug where switching from perspective to orthographic caused triangles to overlap each other incorrectly. [#8346](https://github.com/CesiumGS/cesium/issues/8346)
- Fixed `scene.pickFromRay` intersection inaccuracies. [#8439](https://github.com/CesiumGS/cesium/issues/8439)

### 1.70.1 - 2020-06-10

Expand Down
12 changes: 10 additions & 2 deletions Source/Scene/DerivedCommand.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,14 +189,22 @@ function getLogDepthShaderProgram(context, shaderProgram) {
sources.push(logMain);
}

var addExtension = true;
writesLogDepth = false;
sources = fs.sources;
length = sources.length;

writesLogDepth = false;
for (i = 0; i < length; ++i) {
if (writeLogDepthRegex.test(sources[i])) {
writesLogDepth = true;
}
}
// This define indicates that a log depth value is written by the shader but doesn't use czm_writeLogDepth.
if (fs.defines.indexOf("LOG_DEPTH_WRITE") !== -1) {
writesLogDepth = true;
}

var addExtension = true;
for (i = 0; i < length; ++i) {
if (extensionRegex.test(sources[i])) {
addExtension = false;
}
Expand Down
5 changes: 4 additions & 1 deletion Source/Scene/PointCloudEyeDomeLighting.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,10 @@ function createFramebuffer(processor, context) {
var distanceAndEdlStrengthScratch = new Cartesian2();

function createCommands(processor, context) {
var blendFS = PointCloudEyeDomeLightingShader;
var blendFS = new ShaderSource({
defines: ["LOG_DEPTH_WRITE"],
sources: [PointCloudEyeDomeLightingShader],
});

var blendUniformMap = {
u_pointCloud_colorGBuffer: function () {
Expand Down
1 change: 0 additions & 1 deletion Source/Scene/Scene.js
Original file line number Diff line number Diff line change
Expand Up @@ -1555,7 +1555,6 @@ Object.defineProperties(Scene.prototype, {
if (this._logDepthBuffer !== value) {
this._logDepthBuffer = value;
this._logDepthBufferDirty = true;
this._defaultView.updateFrustums = true;
}
},
},
Expand Down
Loading