Page 2 of 2 FirstFirst 12
Results 21 to 24 of 24

Thread: Adding items in QGraphicsScene is slow

  1. #21
    Join Date
    Jul 2013
    Posts
    15
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Adding items in QGraphicsScene is slow

    I'm sorry for the mistake, I meant 10 000ms of course (=10 sec, what I was about to say at first). But that's a lot compared to 500ms.
    I mesured what you asked for, and it tells me that there's 0ms between those lines (It must be too fast to detect it). So I think the problem here is adding items.
    I should ask a friend to test my application for me. Because I don't care if it's slow for me, really, I just want it to be fast for the others. (Well it would be better if it's fast for everybody but ...)

    Well if you have more ideas, don't hesitate, Thanks!

  2. #22
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Adding items in QGraphicsScene is slow

    Sorry, I meant the elapsed time at line 20 since line line 8. Trying to determine if it is the scene building (before line 20) or the displaying (line 20 onward) that is taking the longest.

    Which compiler, Qt version and Windows version? Are you using an ANGLE or OpenGL build?

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

    Default Re: Adding items in QGraphicsScene is slow

    Quote Originally Posted by ChrisW67 View Post
    Sorry, I meant the elapsed time at line 20 since line line 8. Trying to determine if it is the scene building (before line 20) or the displaying (line 20 onward) that is taking the longest.
    Previous tests seem to indicate it is indexing the scene that takes that time. Which could suggest Grade is using a really old version of Qt

    The fun part is that with Qt5 (linux, xcb) the same code takes almost a second to execute on my computer.
    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.


  4. #24
    Join Date
    Jul 2013
    Posts
    15
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: Adding items in QGraphicsScene is slow

    One second ! Wow that's a huge difference indeed.

    About my Qt version, I downloaded it recently so I'm under Qt 5.0.2. My OS is Windows XP Pro SP3 and I've got an Intel Core 2 Duo (CPU).
    I don't know what do you mean by an ANGLE or an OpenGL Build (I've searched for it but I didn't find anything), I didn't change any configuration so every build setting is the default one.

Similar Threads

  1. QComboBox extremely slow on adding a lot of items
    By Buldozer in forum Qt Programming
    Replies: 3
    Last Post: 16th May 2021, 12:46
  2. QGraphicsScene is SLOW with a lot of items !
    By pl01 in forum Qt Programming
    Replies: 11
    Last Post: 5th August 2011, 16:06
  3. adding subclassed items to a QGraphicsScene
    By liqxpil in forum Newbie
    Replies: 3
    Last Post: 27th October 2010, 11:54
  4. QGraphicsScene: selection of multiple items is very slow
    By felixrubio in forum Qt Programming
    Replies: 0
    Last Post: 22nd July 2010, 15:51
  5. Too slow adding & defining items to QTreeWidget
    By jnk5y in forum Qt Programming
    Replies: 16
    Last Post: 22nd April 2008, 20:26

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.