Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [Solved] Phonon "blocking" my application
Forum Updated to NodeBB v4.3 + New Features

[Solved] Phonon "blocking" my application

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 1.6k Views 1 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.
  • R Offline
    R Offline
    rapidcc
    wrote on last edited by
    #1

    I use Phonon for Audio Playback in my desktop application.
    Everytime I press a certain key, a sound will play.

    Now, the playback works fine and it works just as i want it to work but I came across a problem:
    When I call "stop" on my MediaObject it stops playing but a ton of threads exit and my GUI hangs. I can't trace this problem down as my application returns to the event loop immediately after calling "stop". It has to be "phonons fault".

    So what could it be and how can I fix it? The code looks like this:

    @
    MainWindow.cpp:
    {
    void MainWindow::PlaySound(int s)
    {
    //I have a std map with previously created media objects mapped to int values
    if(smap->find(s) != smap->end())
    {
    ((*smap)[s])->play();
    }
    sleep(1); //sleep one second -> I know this blocks my UI but this call is definitely not our problem
    ((*smap)[s])->stop();
    }
    }
    @

    1 Reply Last reply
    0
    • R Offline
      R Offline
      rapidcc
      wrote on last edited by
      #2

      Alright, I have some news regarding this problem.
      It turned out that it was a bug in the gstreamer backend. Phonon was not the problem.

      kind regards,
      rapidcc

      1 Reply Last reply
      0
      • K Offline
        K Offline
        koahnig
        wrote on last edited by
        #3

        Thanks for reporting that this has been solved.

        I have marked your thread as solved.

        Vote the answer(s) that helped you to solve your issue(s)

        1 Reply Last reply
        0

        • Login

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