Results 1 to 2 of 2

Thread: How to Optimized Combined Graphical Operations?

  1. #1
    Join Date
    Apr 2010
    Posts
    2
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11

    Exclamation How to Optimized Combined Graphical Operations?

    Hi,

    Here is a Scenario, A series of operations that I will call for painting,

    QPainter p(this);

    1). p.fillRect(0,0,320,240, RED_COLOR)

    2) p.drawLine(0,0,100,100, BLUE_COLOR)

    3) p.fillRect(0,0,320,240, YELLOW_COLOR)

    Now I want that painter should not draw first FillRect Function. It should not draw line. It should only perform last operation.

    Is there any way to achive this optimization in Qt.

    Is this type of drawing/painting optimizations are supported by any library?

  2. #2
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: How to Optimized Combined Graphical Operations?

    Now I want that painter should not draw first FillRect Function. It should not draw line. It should only perform last operation.
    On what conditions do you want that to happen ? If you have some condition, put those condition before painting..
    If you dont have any such condition, then you can delete the fillRect and drawLine statements

Similar Threads

  1. Bit operations
    By Lykurg in forum General Programming
    Replies: 1
    Last Post: 8th April 2010, 11:11
  2. Replies: 8
    Last Post: 16th October 2009, 14:44
  3. emit qt signal is very slow how it can be optimized?
    By sawerset in forum Qt Programming
    Replies: 8
    Last Post: 30th December 2008, 09:21
  4. Qt's optimized OpenGL context switching
    By sverhoff in forum Qt Programming
    Replies: 0
    Last Post: 28th March 2006, 16:40
  5. Graphics operations - Qt 4.1
    By hoborg in forum Newbie
    Replies: 1
    Last Post: 18th February 2006, 14:09

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