Results 1 to 12 of 12

Thread: qPixmap retrieve size ( MB/KB ), scalling image performance

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #9
    Join Date
    Dec 2008
    Location
    Poland
    Posts
    383
    Thanks
    52
    Thanked 42 Times in 42 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: qPixmap retrieve size ( MB/KB ), scalling image performance

    I don't think it would make a big difference if at all.
    I tested it right now, no difference...
    Also testing without scale don't speed loading, so only conclusion is that load is slow? I use
    Qt Code:
    1. QPixmap tmp;
    2. QStringList fileNames; //populated with i.e. 7 images, total file size 1.16MB, WinXP
    3. for( int i = 0; i < fileNames.length(); ++i)
    4. {
    5. tmp.load( fileNames[i] );
    6. model.setData( model.index( i, 0 ), tmp, Qt::DecorationRole );
    7. }
    To copy to clipboard, switch view to plain text mode 
    to do that. (forcing extension don't speed up loading). Load is around 500 ms - 1sec.
    After some testing
    load files no scale debug mode 600-700mx
    load files no scale release mode 300-360mx
    load files with scale release mode 360-375mx
    so scaling takes around 30ms on my test files.
    EDIT:
    I tried also QFile; and read pixmap from bytearray same result.
    Also reading 123 images, size 35 MB took (on release compilation) 11s, copying that amount data on win is practically instant.
    Last edited by Talei; 4th April 2010 at 13:40.

Similar Threads

  1. Replies: 2
    Last Post: 14th September 2009, 08:38
  2. Replies: 2
    Last Post: 14th September 2009, 08:31
  3. QPainter - Retrieve drawText size
    By Raccoon29 in forum Qt Programming
    Replies: 2
    Last Post: 2nd May 2008, 09:22
  4. performance issue(QGV + QPixmap::grabWidget)
    By momesana in forum Qt Programming
    Replies: 4
    Last Post: 27th September 2007, 11:31
  5. Replies: 5
    Last Post: 9th April 2007, 14: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
  •  
Qt is a trademark of The Qt Company.