Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. [Solved] QVTKWidgetPlugin makes QT creator crash
QtWS25 Last Chance

[Solved] QVTKWidgetPlugin makes QT creator crash

Scheduled Pinned Locked Moved 3rd Party Software
9 Posts 2 Posters 4.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.
  • M Offline
    M Offline
    mbcx9rb9
    wrote on last edited by
    #1

    I'm trying to use VTK in Qt Creator.

    In Qt Designer, I have copied thelibQVTKWidgetPlugin.dylib into the plugin directory. Now I can create QVTKWidgets in Designer.

    However, when I copy libQVTKWidgetPlugin.dylib into the
    @[QT dir]/QT Creator.app/Contents/Plugins/designer @

    folder and boot up QT Creator, it crashes before loading with the error "Qt Creator quit unexpectedly" (I can attach the full error if necessary).

    Similarly, when I try to promote a QWidget to a QVTKWidget in the designer tab, any program I create with the QVTKWidget crashes with the same error.

    Why is this?

    The QT GUI examples included with VTK work with CMake.

    My specs are: Mac OS X 10.10, VTK 6.1 (release mode, BUILD_SHARED_LIBS on, vtk_GUISupportQt on) Qt Creator 3.2.2 with Qt 5.3.2

    Thanks in advance

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

      Hi and welcome to devnet,

      Which version of Qt did you use to build the plugin ?

      The error report would indeed be useful

      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
      • M Offline
        M Offline
        mbcx9rb9
        wrote on last edited by
        #3

        How do you mean the Qt version used to build the plugin? I built the plugin when building VTK (6.1) and placed it into the plugin folder of Qt Creator 3.2.2 running Qt 5.3.2. I can send you the error when I get to the office tomorrow morning.

        Cheers

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mbcx9rb9
          wrote on last edited by
          #4

          Ok the error is pretty lengthy but it is attached beneath. It happens whenever I load the *.ui file in the editor (i.e. bring up the design tab).

          Thanks for the help

          https://copy.com/lZsSmUtWkXO6fjYt

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

            Your Qt Creator was built with Qt 5.3.2, what version of Qt are you using currently ?

            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
            • M Offline
              M Offline
              mbcx9rb9
              wrote on last edited by
              #6

              Still 5.3.2, the current version of Qt.

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

                From your error log it seems that Qt Creator is trying to access a null pointer. Can you run Qt Creator from the command line with QT_DEBUG_PLUGINS set to 1 to see if you have some more information about what happens ?

                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
                • M Offline
                  M Offline
                  mbcx9rb9
                  wrote on last edited by
                  #8

                  Running with QT_DEBUG_PLUGINS, I found the error:

                  @Error: no override found for 'vtkRenderWindow'@

                  With a quick google, I found that before any #include lines in Qt Creator, you need to add:

                  @#define vtkRenderingCore_AUTOINIT 4(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingFreeTypeOpenGL,vtkRenderingOpenGL)
                  #define vtkRenderingVolume_AUTOINIT 1(vtkRenderingVolumeOpenGL)@

                  Placing the libQVTK file in the designer folder of Creator plugins still causes a crash, but promoting the QWidget manually works. As long as one method works, I'm happy!

                  Cheers for the help

                  Source (http://stackoverflow.com/questions/18642155/no-override-found-for-vtkpolydatamapper)

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

                    Nice !

                    Thanks for sharing !

                    Can you also please 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