Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Overlapped Surface3D and Scatter3D
Forum Update on Monday, May 27th 2025

Overlapped Surface3D and Scatter3D

Scheduled Pinned Locked Moved Solved QML and Qt Quick
8 Posts 3 Posters 2.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Davide87
    wrote on last edited by Davide87
    #1

    Hello everyone

    I recently asked some questions about data visualization via different methods. Then I choose to try the QML way.
    However, I got another problem. I tried looking for solutions on the web for days and I could not find anything useful even for such "simple" problem.

    I have got my Surface3D qml object with its Surface3DSeries and ItemModelSurfaceDataProxy and the surface is well drawn. Now I want to draw on such surface a few points like in a scatter plot (or like the selection point that appears in the qml surface examples, but more than one).

    If I draw the Surface3D and then create a Scatter3D object on top of that, the Surface3D will not be visible anymore.
    If I insert a Scatter3DSeries within the Surface3D object, the complier will give an error because a Scatter3DSeries cannot be used in a Surface3D .
    If I try to put a ItemModelScatterDataProxy into the Surface3DSeries after the ItemModelSurfaceDataProxy, the points will not appear.

    In the examples I could not find any case of surface and scatter objects overlapped.

    Can anyone help me on this Nth problem?
    Thank you in advance.

    DiracsbracketD 1 Reply Last reply
    0
    • D Offline
      D Offline
      Davide87
      wrote on last edited by
      #2

      Anyone? :-(
      Is it even possible to draw a Surface3D and a Scatter3D within the same axis?

      1 Reply Last reply
      0
      • D Offline
        D Offline
        Davide87
        wrote on last edited by
        #3

        Last up :-(

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Hi,

          Sorry nobody can help you with your situation.

          You should try to post it on the interest mailing list. You'll find there Qt's developers/maintainers. This forum is more user oriented.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • D Davide87

            Hello everyone

            I recently asked some questions about data visualization via different methods. Then I choose to try the QML way.
            However, I got another problem. I tried looking for solutions on the web for days and I could not find anything useful even for such "simple" problem.

            I have got my Surface3D qml object with its Surface3DSeries and ItemModelSurfaceDataProxy and the surface is well drawn. Now I want to draw on such surface a few points like in a scatter plot (or like the selection point that appears in the qml surface examples, but more than one).

            If I draw the Surface3D and then create a Scatter3D object on top of that, the Surface3D will not be visible anymore.
            If I insert a Scatter3DSeries within the Surface3D object, the complier will give an error because a Scatter3DSeries cannot be used in a Surface3D .
            If I try to put a ItemModelScatterDataProxy into the Surface3DSeries after the ItemModelSurfaceDataProxy, the points will not appear.

            In the examples I could not find any case of surface and scatter objects overlapped.

            Can anyone help me on this Nth problem?
            Thank you in advance.

            DiracsbracketD Offline
            DiracsbracketD Offline
            Diracsbracket
            wrote on last edited by Diracsbracket
            #5

            Hi @Davide87
            A little bit late, but since you mention you only need to add a few scatter points to the surface, I believe you could try with Q3DSurface instead of QML's Surface3D type and use the addCustomItem method to add custom mesh-objects. In the Qt example below, these custom items are an "oil rig" and "refinery".

            https://doc.qt.io/qt-5.9/qtdatavisualization-customitems-example.html

            You could define your own mesh object to be a small sphere that you would place at your scatter point positions.

            All that is not very elegant, of course, but it could help you out.

            D 1 Reply Last reply
            1
            • DiracsbracketD Diracsbracket

              Hi @Davide87
              A little bit late, but since you mention you only need to add a few scatter points to the surface, I believe you could try with Q3DSurface instead of QML's Surface3D type and use the addCustomItem method to add custom mesh-objects. In the Qt example below, these custom items are an "oil rig" and "refinery".

              https://doc.qt.io/qt-5.9/qtdatavisualization-customitems-example.html

              You could define your own mesh object to be a small sphere that you would place at your scatter point positions.

              All that is not very elegant, of course, but it could help you out.

              D Offline
              D Offline
              Davide87
              wrote on last edited by
              #6

              @SGaist Thank you. I wrote to that mailing list, but unfortunately no one answered me :-(

              @Diracsbracket I'll try it and let you know. Thanks.

              1 Reply Last reply
              0
              • D Offline
                D Offline
                Davide87
                wrote on last edited by Davide87
                #7

                It works good!

                I took the sphere from Qt\5.11.1\Src\qtdatavis3d\src\datavisualization\engine\meshes. Then I added the custom item as in that example.
                The Q3DSurface class works perfectly. Furthermore now I don't need to get crazy passing things from c++ to qml.

                That's the result:
                0_1533804259361_surface.png

                Thank you very much guys.

                ps: Maybe "QML and Qt Quick" is no more the appropriate section for this topic :-D

                DiracsbracketD 1 Reply Last reply
                1
                • D Davide87

                  It works good!

                  I took the sphere from Qt\5.11.1\Src\qtdatavis3d\src\datavisualization\engine\meshes. Then I added the custom item as in that example.
                  The Q3DSurface class works perfectly. Furthermore now I don't need to get crazy passing things from c++ to qml.

                  That's the result:
                  0_1533804259361_surface.png

                  Thank you very much guys.

                  ps: Maybe "QML and Qt Quick" is no more the appropriate section for this topic :-D

                  DiracsbracketD Offline
                  DiracsbracketD Offline
                  Diracsbracket
                  wrote on last edited by
                  #8

                  @Davide87 said in Overlapped Surface3D and Scatter3D:

                  Qt\5.11.1\Src\qtdatavis3d\src\datavisualization\engine\meshes

                  Great to hear, and thank you for the feedback!
                  Thanks to this question, I also got to learn about the awesome software used to create the meshes:
                  https://www.blender.org/

                  1 Reply Last reply
                  0

                  • Login

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • Users
                  • Groups
                  • Search
                  • Get Qt Extensions
                  • Unsolved