Results 1 to 1 of 1

Thread: QMediaplayer Sound status

  1. #1
    Join Date
    Nov 2014
    Posts
    12
    Thanks
    4

    Default QMediaplayer Sound status

    Hello!

    I have a new question that I hope someone could help me out.

    How can I test my QMediaPlayer status?

    WARNING PSEUDO CODE INCOMING!!

    Qt Code:
    1. QMediaPlayer ErrorSound;
    2. if(ErrorSound == QMediaPlayer::EndOfMedia)
    3. {
    4. make things
    5. }
    To copy to clipboard, switch view to plain text mode 

    Thank you in advance!

    UPDATE

    I cant test it right now but I think this will solve it, can someone tell their opinion?
    Qt Code:
    1. QMediaPlayer ErrorSound;
    2. if(ErrorSound->mediaStatus() == 7) // value = 7 ---->Playback has reached the end of the current media. The player is in the StoppedState.
    3. {
    4. make things
    5. }
    To copy to clipboard, switch view to plain text mode 

    Thank you!
    Last edited by digimonkey; 16th March 2015 at 11:17.

Similar Threads

  1. QMediaplayer Sound file problem
    By digimonkey in forum Newbie
    Replies: 1
    Last Post: 4th February 2018, 06:33
  2. QMediaPlayer Sound not working in other PCs
    By digimonkey in forum Qt Programming
    Replies: 2
    Last Post: 13th March 2015, 05:07
  3. QMediaPlayer repeat sound
    By alenn.masic in forum Qt Programming
    Replies: 0
    Last Post: 21st February 2013, 14:46
  4. Replies: 3
    Last Post: 8th July 2010, 07:41
  5. MP3 Sound / OGG Sound Play on GUI
    By patrik08 in forum Newbie
    Replies: 3
    Last Post: 1st September 2006, 19:01

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.