Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. [Solved] Scrolling Text eating lot of CPU on beagleBone
Forum Updated to NodeBB v4.3 + New Features

[Solved] Scrolling Text eating lot of CPU on beagleBone

Scheduled Pinned Locked Moved Solved Mobile and Embedded
25 Posts 4 Posters 8.3k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #12

    Looks like you should rather consider a QListView using a QStringListModel.

    Also, how big is the history that you want to keep available to your passengers ?

    Interested in AI ? www.idiap.ch
    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

    1 Reply Last reply
    1
    • G Offline
      G Offline
      guru007
      wrote on last edited by
      #13

      Thanks for suggestions, But I think problem is graphics performance on Beaglebone black.
      I think application not using hardware acceleration for rendering of scrolling text because text is refreshed at 100 times per second because I scrolling text by incrementing :
      QTimer timer;
      timer.setInterval(5);
      timer-> connected with Slot()
      Slot()
      {
      static int count = 0;
      scrollbar->setValue(count);
      count ++;
      }

      Basically When I using other Qt Demo apps like colliding mice CPU usage increases to 100%.
      BeagleBone black SGX GPU for graphics. Is there anything to do or How can I check whether GPU is used or not By Qt application.
      Thanks

      jsulmJ 2 Replies Last reply
      0
      • G guru007

        Thanks for suggestions, But I think problem is graphics performance on Beaglebone black.
        I think application not using hardware acceleration for rendering of scrolling text because text is refreshed at 100 times per second because I scrolling text by incrementing :
        QTimer timer;
        timer.setInterval(5);
        timer-> connected with Slot()
        Slot()
        {
        static int count = 0;
        scrollbar->setValue(count);
        count ++;
        }

        Basically When I using other Qt Demo apps like colliding mice CPU usage increases to 100%.
        BeagleBone black SGX GPU for graphics. Is there anything to do or How can I check whether GPU is used or not By Qt application.
        Thanks

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #14

        @guru007 said in Scrolling Text eating lot of CPU on beagleBone:

        text is refreshed at 100 times per second

        this does not make sense as your display most probably cannot refresh so often (usually it is 60Hz). Actually it would be enough to refresh at 25Hz - this is what a human perceives as smooth.

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        G 1 Reply Last reply
        1
        • jsulmJ jsulm

          @guru007 said in Scrolling Text eating lot of CPU on beagleBone:

          text is refreshed at 100 times per second

          this does not make sense as your display most probably cannot refresh so often (usually it is 60Hz). Actually it would be enough to refresh at 25Hz - this is what a human perceives as smooth.

          G Offline
          G Offline
          guru007
          wrote on last edited by SGaist
          #15

          @jsulm
          But with even 30 fps it consuming whole processing Power.

          1 Reply Last reply
          0
          • G guru007

            Thanks for suggestions, But I think problem is graphics performance on Beaglebone black.
            I think application not using hardware acceleration for rendering of scrolling text because text is refreshed at 100 times per second because I scrolling text by incrementing :
            QTimer timer;
            timer.setInterval(5);
            timer-> connected with Slot()
            Slot()
            {
            static int count = 0;
            scrollbar->setValue(count);
            count ++;
            }

            Basically When I using other Qt Demo apps like colliding mice CPU usage increases to 100%.
            BeagleBone black SGX GPU for graphics. Is there anything to do or How can I check whether GPU is used or not By Qt application.
            Thanks

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by SGaist
            #16

            @guru007 Sorry, something went wrong here and I edited your last post. That wasn't intentionally.

            You wrote before that the text can be very long. You should test with not so long text (but still long enough to need a scroll bar). Does it then still consume 100% CPU?
            Qt widgets do not use hardware acceleration as far as I know (but QML does). Alternative would be to use http://doc.qt.io/qt-5/graphicsview.html

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            1
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #17

              @jsulm Everything is back on track. I still had the email from the thread :)

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              jsulmJ 1 Reply Last reply
              2
              • SGaistS SGaist

                @jsulm Everything is back on track. I still had the email from the thread :)

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #18

                @SGaist Thanks!

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                G 1 Reply Last reply
                2
                • jsulmJ jsulm

                  @SGaist Thanks!

                  G Offline
                  G Offline
                  guru007
                  wrote on last edited by
                  #19

                  @jsulm How can I check If my application uses GPU for rendering. I read from stackoverflow:

                  Qt doesn't magically GPU-accelerate the entire application. Widgets are not accelerated unless they derive from QOpenGLWidget. Qt Quick 2 is accelerated by default; there's an option of using the software renderer on hardware that doesn't support OpenGL ES 2. Qt Quick 1 is accelerated if you set a QOpenGLWidget as a viewport on the QGraphicsView.

                  Could you suggest some already built app to test gpu? Some Demo app

                  jsulmJ 1 Reply Last reply
                  0
                  • G guru007

                    @jsulm How can I check If my application uses GPU for rendering. I read from stackoverflow:

                    Qt doesn't magically GPU-accelerate the entire application. Widgets are not accelerated unless they derive from QOpenGLWidget. Qt Quick 2 is accelerated by default; there's an option of using the software renderer on hardware that doesn't support OpenGL ES 2. Qt Quick 1 is accelerated if you set a QOpenGLWidget as a viewport on the QGraphicsView.

                    Could you suggest some already built app to test gpu? Some Demo app

                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by
                    #20

                    @guru007 If you use widgets there is nothing to check as those do not use GPU.

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    G 1 Reply Last reply
                    1
                    • jsulmJ jsulm

                      @guru007 If you use widgets there is nothing to check as those do not use GPU.

                      G Offline
                      G Offline
                      guru007
                      wrote on last edited by
                      #21

                      @jsulm So which Qt Demo example I can use to test Gpu acceleration?

                      thanks

                      jsulmJ 1 Reply Last reply
                      0
                      • G guru007

                        @jsulm So which Qt Demo example I can use to test Gpu acceleration?

                        thanks

                        jsulmJ Offline
                        jsulmJ Offline
                        jsulm
                        Lifetime Qt Champion
                        wrote on last edited by jsulm
                        #22

                        @guru007 Again: you're currently using widgets! Widgets do not use GPU - what do you want to check?
                        If you're planning to switch to QML, then take one of QML/QtQuick examples.

                        https://forum.qt.io/topic/113070/qt-code-of-conduct

                        G 1 Reply Last reply
                        2
                        • jsulmJ jsulm

                          @guru007 Again: you're currently using widgets! Widgets do not use GPU - what do you want to check?
                          If you're planning to switch to QML, then take one of QML/QtQuick examples.

                          G Offline
                          G Offline
                          guru007
                          wrote on last edited by
                          #23

                          @jsulm Now I am also talking about Qml. I think colliding mice is right example to test.
                          Am I right dear?

                          jsulmJ 1 Reply Last reply
                          0
                          • G guru007

                            @jsulm Now I am also talking about Qml. I think colliding mice is right example to test.
                            Am I right dear?

                            jsulmJ Offline
                            jsulmJ Offline
                            jsulm
                            Lifetime Qt Champion
                            wrote on last edited by
                            #24

                            @guru007 Should be fine

                            https://forum.qt.io/topic/113070/qt-code-of-conduct

                            1 Reply Last reply
                            2
                            • G Offline
                              G Offline
                              guru007
                              wrote on last edited by
                              #25

                              problem is solved by using QgrpahicsView with Qimage.
                              I draw text on QImage And Display it in QGraphicScene.
                              Cpu usage decreased to 45 % .
                              Thanks for ur replies.

                              1 Reply Last reply
                              1

                              • Login

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • Users
                              • Groups
                              • Search
                              • Get Qt Extensions
                              • Unsolved