Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Game Development
  4. [solved] how do i get the current volume of device in qt?
Forum Updated to NodeBB v4.3 + New Features

[solved] how do i get the current volume of device in qt?

Scheduled Pinned Locked Moved Game Development
6 Posts 3 Posters 4.2k 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.
  • T Offline
    T Offline
    Tratstil
    wrote on last edited by
    #1

    I use phonon to play music but the volume not change when user changes volume of device.
    Please help, thanks.

    1 Reply Last reply
    0
    • L Offline
      L Offline
      leon.anavi
      wrote on last edited by
      #2

      Could you please share more details? Game for which platform are you developing and how does to user changes the volume of the device?

      http://anavi.org/

      1 Reply Last reply
      0
      • T Offline
        T Offline
        Tratstil
        wrote on last edited by
        #3

        @leon.anavi thanks you a lot.
        I had solved it.
        I have developed in harmattan platform, i forgot set the name for QApplication object before create any object of phonon::MediaObject . now it had been solved but i still want know what event will be thrown when user change volume of device.

        1 Reply Last reply
        0
        • L Offline
          L Offline
          leon.anavi
          wrote on last edited by
          #4

          [quote author="Tratstil" date="1314087052"]@leon.anavi thanks you a lot.
          I had solved it.[/quote]

          You are welcome but I didn't do anything :)

          Btw there is a thread at "developer.nokia.com about volume keys on MeeGo Harmattan devices":http://www.developer.nokia.com/Community/Discussion/showthread.php?226283-Grab-Volume-Keys-on-Harmattan. Another interesting link regated to the same topic is: "Using Resource Policy to enhance games":http://library.developer.nokia.com/topic/MeeGo_1.2_Harmattan_API/html/guide/html/Developer_Library_Best_practices_for_application_development_Using_Resource_Policy_to_enhance_games_a32a.html. These links might be useful to you.

          http://anavi.org/

          1 Reply Last reply
          0
          • T Offline
            T Offline
            Tratstil
            wrote on last edited by
            #5

            :) good link.

            1 Reply Last reply
            0
            • K Offline
              K Offline
              kunal_the_one
              wrote on last edited by
              #6

              Hi Tratstil,

              Can you please share some more details about how you solve the problem.

              I am also using Phonon in one of my project. But when I change volume using volume key it dose not affect volume to Phonon AudioObject.

              You said you set application name and it solve your problem ? Are you referring to QCoreApplication::setApplicationName ?

              Thanks,
              Kunal

              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