Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [solved] Qt 5.3 beta + Qt3D (git) + QGLView + QDialog
Forum Updated to NodeBB v4.3 + New Features

[solved] Qt 5.3 beta + Qt3D (git) + QGLView + QDialog

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 1.4k Views 1 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.
  • T Offline
    T Offline
    timio
    wrote on last edited by
    #1

    Hi,

    I've been trying to setup QGLView + 3D content into widget base application's dialog without success. I always run into:

    "ASSERT failure in QGLPainter: "begin() has not been called or it failed", file painting\qglpainter.cpp, line 1665"

    I've been experimenting with basketview example that comes with qt3d. It works fine as it is and also works within QMainWindow:

    BasketView *view = new BasketView();
    QWidget *container = QWidget::createWindowContainer(view);
    centralWidget()->layout()->addWidget(container);

    However, my target is to have a QDialog that contains the 3D view. I know I'm experimenting with code that is not finalized and is under heavy construction but I would appreciate any pointers or experiences on this. Is this even supposed to work (at this stage)?

    thanks

    1 Reply Last reply
    0
    • T Offline
      T Offline
      timio
      wrote on last edited by
      #2

      I think I figured this out.. just in case someone else is struggling with similar issues.

      The dialog itself was not the problem, the problem was that during QGLView initialization the dialog size was (momentarily) 0 before I updated the size.

      Anyway, QGLView is now working inside a dialog and I can proceed with my little project :)

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

        Hi and welcome to devnet !

        Glad you found out and thanks for sharing the solution :)

        Can you also update the thread title prepending [solved] so other forum users may know a solution has been found :)

        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

        • Login

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