CesiumGS / CesiumGS/cesium

Overlapping image material z-fighting bug

Open
#4,695 0 comments 0 reactions 0 assignees View on GitHub
category - graphics type - bug
Dominant language
JavaScript
Stars
15.8k
Forks
3.9k
Avg merge
4d 6h
Merged PRs (30d)
34

Description

Reported on the forum: https://groups.google.com/forum/#!topic/cesium-dev/EKRqbL2TJJU

![image](https://cloud.githubusercontent.com/assets/3451886/20754792/996ac670-b6da-11e6-82f7-08cc00ab0edc.png)

This problem doesn't happen in 2D or for polygons with a PerInstanceColorMaterial

``` javascript
var czml = [{
"id" : "document",
"name" : "CZML Geometries: Polygon",
"version" : "1.0"
}, {
"polygon" : {
"positions" : {
"cartographicDegrees" : [
-108.0, 25.0, 0,
-100.0, 27.0, 0,
-100.0, 32.0, 0,
-108.0, 30.0, 0
]
},
"height": 0,
"material" : {
"image": {
"image": { "uri": "../images/Cesium_Logo_Color.jpg" }
}
}
}
},{
"polygon" : {
"positions" : {
"cartographicDegrees" : [
-109.0, 26.0, 0,
-101.0, 28.0, 0,
-101.0, 33.0, 0,
-109.0, 31.0, 0
]
},
"height": 0,
"material" : {
"image": {
"image": { "uri": "../images/Cesium_Logo_Color.jpg" }
}
}
}
}];

var viewer = new Cesium.Viewer('cesiumContainer');
var dataSource = Cesium.CzmlDataSource.load(czml);
viewer.dataSources.add(dataSource);
viewer.zoomTo(dataSource);
```

Contributor guide

Open the contributing guide

Research direction

Start by running the supplied Cesium.Viewer and CzmlDataSource.load reproduction with the two overlapping textured polygons, then compare it with 2D and PerInstanceColorMaterial cases. Trace the polygon rendering path from the viewer and determine how completion should be verified: overlapping image-material polygons no longer visibly z-fight.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
computer-graphics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.