Cesium: Picking priority

Created on 31 Mar 2014  路  13Comments  路  Source: CesiumGS/cesium

It would be a useful addition to CZML for objects to have a "picking priority" of some sort. @mramato and I discussed possibly an enum (High, Default, Low, None) or a number (where 1 is default, and 0 means don't pick). The viewerDynamicObjectMixin would drill-pick and take the highest-priority pickable object as the picked object.

This feature would be useful for scenes that have a lot of sensor cones, or a single very large sensor cone, for example. The cone(s) can contain multiple objects, and the user may be more interested in picking the interior objects than the cone itself. The cone would get "low" priority (but not un-pickable) and would only get picked if there were no other objects under the mouse.

category - picking priority - high type - enhancement

Most helpful comment

This is something that gets requested in the forum frequently.

https://groups.google.com/forum/?hl=en#!topic/cesium-dev/0XA8qWPQfRE
https://groups.google.com/d/msg/cesium-dev/agtOrHYEhUo/lGlFb5q4EQAJ

All 13 comments

I recently encountered a use case where I needed this feature as well. I have a CZML with a polyline showing a route and points drawn at each stop. The points are intended to be picked to show the description in the info box, but frequently the pick ends up returning the polyline instead of the point. In my case, I never need to pick the polyline itself.

yep us too.. we're making a measuring tool and it doesn't make any sense that the vertex markers or line are clickable.

This is something that gets requested in the forum frequently.

https://groups.google.com/forum/?hl=en#!topic/cesium-dev/0XA8qWPQfRE
https://groups.google.com/d/msg/cesium-dev/agtOrHYEhUo/lGlFb5q4EQAJ

+1

I'm going to work on this right now. Should have a PR by tomorrow.

Thanks @dwhipps! This has been a frequently requested feature, I think a lot of people will be happy to see this added

This came up again on the forum: https://groups.google.com/forum/?hl=en#!topic/cesium-dev/wO_LHnTsmJs

Any news on this?

@svenvarennes no update on this beyond what is in #4410. Feel free to test, review, and chime in on that PR.

Also requested by @githubhanjunjun in #7623

Requested again here: https://groups.google.com/d/msg/cesium-dev/NojRg2rnfUg/JwMkEqkQAwAJ

I have a geojson file which i load as a baselayer using viewer.datasource and have several other geojsons that load on top of the baselayer. I want to make the baselayer geojson file not be selected when clicking on the polygon and being shown in the cesium info box. Is there a way to do so.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

OmarShehata picture OmarShehata  路  4Comments

lilleyse picture lilleyse  路  4Comments

puckey picture puckey  路  4Comments

thw0rted picture thw0rted  路  4Comments

worlddai picture worlddai  路  3Comments