Icon layer is not working anymore after new release of 8.4.2 version #5452
Unanswered
Mayoorshardha
asked this question in
Q&A
Replies: 2 comments 1 reply
-
There was no change in 8.4.2 that affected the IconLayer. The website examples at https://deck.gl/examples/icon-layer/ and https://deck.gl/docs/api-reference/layers/icon-layer are using the latest release. I suggest you revert back to 8.4.1 and see if it indeed is caused by the upgrade of deck.gl. |
Beta Was this translation helpful? Give feedback.
1 reply
-
With deck gl 8.4.3 version release, it got fixed on its own. Now its working fine! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello Everyone!
I am using icon layer for my project and it was working fine up until 8.4.1 version. However, after the update to the deck gl to 8.4.2, the map is rendering however the icons are not showing anymore. I am getting an error of set uniforms is not defined.
I am getting data from an api route and iconmap and iconatlas are imported from my assets folder. Those are fine.
Package.json
"@deck.gl/core": "8.4.2",
"deck.gl": "8.4.2",
"@deck.gl/layers": "8.4.2",
"@deck.gl/react": "8.4.2",
"@luma.gl/core": "8.4.1",
"@luma.gl/engine": "8.4.1",
"@luma.gl/webgl": "8.4.1",
Code:
const MAP_VIEW = new MapView({ repeat: true });
const INITIAL_VIEW_STATE = {
longitude: -95.5698,
latitude: 29.7604,
zoom: 8,
maxZoom: 20,
pitch: 0,
bearing: 0,
};
const mapStyle =
"https://basemaps.cartocdn.com/gl/positron-gl-style/style.json";
const [data, setData] = useState([]);
const layer = new IconLayer({
id: "icon-layer",
getIcon: (d) => "marker",
sizeUnits: "meters",
sizeScale: 2000,
sizeMinPixels: 30,
pickable: true,
getPosition: d => d.coordinates,
getSize: d => 5,
data,
iconAtlas,
iconMapping
});
return (
<DeckGL
width={"100%"}
layers={[layer]}
views={MAP_VIEW}
initialViewState={INITIAL_VIEW_STATE}
controller={true}
getTooltip={getTooltip}
useDevicePixels={false}
>
);
Beta Was this translation helpful? Give feedback.
All reactions