Jump to content

multi-views and scene.pick


Dad72
 Share

Recommended Posts

Hi,

 

1 - It may be a bug, but when I have two viewpoint, I can no longer click on the objects in the scene with scene.pick( ). as if the viewpoint 2 (mini-map) had covered the entirety of the canvas by over the scene.

 

2- It would be useful to have also the possibility of deleted a point of view of the scene. For exemple, I selected on camera 2 (with Gizmo), it shows me one points of view of this camera, if I selected a box, I deleted this point of view of the camera 2. But I have not succeeded in tested this, because the objects are no longer selectable as I pointed out in this post.

 

Thank you Deltakosh

Link to comment
Share on other sites

Here are the examples. The 2 scenes on a scene.pick() with an alert() when you click on a box.

 

The first scene is with the multi-views and if you click on a box, nothing this past.
Scene 1

 

The next scene is exactly the same without the multi-view and if you click on a box, you will get the alert( 'Box selected: Ok').
Scene 2

Link to comment
Share on other sites

I've just pushed a bug fix on github.

Now the scene.pick has the following signature:

 

   
 BABYLON.Scene.prototype.pick = function (x, y, predicate, fastCheck, camera) {        /// <summary>Launch a ray to try to pick a mesh in the scene</summary>        /// <param name="x">X position on screen</param>        /// <param name="y">Y position on screen</param>        /// <param name="predicate">Predicate function used to determine eligible meshes. Can be set to null. In this case, a mesh must be enabled, visible and with isPickable set to true</param>        /// <param name="fastCheck">Launch a fast check only using the bounding boxes. Can be set to null.</param>        /// <param name="camera">camera to use for computing the picking ray. Can be set to null. In this case, the scene.activeCamera will be used</param>
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...