Having a hard time displaying entity description

1. A concise explanation of the problem you’re experiencing.

Hello, so I want to display information on entities in my entity pool. I was thinking of using the description property. From the sandbox examples, it seems that clicking on an entity should trigger a showing of the entity’s name and description. My entities don’t display either when clicked on.

2. A minimal code example. If you’ve found a bug, this helps us reproduce and repair it.

var temp = {

id : ren_guid,

position : Cesium.Cartesian3.fromDegrees(lon, lat),

show: true,

billboard : {

image : img_ent,

color : color_ent,

show : true,

width : width_ent,

height : height_ent

},

label : {

text : ren_name,

font : ‘10pt monospace’,

fillColor: color_text,

style : Cesium.LabelStyle.FILL_AND_OUTLINE,

outlineWidth : 2,

verticalOrigin : Cesium.VerticalOrigin.BOTTOM,

pixelOffset : new Cesium.Cartesian2(0, -9)

}

}

temp.name = ‘ren_guid’

temp.description = “hi this is a test!”

return temp

This temp value is returned to a variable which is then added to a collection of entities.

I do currently have a clickhandler for each entity. Essentially, the entity is clicked which raises a selected flag which then triggers actions to draw a selected icon over the selected entity in the cesium viewer.

3. Context. Why do you need to do this? We might know a better way to accomplish your goal.

I would like to have the entity configured such that when I read in specific data on said entity, the data corresponding to the entity will display directly on the cesium viewer or clicking and showing a box that displays the data works fine as well.

4. The Cesium version you’re using, your operating system and browser.

I’m using Cesium 1.15 on linux. My browser is Chrome.

As long as the description and name are set on the entity and that gets added with viewer.entities.add(temp), then it should work. Can you show how you’re adding the entity to the scene? Are you able reproduce this issue in Sandcastle (https://cesiumjs.org/Cesium/Build/Apps/Sandcastle/) ? That’d help determine if it’s a bug or if there’s something else going on.