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. Qt3D/Qml mesh bounding box
Forum Updated to NodeBB v4.3 + New Features

Qt3D/Qml mesh bounding box

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
3 Posts 3 Posters 1.3k Views 2 Watching
  • 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.
  • Q Offline
    Q Offline
    Q--t 0
    wrote on last edited by
    #1

    Hi Qt guys,

    I am importing an obj file and want to find the boundingbox of this object using qt3d/qml.

    Any body has an idea if we can access such information in qt3d/qml.

    Q--t

    1 Reply Last reply
    0
    • StevenFSS Offline
      StevenFSS Offline
      StevenFS
      wrote on last edited by
      #2

      Hi @Q-t-0, I just imported a custom-mesh *.obj from Blender into the QTDataVisualization arena. I did not encounter any problems/properties or even a mention of Bounding-Boxes. Could you please provide more details on what your trying to accomplish and what problem your hitting?

      If it helps my final syntax was this:

      // NOTE: This was a Polar Grid. 'position' coords are (angle, height, direction).
      Custom3DItem {
          id: widgetMesh
          visible: true
          meshFile: ":models/myWidget.obj"
          textureFile: ":models/blue50.png"   // small semi-transparent square.
          position: Qt.vector3d(270.0, 96.0, 25.0)
          scaling: Qt.vector3d(15.0, 4.0, 15.0)
      }
      

      Issues I did encounter:

      1. Initially my object was much-much too large (or too small) and I had to play with the scaling. I did this directly in the QML (not in the model generator). See syntax above.
      2. During object creation (ie. in Blender) you must create the UV mapping, check the beginning of this page, just the UV mapping part. http://www.chocofur.com/uv-mapping-tutorial-in-blender.html
      3. The texture/material/opacity were not set in Blender during object-creation. Notice my textureFile is a straight *.png import.


      Let us know if any of this is helpful!

      C++ Software Engineer

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        Hi! You need to implement your own aspect for this. Don't think you can do this without writing code in C++ though.

        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