Results 1 to 13 of 13

Thread: Text in Multithreading OpenGL

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Dec 2010
    Posts
    15
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    1

    Default Re: Text in Multithreading OpenGL

    There is always an workaround!
    My issue is to show a Text in OpenGL Widget.

    But I can't do it becouse QPainter that privided renderText() have to be initilized in main thread or OpenGL must run in main thread. But I can't run OpenGL in main thread, becouse I have to show 9 videos (about 40*9 images in HD format per second) at the same time. If I will do this my main windows will freez.

    Do I have other optionts?

    thanks!

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

    Default Re: Text in Multithreading OpenGL

    Quote Originally Posted by bahbah30 View Post
    There is always an workaround!
    My issue is to show a Text in OpenGL Widget.
    So don't use threads, that's your workaround.
    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.


  3. #3
    Join Date
    Dec 2010
    Posts
    15
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    1

    Default Re: Text in Multithreading OpenGL

    Quote Originally Posted by wysota View Post
    So don't use threads, that's your workaround.
    than will my main tread freez! How woud you show 9 vidoes without freezing main thread?

  4. #4
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanked 268 Times in 268 Posts
    Wiki edits
    20

    Default Re: Text in Multithreading OpenGL

    Use techniques that do not block the eventloop.
    This works up to a certain point. If loading and displaying of a single frame is as fast as possible and it still isn't fast enough for the computer, you'll need to look into special techniques. Threading will not help here.

    I can't imagine any need for 40 fps with 9 (full) HD frames on a single computer monitor. That is one area you can greatly improve the speed.
    If it is necessary, you do not want a simple computer with a single monitor, you want a computer with multiple monitors that has a single GPU for every monitor. In your example 9 monitors and 9 GPU's. And then you can redirect the painting, decoding, etc... to each GPU
    Last edited by tbscope; 10th December 2010 at 09:30.

Similar Threads

  1. Replies: 0
    Last Post: 20th August 2010, 12:50
  2. 2D OpenGL text rendering with existing app
    By bytebucket in forum Newbie
    Replies: 7
    Last Post: 11th March 2010, 20:28
  3. regarding multithreading
    By mohanakrishnan in forum Qt Programming
    Replies: 19
    Last Post: 9th December 2009, 08:21
  4. QGraphicsView, OpenGL & rotated text
    By anthon in forum Qt Programming
    Replies: 8
    Last Post: 5th December 2009, 17:05
  5. No text antialiasing with OpenGL graphicsview
    By pherthyl in forum Qt Programming
    Replies: 3
    Last Post: 13th March 2009, 22:47

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.