Description
An example of a geojson layer I created where antialiasing normally works:
new GeoJsonLayer({
id: 'lines',
data: linesDisplayGeojson,
getLineColor: getLineColor,
getLineWidth: SUBWAY_TUNNEL_WIDTH * LINE_WIDTH_MODIFIER,
lineWidthMinPixels: MIN_TRACK_PIXEL_WIDTH * LINE_WIDTH_MODIFIER,
lineCapRounded: true,
beforeId: 'buildings-3d',
updateTriggers: {
getLineColor: [hasActiveJourney]
},
}),
But when I update it to:
new GeoJsonLayer({
id: 'lines',
data: linesDisplayGeojson,
getLineColor: getLineColor,
getLineWidth: SUBWAY_TUNNEL_WIDTH * LINE_WIDTH_MODIFIER,
lineWidthMinPixels: MIN_TRACK_PIXEL_WIDTH * LINE_WIDTH_MODIFIER,
lineCapRounded: true,
beforeId: 'buildings-3d',
updateTriggers: {
getLineColor: [hasActiveJourney]
},
getOffset: (f: any) => f.properties.offset,
extensions: [new PathStyleExtension({ offset: true })],
}),
Antialiasing breaks. If I take the code that works and just add
extensions: [new PathStyleExtension()]
It works fine it's just when I pass in the {offset: true} flag that things break.
An image of a line I drew without the offset flag
VS one with it
Flavors
Expected Behavior
No response
Steps to Reproduce
Here's an example of a line I generated:
test.json
Environment
- Framework version:
"@deck.gl/core": "^9.0.38",
"@deck.gl/geo-layers": "^9.0.38",
"@deck.gl/layers": "^9.0.38",
"@deck.gl/mapbox": "^9.0.38",
"@deck.gl/react": "^9.0.38",
"maplibre-gl": "^4.7.0",
"react-map-gl": "^7.1.7"
- Browser: Chrome
- OS: MacOS 15.1.1 (24B91)
Logs
No response
Description
An example of a geojson layer I created where antialiasing normally works:
new GeoJsonLayer({
id: 'lines',
data: linesDisplayGeojson,
getLineColor: getLineColor,
getLineWidth: SUBWAY_TUNNEL_WIDTH * LINE_WIDTH_MODIFIER,
lineWidthMinPixels: MIN_TRACK_PIXEL_WIDTH * LINE_WIDTH_MODIFIER,
lineCapRounded: true,
beforeId: 'buildings-3d',
updateTriggers: {
getLineColor: [hasActiveJourney]
},
}),
But when I update it to:
new GeoJsonLayer({
id: 'lines',
data: linesDisplayGeojson,
getLineColor: getLineColor,
getLineWidth: SUBWAY_TUNNEL_WIDTH * LINE_WIDTH_MODIFIER,
lineWidthMinPixels: MIN_TRACK_PIXEL_WIDTH * LINE_WIDTH_MODIFIER,
lineCapRounded: true,
beforeId: 'buildings-3d',
updateTriggers: {
getLineColor: [hasActiveJourney]
},
getOffset: (f: any) => f.properties.offset,
extensions: [new PathStyleExtension({ offset: true })],
}),
Antialiasing breaks. If I take the code that works and just add
extensions: [new PathStyleExtension()]It works fine it's just when I pass in the
{offset: true}flag that things break.An image of a line I drew without the offset flag
VS one with it
Flavors
Expected Behavior
No response
Steps to Reproduce
Here's an example of a line I generated:
test.json
Environment
"@deck.gl/core": "^9.0.38",
"@deck.gl/geo-layers": "^9.0.38",
"@deck.gl/layers": "^9.0.38",
"@deck.gl/mapbox": "^9.0.38",
"@deck.gl/react": "^9.0.38",
"maplibre-gl": "^4.7.0",
"react-map-gl": "^7.1.7"
Logs
No response