Scene.pick returns undefined on latest Chrome on Windows

903 views
Skip to first unread message

Dario Marques

unread,
Mar 16, 2016, 3:47:26 PM3/16/16
to cesium-dev

You can reproduce it on every demo on cesium website, like this one:


http://shinsai.mapping.jp/index_en.html

It works on Opera and Firefox


Google Chrome Version: '49.0.2623.87 m'


scene.pick(click.position) with the click position returns undefined

Hannah Pinkos

unread,
Mar 17, 2016, 10:50:19 AM3/17/16
to cesium-dev
Hello,

I'm not sure what would be causing that problem. Please follow these steps and tell me what happens:

• Run chrome in incognito mode (you can open an incognito window using ctrl+shift+n)
• Replace the code in the left pane with this example:
var viewer = new Cesium.Viewer('cesiumContainer');

var entity = viewer.entities.add({
    position
: Cesium.Cartesian3.fromDegrees(-75.59777, 40.03883),
    billboard
: {
        image
: '../images/Cesium_Logo_overlay.png'
   
}
});

var handler = new Cesium.ScreenSpaceEventHandler(viewer.scene.canvas);
handler
.setInputAction(function(movement) {
   
var pickedObject = viewer.scene.pick(movement.endPosition);
   
if (Cesium.defined(pickedObject) && (pickedObject.id === entity)) {
        entity
.billboard.scale = 2.0;
        entity
.billboard.color = Cesium.Color.YELLOW;
   
} else {
        entity
.billboard.scale = 1.0;
        entity
.billboard.color = Cesium.Color.WHITE;
   
}
}, Cesium.ScreenSpaceEventType.MOUSE_MOVE);


•  Hit the 'Run' button, then mouse over the logo that has been added to the globe.

Does the logo change when you hover over it?  If not, are there any errors in the console?
What OS and graphics card does your computer have?

Thanks

-Hannah

dario....@centrodeoperacoesrio.com.br

unread,
Apr 27, 2016, 4:26:31 PM4/27/16
to cesium-dev
Thank you Hannah.

Unfortunatelly the logo not hover and i get no errors in the javascript console.

Simple nothing occours.

I´m my system i have this code:

var handler = new Cesium.ScreenSpaceEventHandler(scene.canvas);
handler.setInputAction(function(click) {
console.log('clicked!');
var pickedObject = scene.pick(click.position);
console.log(pickedObject);
if (Cesium.defined(pickedObject))
{
.......
}, Cesium.ScreenSpaceEventType.LEFT_CLICK);


Notice that first console.log give me sure Cesium hit the click event, because it return "clicked!" in the console, but the second one returns "undefined" for the pickedObject.

Its Google Chrome updated with last version and i´m using graphic card RADEON HD 6800.

Some totally different machines give the same error, about 5% of all machines we have in our department. Not so much in numeric terms but important machines are not working.

Hannah Pinkos

unread,
Apr 28, 2016, 8:18:22 AM4/28/16
to cesium-dev, dario....@centrodeoperacoesrio.com.br
Very strange, I've never seen that problem before.  Are they Windows, Mac or Linux machines?

-Hannah

kylesj...@gmail.com

unread,
May 9, 2016, 11:40:13 AM5/9/16
to cesium-dev
I get this same exact issue with my latest Chrome (50.0.2661.94m)

Works fine in Firefox, but can't get scene.pick to work in Chrome at all anymore. Even tried the incognito test and it still fails.

No error return, just doesn't pick.

Works fine on other machines in office.

kylesj...@gmail.com

unread,
May 9, 2016, 11:42:36 AM5/9/16
to cesium-dev, kylesj...@gmail.com

I'm in Windows 7 Pro, with a AMD RADEON HD 6350

josia...@gmail.com

unread,
May 9, 2016, 4:32:34 PM5/9/16
to cesium-dev
On Wednesday, March 16, 2016 at 3:47:26 PM UTC-4, Dario Marques wrote:


I'm having the same issue.

Chrome 50.0.2661.94 m (64-bit)

AMD Radeon(TM) HD 8490, driver: 13.351.1007.1006

Matthew Amato

unread,
May 9, 2016, 4:37:10 PM5/9/16
to cesiu...@googlegroups.com
Are you using terrain?  Does it work if you disable terrain?  I think you are running into this bug: https://github.com/AnalyticalGraphicsInc/cesium/pull/3900

Which has been fixed and will be in the next release (1.22 on June 1st)


--
You received this message because you are subscribed to the Google Groups "cesium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cesium-dev+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Message has been deleted

kylesj...@gmail.com

unread,
May 9, 2016, 4:42:00 PM5/9/16
to cesium-dev
Tried disabling terrain and still returns null. But I will be happy to wait for the next release to see if it's fixed anyway!

dario....@centrodeoperacoesrio.com.br

unread,
May 21, 2016, 3:50:24 PM5/21/16
to cesium-dev
in our department we start to solve doing update the video driver and all windows updates.

i'm not sure if this way solve in all machines, i will confirm at monday and let you guys updated.

Shirui Wang

unread,
Oct 16, 2017, 4:31:52 AM10/16/17
to cesium-dev
Hi,

I'm running into the same problem with AMD graphics card.
Any updates for that?
Reply all
Reply to author
Forward
0 new messages