Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-89385

View3D.pick doesn't work on custom geometry

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 6.0.1, 6.1.0
    • 6.0.0
    • Quick: 3D
    • None
    • Arch Linux 5.9.13
    • Linux/X11
    • 3
    • fc5b1f8c1967d2e9f0b6fe98c59b0573b5ddfb0a (qt/qtquick3d/6.0) 4d5d7750e8ea7d7cd99b7568ab70a7a2314dbb5f (qt/qtquick3d/dev)
    • Qt Quick 3D - 51/52, Qt Quick 3D - 2021 - Weeks 1/2

    Description

      It appears that the function View3D.pick doesn't work when the Model to be picked uses custom geometry via QQuick3DGeometry, regardless of whether or not pickable: true is set on the Model. I have attached a modified version of the main.qml file from the customgeometry example from QtQuick3D with the following changes:

       

      • Added a sphere which uses the built-in geometry #Sphere geometry.
      • Made the default mesh type a custom triangle and made the triangle pickable.
      • Added a MouseArea that calls View3D on left mouse click and prints the result to the console.

       

      If you left click on the sphere the 3D position on the sphere corresponding to where you clicked will be printed in the console. If you left click on the triangle the origin position will be printed instead, the same as if you had left clicked on the background of the scene.

      Attachments

        Activity

          People

            janichol Andy Nichols
            ai2 Ai Kizuna
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: