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. Get coordinates of dicom image by clicking anywhere on image in Qt
Forum Updated to NodeBB v4.3 + New Features

Get coordinates of dicom image by clicking anywhere on image in Qt

Scheduled Pinned Locked Moved Unsolved General and Desktop
23 Posts 5 Posters 3.5k 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.
  • mrjjM Offline
    mrjjM Offline
    mrjj
    Lifetime Qt Champion
    wrote on last edited by
    #21

    HI
    you can not promote a widget to 2 different widgets.
    That is not possible but would be cool if it could work :)
    You can have 2 widgets but im not sure why you want that.

    From the code, matDisplay is your version of QVTKWidget so
    you should place a QWidget and promote that to matDisplay.

    And it then contains your extra code for mousePress and all of QVTKWidget

    1 Reply Last reply
    1
    • P Offline
      P Offline
      pvirk
      wrote on last edited by
      #22

      I tried this way.
      I used QWidget for my matDisplay class and promoted to matDisplay.
      But when I use that same QWidget in my code to load image, It shows those same errors.
      Error C2039 'SetRenderWindow': is not a member of 'matDisplay'
      Error C2039 'GetInteractor': is not a member of 'matDisplay'

      (because it is promoted to only matDisplay and not to QVTKWidget)

      I need only one widget where i can load dicom image (which are connected to render window and interactor in my code) and use that same widget to get coordinates of that dicom image.

      Sorry I tried all ways, but don't understand how to achieve these both things using only one widget.
      Kindly please help me.

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

        Inherit matWidget from QVTKWidget.

        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
        1

        • Login

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