Why GraphicsLayer points opacity not working

04-29-2021 03:13 AM
New Contributor

Hi, i'm trying to add some symbols(picture/simple marker) on the map and wants to make their opacity=1.

For some reason the Basemap elements (roads and buildings) shows behind those symbols.

I've tried some solutions like:

graphicsLayer.opacity = 1;

but still the same problem.

Its happens only when i'm using a PortalItem as my basemap:

let portalItem = new PortalItem({
id: "4f2e99ba65e34bb8af49733d9778fb8e",
let basemap = new Basemap({
portalItem: portalItem,
var map = new Map({
basemap: basemap,

Is anyone can help me with that?

Also If there's any other correct way to use that basemap i'd like to know.


0 Kudos
2 Replies
Frequent Contributor II

What does the symbols for your graphics look like? If you are using rgba values for the color, that will add transparency to those graphics on the map. 

0 Kudos
New Contributor

Hi, for now i'm trying to add a  a picture-marker as my symbol, PNG type, with no transparency.

Also when I tried a simple-marker it was only a color value ('red' for example) and not RGB, both acts the same.

I think its all about the Basemap. when I'm using another ID it looks ok. is that making any sense? if so, there is another way to use it? thanks.


0 Kudos