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

It is not possible to hide the scene node

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P2: Important P2: Important
    • 5.15.4, 6.0.0 RC
    • 5.12.4
    • Quick: 3D
    • None
    • Windows
    • 779379f2d3df4d11f1bf7ee7c84b77b3aecfc545 (qt/qtquick3d/5.15)

      When setting the visible property of the root node to false, while the application is running nothing happens.

      Example:

      import QtQuick 2.12
      import QtQuick.Window 2.12
      import QtQuick3D 1.0
      import Qt.labs.calendar 1.0
      import QtQuick.Controls 2.3
      
      Item {
          id: window
          width: 1280
          height: 720
      
          View3D {
              id: view
              anchors.fill: parent
      
      
              Node {
                  id: scene
      
               
                  Light {
                      id: directionalLight
                  }
      
                  Camera {
                      id: camera
      
                      z: -600
                  }
      
                  Electriccar_27k { /* Could be anything */
                      id: cubeModel
                      visible: checkBox.checked
      
                   
                  }
              }
      
              CheckBox {
                  id: checkBox
                  x: 8
                  y: 15
                  text: qsTr("Check Box")
                  checked: true
              }
          }
      }
      

      Expected Outcome:
      When I uncheck the checkbox (When running the project) the model the car/cube/scene should become invisble.
      Current Outcome:
      Nothing happens

      This is expected to work when we 'live edit' the scene in the tooling.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            janichol Andy Nichols
            thohartm Thomas Hartmann
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes