x3dom / apps-modeling

Publicly Available Applications
Other
3 stars 3 forks source link

lost of mouse interactions and selection on primitives #112

Closed chmouton closed 10 years ago

chmouton commented 10 years ago

this text to track this strange issue: some models of laptops and desktops used at EDF present different behaviors for the mouse interactions on primitives both on Firefox 24.0 and Google Chrome 29.0.1547.76 m with windows 7 32bit.

The bug is : once the drag&drop of the primitive (box, cylinder, whatever...) is done, the mouse interactions are restricted or switched automatically to the navigation mode : the complete scene is moving and not the primitive only. The cursor of the mouse is always an "hand" and never a "cross" like in the normal way of use. You can't also select in yellow an other primitive. You have to go in the ThreeView to select the primitive yu want and sometimes even there, you can't select the primitive. If you try to change the mode with clicking on the icons to the rotation, translation mode, only the panel at the bottom is refreshed and you stay in the navigation mode.

This bug appears on this first list of laptops and desktops used at EDF : HP probook 6460b, HP EliteBook 2560p.

The bug doesn't appear on this other list of laptops and desktops: HP Probook 6450b, HP Probook 6530b, HP Z600

yjung commented 10 years ago

No idea, never happened to us, but since at the current stage this is a prototypical demonstrator, we can postpone debugging and show the application on a working machine.

mlimper commented 10 years ago

@yjung Can we extract a specific problem out of this description, so that we could maybe just google for it for now? Maybe others also had similar issues...

@chmouton Do I understand you correctly that this only occurs after drop events?

chmouton commented 10 years ago

@mlimper the scene is always empty when I start the component editor. The drag&drop of primitives works fine: the primitive is right where your cursor let it on the scene but after that, only navigation mode is possible and mouse picking on a primitive in the scene is not possible.

yjung commented 10 years ago

Seems like on certain environments drag&drop eats up a relevant mouse event. However, without ability to really debug this issue live, this is digging in the dust and might thus break other things, which we don't want. Perhaps @chmouton can send us a machine where this happens so we can test and fix.

yjung commented 10 years ago

And the dev tool's console doesn't say something like "xxx is undefined"?

chmouton commented 10 years ago

In the Firefox browser console there are only these few lines: [12:35:20.047] Unknown property 'box-sizing'. Declaration dropped. @ http://x3dom.org/editor/editor/component_editor/ [12:35:20.454] Use of Mutation Events is deprecated. Use MutationObserver instead. @ http://x3dom.org/x3dom/src/X3DCanvas.js:314 [12:35:21.499] Error in parsing value for 'height'. Declaration dropped. @ http://x3dom.org/editor/editor/component_editor/ [12:35:21.500] "12:35:21.500 - Dynatree._create(): version='$Version: 1.2.4$', debugLevel=" 1 "." [12:35:22.416] Use of getPreventDefault() is deprecated. Use defaultPrevented instead. @ http://x3dom.org/editor/editor/static/ext/jquery-1.9.1.js:3346

yjung commented 10 years ago

I get the same output, it's harmless, but maybe an update to a newer jQuery version might help, but don't know?!

yjung commented 10 years ago

BTW, you can also create objects by clicking with the right mouse button onto the grid. Does this work for you?

yjung commented 10 years ago

Just checked it with the oldest hardware I found: Core2 CPU T5600 @ 1.83 GHz and 1 GB RAM with Mobile Intel 945 Express Chipset graphics card, and Firefox 24, and even there everything worked as expected. Very strange...

chmouton commented 10 years ago

I can show you in live what happens with our webconference system

yjung commented 10 years ago

Sorry, I'm on vacation today, the blacksmith comes at two.

yjung commented 10 years ago

Added some additional callbacks, could you please check again (and don't forget to clear the Cache)?

chmouton commented 10 years ago

Still the same issue: Max told me to use the key "D", there are two red lines in the X3DOM console and no object in the black square at the top-left corner of the 3D scene.

20130926-capture01

chmouton commented 10 years ago

With this x3dom example, no popup with ID and coordinates: http://x3dom.org/x3dom/test/functional/geoPrimitives.xhtml

20130926-capture02 log here: INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: New camera position: 0 0 15

INFO: New center of Rotation: 0 0 0

INFO: position: 0 0 15 orientation: 0 0 0 0

INFO: Time for setup and init of GL element no. 1: 293 ms.

INFO: activate FogBindable null/defaultX3DFogNode

INFO: register FogBindable null/defaultX3DFogNode

INFO: create new Fog for X3DFogNode-stack

INFO: activate ViewpointBindable anotherView/

INFO: activate first X3DViewpointNode for X3DViewpointNode-stack

INFO: activate BackgroundBindable null/

INFO: activate first X3DBackgroundNode for X3DBackgroundNode-stack

INFO: System ready.

INFO: activate NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: register NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: NavType: examine

INFO: create new NavigationInfo for X3DNavigationInfoNode-stack

INFO: activate EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: register EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: create new Environment for X3DEnvironmentNode-stack

INFO: register BackgroundBindable null/

INFO: register ViewpointBindable anotherView/

INFO: addEventListener for X3D.onDOMNodeInserted

INFO: addEventListener for X3D.onDOMNodeRemoved

INFO: Vendor: Mozilla, Renderer: Mozilla, Version: WebGL 1.0, ShadingLangV.: WebGL GLSL ES 1.0, MSAA samples: 4 Extensions: OES_element_index_uint,OES_texture_float,OES_texture_float_linear,OES_standard_derivatives,EXT_texture_filter_anisotropic,MOZ_WEBGL_lose_context,WEBGL_lose_context,MOZ_WEBGL_compressed_texture_s3tc,WEBGL_compressed_texture_s3tc

INFO: Initializing X3DCanvas for [x3dom-spheres-canvas]

INFO: Inline X3D styles detected

INFO: Creating canvas for (X)3D element...

INFO: Time for setup and init of GL element no. 0: 628 ms.

INFO: activate FogBindable null/defaultX3DFogNode

INFO: register FogBindable null/defaultX3DFogNode

INFO: create new Fog for X3DFogNode-stack

INFO: activate ViewpointBindable aView/

INFO: activate first X3DViewpointNode for X3DViewpointNode-stack

INFO: activate BackgroundBindable null/

INFO: activate first X3DBackgroundNode for X3DBackgroundNode-stack

INFO: System ready.

INFO: activate NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: register NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: NavType: examine

INFO: create new NavigationInfo for X3DNavigationInfoNode-stack

INFO: activate EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: register EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: create new Environment for X3DEnvironmentNode-stack

INFO: register ViewpointBindable aView/

INFO: register BackgroundBindable null/

INFO: addEventListener for X3D.onDOMNodeInserted

INFO: addEventListener for X3D.onDOMNodeRemoved

INFO: Vendor: Mozilla, Renderer: Mozilla, Version: WebGL 1.0, ShadingLangV.: WebGL GLSL ES 1.0, MSAA samples: 4 Extensions: OES_element_index_uint,OES_texture_float,OES_texture_float_linear,OES_standard_derivatives,EXT_texture_filter_anisotropic,MOZ_WEBGL_lose_context,WEBGL_lose_context,MOZ_WEBGL_compressed_texture_s3tc,WEBGL_compressed_texture_s3tc

INFO: Initializing X3DCanvas for [x3dom-boxes-canvas]

INFO: onmouseup, stop(event);

INFO: onmousemove, move(event);

INFO: onmousedown, start(event);

INFO: Inline X3D styles detected

INFO: Creating canvas for (X)3D element...

INFO: Found 2 X3D and 0 (experimental) WebSG nodes...

chmouton commented 10 years ago

but on this one, it works very nicely: http://x3dom.org/x3dom/test/functional/autoTest.xhtml

20130926-capture03 INFO: Ray hit at position 151 43 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 191 75 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 238 83 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 20 84 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 240 71 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 18 84 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 25 78 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 31 73 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 103 71 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 169 100 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 208 79 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 228 53 0

INFO: Hit "Shape/ clickShape"

INFO: Ray hit at position 147 67 0

INFO: Hit "Shape/ clickShape"

INFO: Time for setup and init of GL element no. 0: 334 ms.

INFO: activate FogBindable null/defaultX3DFogNode

INFO: register FogBindable null/defaultX3DFogNode

INFO: create new Fog for X3DFogNode-stack

INFO: activate ViewpointBindable null/

INFO: activate first X3DViewpointNode for X3DViewpointNode-stack

INFO: activate BackgroundBindable null/

INFO: activate first X3DBackgroundNode for X3DBackgroundNode-stack

INFO: System ready.

INFO: activate NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: register NavigationInfoBindable null/defaultX3DNavigationInfoNode

INFO: NavType: examine

INFO: create new NavigationInfo for X3DNavigationInfoNode-stack

INFO: activate EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: register EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: create new Environment for X3DEnvironmentNode-stack

INFO: Current ComposedShader node implementation limitations: Vertex attributes (if given in the standard X3D fields 'coord', 'color', 'normal', 'texCoord'), matrices and texture are provided as follows... (see also http://x3dom.org/x3dom/doc/help/composedShader.html) attribute vec3 position; attribute vec3 normal; attribute vec2 texcoord; attribute vec3 color; uniform mat4 modelViewProjectionMatrix; uniform mat4 modelViewMatrix; uniform mat4 normalMatrix; uniform mat4 viewMatrix; uniform sampler2D tex;

INFO: register ViewpointBindable null/

INFO: register BackgroundBindable null/

INFO: addEventListener for X3D.onDOMNodeInserted

INFO: addEventListener for X3D.onDOMNodeRemoved

INFO: Vendor: Mozilla, Renderer: Mozilla, Version: WebGL 1.0, ShadingLangV.: WebGL GLSL ES 1.0, MSAA samples: 4 Extensions: OES_element_index_uint,OES_texture_float,OES_texture_float_linear,OES_standard_derivatives,EXT_texture_filter_anisotropic,MOZ_WEBGL_lose_context,WEBGL_lose_context,MOZ_WEBGL_compressed_texture_s3tc,WEBGL_compressed_texture_s3tc

INFO: Initializing X3DCanvas for [x3dom-someUniqueId-canvas]

INFO: Creating canvas for (X)3D element...

INFO: Found 1 X3D and 0 (experimental) WebSG

yjung commented 10 years ago

Maybe a security issue? Have you checked the Browser settings?

chmouton commented 10 years ago

It works perfectly on some other models of laptops and desktops at EDF even the GeoPrimitives example.

Le 26 sept. 2013 à 21:01, Yvonne Jung notifications@github.com a écrit :

Maybe a security issue? Have you checked the Browser settings?

— Reply to this email directly or view it on GitHub.

yjung commented 10 years ago

The problem is that I simply cannot reproduce this issue, though I tested with all relevant browsers on several desktops and laptops (even on my sister's very old machine). There must be some strange settings or whatever on your machines, I just don't have any other idea. Did you click on something in the geoPrimitives test, and did. something happen then?

chmouton commented 10 years ago

No popup or message window when I click on the primitives on my computer. But it works perfectly on the others computers who run right the component editor.

Le 26 sept. 2013 à 21:25, Yvonne Jung notifications@github.com a écrit :

The problem is that I simply cannot reproduce this issue, though I tested with all relevant browsers on several desktops and laptops (even on my sister's very old machine). There must be some strange settings or whatever on your machines, I just don't have any other idea. Did you click on something in the geoPrimitives test, and did. something happen then?

— Reply to this email directly or view it on GitHub.

yjung commented 10 years ago

What are the red lines you mentioned?

yjung commented 10 years ago

And what is the output of this page? http://www.x3dom.org/check/details/

chmouton commented 10 years ago

These two lines are in red when D is active in the component editor: WARNING: No primitive with id "" found!

WARNING: No primitive with id "" found!

20130926-capture04 20130926-capture05

yjung commented 10 years ago

Should be there only once, but is harmless. What says the check/details page mentioned above?

chmouton commented 10 years ago

Please find the two reports for the check/details page.

----- Mail original ----- De: "Yvonne Jung" notifications@github.com À: "x3dom/apps-modeling" apps-modeling@noreply.github.com Cc: "chmouton" christophe.mouton@free.fr Envoyé: Jeudi 26 Septembre 2013 22:06:44 Objet: Re: [apps-modeling] lost of mouse interactions and selection on primitives (#112)

Should be there only once, but is harmless. What says the check/details page mentioned above?

— Reply to this email directly or view it on GitHub .

yjung commented 10 years ago

We can try switching to mobile shaders, seems the pickbuffer shader is too big. This also occurs without drag drop, when just clicking a primitive image as in the early version? Does the shadow example work?

chmouton commented 10 years ago

Yes it's the same issue with only one click on the primitive image. Could you give me the link of the shadow example?

yjung commented 10 years ago

If my assumption was true, then the editor should now work for you (please clear cache and reload). If not, here the shadow examples: http://x3dom.org/x3dom/test/functional/animatedLights.xhtml http://x3dom.org/x3dom/test/functional/geoPrimitivesTexture.xhtml

chmouton commented 10 years ago

It's still the same behaviour but with this new red line in the D console: "WARNING: Detected mobile graphics card! Using low quality shaders without ImageGeometry support!"


INFO: addEventListener for X3D.ontouchend

INFO: addEventListener for X3D.ontouchmove

INFO: addEventListener for X3D.ontouchstart

INFO: addEventListener for X3D.onMozTouchUp

INFO: addEventListener for X3D.onMozTouchMove

INFO: addEventListener for X3D.onMozTouchDown

INFO: addEventListener for X3D.onmousemove

INFO: addEventListener for X3D.onmouseout

INFO: addEventListener for X3D.onmouseup

INFO: Inline: added x3d/axis.x3d to scene.

INFO: setBaseURL: x3d/

INFO: Inline: downloading x3d/axis.x3d done.

WARNING: No primitive with id "" found!

WARNING: No primitive with id "" found!

INFO: Time for setup and init of GL element no. 0: 369 ms.

INFO: activate FogBindable null/defaultX3DFogNode

INFO: register FogBindable null/defaultX3DFogNode

INFO: create new Fog for X3DFogNode-stack

INFO: activate ViewpointBindable viewPoint/

INFO: activate first X3DViewpointNode for X3DViewpointNode-stack

INFO: activate BackgroundBindable null/defaultX3DBackgroundNode

INFO: register BackgroundBindable null/defaultX3DBackgroundNode

INFO: create new Background for X3DBackgroundNode-stack

INFO: System ready.

INFO: activate NavigationInfoBindable navi/

INFO: activate first X3DNavigationInfoNode for X3DNavigationInfoNode-stack

INFO: activate EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: register EnvironmentBindable null/defaultX3DEnvironmentNode

INFO: create new Environment for X3DEnvironmentNode-stack

INFO: register NavigationInfoBindable navi/

INFO: NavType: examine

INFO: register OrthoViewpointBindable orthoViewPointRight/

INFO: register OrthoViewpointBindable orthoViewPointLeft/

INFO: register OrthoViewpointBindable orthoViewPointBottom/

INFO: register OrthoViewpointBindable orthoViewPointTop/

INFO: register OrthoViewpointBindable orthoViewPointBack/

INFO: register OrthoViewpointBindable orthoViewPointFront/

INFO: register ViewpointBindable viewPoint/

INFO: addEventListener for X3D.onDOMNodeInserted

INFO: addEventListener for X3D.onDOMNodeRemoved

WARNING: Detected mobile graphics card! Using low quality shaders without ImageGeometry support!

INFO: Vendor: Mozilla, Renderer: Mozilla, Version: WebGL 1.0, ShadingLangV.: WebGL GLSL ES 1.0, MSAA samples: 4 Extensions: OES_element_index_uint,OES_texture_float,OES_texture_float_linear,OES_standard_derivatives,EXT_texture_filter_anisotropic,MOZ_WEBGL_lose_context,WEBGL_lose_context,MOZ_WEBGL_compressed_texture_s3tc,WEBGL_compressed_texture_s3tc

INFO: Initializing X3DCanvas for [x3dom-x3d-canvas]

INFO: ondragover, controller.allowDrop(event)

INFO: ondrop, controller.drop(event)

INFO: onkeydown, if ((event || window.event).keyCode == 46){ primitiveManager.removeCurrentObject(); /46 = DEL/ }

INFO: Creating canvas for (X)3D element...

INFO: Found 1 X3D and 0 (experimental) WebSG nodes...

chmouton commented 10 years ago

This one looks strange : http://x3dom.org/x3dom/test/functional/animatedLights.xhtml

20130926-capture06

chmouton commented 10 years ago

For the other one, it looks better; http://x3dom.org/x3dom/test/functional/geoPrimitivesTexture.xhtml

20130926-capture07

yjung commented 10 years ago

But without shadows...

yjung commented 10 years ago

Looks like FBO issues, shadows are broken, too. Very strange...

yjung commented 10 years ago

Maybe it's the buffer size. Would you please try again the following two examples which are now of POT size? http://x3dom.org/x3dom/test/functional/geoPrimitives.xhtml http://x3dom.org/x3dom/test/functional/geoPrimitivesTexture.xhtml

chmouton commented 10 years ago

Fro the example : http://x3dom.org/x3dom/test/functional/geoPrimitivesTexture.xhtml

the X3DOM log is

INFO: New camera position: -3.132444576072132 11.583108131714468 -0.13927306576101856 INFO: New center of Rotation: 0 0 0 INFO: New camera position: -3.1324445760721322 11.58310813171447 -0.13927306576101853 INFO: New center of Rotation: 0 0 0 INFO: New camera position: 0 0 12 INFO: New center of Rotation: 0 0 0 INFO: Time for setup and init of GL element no. 0: 373 ms. INFO: activate FogBindable null/defaultX3DFogNode INFO: register FogBindable null/defaultX3DFogNode INFO: create new Fog for X3DFogNode-stack INFO: activate ViewpointBindable null/ INFO: activate first X3DViewpointNode for X3DViewpointNode-stack INFO: activate BackgroundBindable null/ INFO: activate first X3DBackgroundNode for X3DBackgroundNode-stack INFO: System ready. INFO: activate NavigationInfoBindable null/defaultX3DNavigationInfoNode INFO: register NavigationInfoBindable null/defaultX3DNavigationInfoNode INFO: NavType: examine INFO: create new NavigationInfo for X3DNavigationInfoNode-stack INFO: activate EnvironmentBindable null/defaultX3DEnvironmentNode INFO: register EnvironmentBindable null/defaultX3DEnvironmentNode INFO: create new Environment for X3DEnvironmentNode-stack INFO: register ViewpointBindable null/ WARNING: Fallback to inefficient multi-index mode since creaseAngle=0. INFO: register BackgroundBindable null/ INFO: addEventListener for X3D.onDOMNodeInserted INFO: addEventListener for X3D.onDOMNodeRemoved WARNING: Detected mobile graphics card! But being forced to desktop shaders which might not work! INFO: Vendor: WebKit, Renderer: WebKit WebGL, Version: WebGL 1.0 (OpenGL ES 2.0 Chromium), ShadingLangV.: WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium), MSAA samples: 4 Extensions: WEBKIT_EXT_texture_filter_anisotropic,OES_element_index_uint,OES_standard_derivatives,OES_texture_float,OES_texture_float_linear,OES_texture_half_float,OES_texture_half_float_linear,OES_vertex_array_object,WEBKIT_WEBGL_compressed_texture_s3tc,WEBKIT_WEBGL_depth_texture,WEBGL_lose_context INFO: Initializing X3DCanvas for [x3dom-boxes-canvas] INFO: Creating canvas for (X)3D element... INFO: Found 1 X3D and 0 (experimental) WebSG nodes...

----- Mail original ----- De: "Yvonne Jung" notifications@github.com À: "x3dom/apps-modeling" apps-modeling@noreply.github.com Cc: "chmouton" christophe.mouton@free.fr Envoyé: Vendredi 27 Septembre 2013 11:49:34 Objet: Re: [apps-modeling] lost of mouse interactions and selection on primitives (#112)

Maybe it's the buffer size. Would you please try again the following two examples which are now of POT size? http://x3dom.org/x3dom/test/functional/geoPrimitives.xhtml http://x3dom.org/x3dom/test/functional/geoPrimitivesTexture.xhtml

— Reply to this email directly or view it on GitHub .

yjung commented 10 years ago

Does it work or not?

chmouton commented 10 years ago

No message window for GeoPrimitives and still "test" instead of "box.isOver etc." No shadow and no "Ray hit at position etc." for geoPrimitivesTexture

----- Mail original ----- De: "Yvonne Jung" notifications@github.com À: "x3dom/apps-modeling" apps-modeling@noreply.github.com Cc: "chmouton" christophe.mouton@free.fr Envoyé: Vendredi 27 Septembre 2013 12:17:11 Objet: Re: [apps-modeling] lost of mouse interactions and selection on primitives (#112)

Does it work or not?

— Reply to this email directly or view it on GitHub .

yjung commented 10 years ago

Have you tried a graphics driver update?

yjung commented 10 years ago

As a very last idea I've now disabled touch for the component editor, just for testing, could you please try again: http://www.x3dom.org/editor/editor/component_editor/

chmouton commented 10 years ago

Dear Yvonne,

still the same issue, no improvement :(

Le 28 sept. 2013 à 12:38, Yvonne Jung notifications@github.com a écrit :

As a very last idea I've now disabled touch for the component editor, just for testing, could you please try again: http://www.x3dom.org/editor/editor/component_editor/

— Reply to this email directly or view it on GitHub.

yjung commented 10 years ago

Would it be possible to send us a machine where this happens? Because I have no more ideas, and I just can't reproduce this error.