Results 1 to 20 of 46

Thread: Qpainter function on a QFrame problem

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Riverside, Rhode Island, USA
    Posts
    245
    Thanks
    52
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qpainter function on a QFrame problem

    I am going back and check my data as I am sure that is where it must be as you suggest, but I would like to know about the "{ Q_ASSERT_X(i >= 0 && i < p.size(),...." message. can it help me find where and what is the problem is?.

    I looked at QGraphicsView, as you suggested earlier, but for some reason decided not to go there. I will however do so now and try to make a parallel program to the one I have now.

    What I am trying to do as a structural engineer is write a parametric driven program to replace the current CAD programs used in the industry and one that someone can learn to use in a day or two by going back to a modified command line operation similar to one I had written in pre-dos days. I do not have any time restraints, but a need to get it right.

    I took a quick look at "graphicsview" and noted it was a 2D program and the program i am trying to re-write was a 3D rendered structure
    Thanks for you indulgence
    Attached Images Attached Images
    Last edited by impeteperry; 10th September 2008 at 06:36.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qpainter function on a QFrame problem

    Quote Originally Posted by impeteperry View Post
    I am going back and check my data as I am sure that is where it must be as you suggest, but I would like to know about the "{ Q_ASSERT_X(i >= 0 && i < p.size(),...." message. can it help me find where and what is the problem is?.
    Not really. But a backtrace from a debugger will and I suggest you use one here. There is no point in guessing if the application itself can tell you what is wrong.

    I looked at QGraphicsView, as you suggested earlier, but for some reason decided not to go there. I will however do so now and try to make a parallel program to the one I have now.
    I really suggest you reconsider using GV. It's perfect for your usecase.

    I took a quick look at "graphicsview" and noted it was a 2D program and the program i am trying to re-write was a 3D rendered structure
    But you are rendering it on a 2D canvas, so everything is ok. If you want to have real 3D, consider using OpenGL with one of the viewer frameworks available for Qt.

  3. #3
    Join Date
    Jan 2006
    Location
    Riverside, Rhode Island, USA
    Posts
    245
    Thanks
    52
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qpainter function on a QFrame problem

    Thanks
    I am using opengl.

    There are 2 parts to the program.
    1. developing a library of concrete elements (columns, beams, plank, connection hardware etc.) using opengl.

    2. defining where they go.

    This in a replacement for conventional CAD! which is prone for errors resulting from a multiplicity of input points for a given item. (floor plan, excavations, wall sections and details);

    I layout a set of grids( support lines)
    select a level (1st, 2nd, 3rd etc floor, )
    place columns from the column library and locate them on grid intersections
    place beams from the beam library and locate them by their supporting columns
    place plank from the plank library and locate them by their supporting beams

    now, if a grid line is moved, the associated columns move, the beam location and spans change, the plank location and spans change.
    Now is a change levels, the column length changes etc.

    this is all done automatically. Sort of like a "solid modeler" which I had tried.

    Sorry to be so verbose, and I thank you for you patients.
    Attached Images Attached Images

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qpainter function on a QFrame problem

    Hmm... honestly I don't see anything 3D in the second image you attached to the last post.

  5. #5
    Join Date
    Jan 2006
    Location
    Riverside, Rhode Island, USA
    Posts
    245
    Thanks
    52
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qpainter function on a QFrame problem

    Quote Originally Posted by wysota View Post
    Hmm... honestly I don't see anything 3D in the second image you attached to the last post.
    All right you are getting to me. This is a database that defines the total structure. Any change here changes everything. I am going away for a couple of weeks and try out your recommendations from scratch

    Thanks again

  6. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qpainter function on a QFrame problem

    Regardless of what the data is meant for, it is displayed as 2D, therefore suits well with the Graphics View architecture.

  7. The following user says thank you to wysota for this useful post:

    impeteperry (13th September 2008)

  8. #7
    Join Date
    Jan 2006
    Location
    Riverside, Rhode Island, USA
    Posts
    245
    Thanks
    52
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qpainter function on a QFrame problem

    I am already incorporating QGraphicView (trying anyway) into my program.
    Thanks again

    pete.

  9. #8
    Join Date
    Jan 2006
    Location
    Riverside, Rhode Island, USA
    Posts
    245
    Thanks
    52
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Qpainter function on a QFrame problem

    Thanks for all the help. How do I close this posts so I can use some attachments on another post i want to make

Similar Threads

  1. QPSQL driver in windows
    By brevleq in forum Installation and Deployment
    Replies: 31
    Last Post: 14th December 2007, 12:57
  2. how to add static library into qmake
    By Namrata in forum Qt Tools
    Replies: 1
    Last Post: 20th November 2007, 17:33
  3. Problem emitting signal from a static function
    By Valheru in forum Qt Programming
    Replies: 21
    Last Post: 12th June 2007, 14:48
  4. KDE/QWT doubt on debian sarge
    By hildebrand in forum KDE Forum
    Replies: 13
    Last Post: 25th April 2007, 06:13
  5. use qpsql
    By raphaelf in forum Installation and Deployment
    Replies: 34
    Last Post: 22nd August 2006, 12:52

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.