Results 1 to 7 of 7

Thread: physics simulation

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    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: physics simulation

    You have to calculate everything manually yourself. You can use QLineF and QPointF to calculate intersections but the rest requires pure math skills. That's one of the reasons I'm suggesting GraphicsView.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  2. #2
    Join Date
    Aug 2008
    Location
    Algarve, Portugal
    Posts
    288
    Thanks
    23
    Thanked 32 Times in 28 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Default Re: physics simulation

    I did a program like that where points would move inside a rectangle, like balls in a pool table. If I correctly understood, you have user draw lines with different angles than the horizontal and vertical lines of the rectangle. It´s all math like Wysota said, but if you think it can help you, I can try to find my code and show you, but it's old and made in MFC6 with opengl.

Similar Threads

  1. QTimer or recursive calls for simulation?
    By Morea in forum Qt Programming
    Replies: 3
    Last Post: 12th May 2006, 00:19

Tags for this Thread

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.