WO2016161877A1 - Method and system for determining application program currently playing audio content - Google Patents

Method and system for determining application program currently playing audio content Download PDF

Info

Publication number
WO2016161877A1
WO2016161877A1 PCT/CN2016/076484 CN2016076484W WO2016161877A1 WO 2016161877 A1 WO2016161877 A1 WO 2016161877A1 CN 2016076484 W CN2016076484 W CN 2016076484W WO 2016161877 A1 WO2016161877 A1 WO 2016161877A1
Authority
WO
WIPO (PCT)
Prior art keywords
application
sound
query
playing
icon
Prior art date
Application number
PCT/CN2016/076484
Other languages
French (fr)
Chinese (zh)
Inventor
朱萧木
谭瑞
耿达维
Original Assignee
北京锤子数码科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京锤子数码科技有限公司 filed Critical 北京锤子数码科技有限公司
Publication of WO2016161877A1 publication Critical patent/WO2016161877A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs

Definitions

  • the present invention relates to the field of application identification technology, and more particularly to a method and system for determining an application that is playing a sound.
  • many applications can control the sound of electronic devices, such as various music playback applications, video playback applications, Internet radio applications, audio reading applications, voice chat applications. Programs, etc.
  • applications running on the user's electronic device that can control the sound of the electronic device
  • the user may not know which one of the running applications is sounding.
  • the application needs to be found first. According to the existing operation mode, the user needs to open the interface of each running application separately, and then determine the application that is controlling the sound of the electronic device according to the playing state of the interface.
  • the existing operation mode is inefficient, which is not only inconvenient for the user, but also opens the application interface multiple times, which also causes unnecessary consumption of electronic device resources, and how to help the user quickly find an application that is controlling the sound of the electronic device. , is still a technical problem to be solved urgently.
  • the present invention discloses a method for determining an application that is playing a sound.
  • the method is applied to an electronic device, and the method comprises:
  • the displayed icon has a preset display effect.
  • the query identifies a process identifier of a process that is playing a sound, including:
  • it also includes:
  • the process of receiving the user stops the operation, and stops the operation of the process that is playing the sound according to the process stop operation.
  • the electronic device is a mobile terminal
  • the application query operation is: a query operation of a running application.
  • the query identifies a process identifier of a process that is playing a sound, including:
  • the process identifier of the process that is transmitting sound data to the audio flinger module of the audio subsystem through the Audio Track of the sound output channel is queried through the application programming interface.
  • the present invention also provides a system for determining an application that is playing a sound, which is applied to an electronic device, the system comprising: a process query unit, an application determining unit, and an icon display unit,
  • the process query unit is configured to query a process identifier of a process that is playing a sound
  • the application determining unit is configured to determine, according to a correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
  • the icon display unit is configured to display an icon of the determined application on a display screen of the electronic device.
  • the displayed icon has a preset display effect.
  • the process query unit includes: an operation query subunit or a detection query self unit,
  • the operation query sub-unit is configured to query a process identifier of a sound being played after receiving an application query operation of the user;
  • the detection query sub-unit is configured to query a process identifier of a process that is playing a sound after detecting that a process is playing a sound.
  • the method further includes: an interface display unit or a process stop unit,
  • the interface display unit is configured to receive a click operation of the user for the icon, and display an interface of the determined application according to the click operation;
  • the process stop unit is configured to receive a process stop of the user, and stop the operation of the process that is playing the sound according to the process stop operation.
  • the electronic device is a mobile terminal
  • the application query operation is: a query operation of a running application.
  • the process query unit is specifically configured to: query, by using an application programming interface, a process identifier of a process that is transmitting sound data to an audio flinger module of an audio subsystem through a voice output channel Audio Track.
  • the method and system for determining an application that is playing a sound can query the process identifier of the process that is playing the sound, and determine the application corresponding to the process ID that is queried according to the correspondence between the process identifier and the application, and display the Determine the icon of the app. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
  • FIG. 1 is a flowchart of a method for determining an application that is playing a sound according to an embodiment of the present invention
  • FIG. 2 is an icon of an application with a preset display effect according to an embodiment of the present invention.
  • FIG. 3 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention
  • FIG. 4 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention
  • FIG. 5 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention
  • FIG. 6 is a schematic diagram of displaying a volume adjustment control on an icon side according to an embodiment of the present invention.
  • FIG. 7 is a schematic structural diagram of a system for determining an application that is playing a sound according to an embodiment of the present invention.
  • FIG. 8 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present disclosure
  • FIG. 9 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present invention.
  • FIG. 10 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present invention.
  • a method for determining an application is provided in an embodiment of the present invention, and the method may be applied to an electronic device, where the method may include:
  • the electronic device in the present invention may be a mobile phone, a tablet computer, a computer, etc., and the present invention is particularly suitable for use in a mobile phone.
  • the implementation process of the S100 may be any one of the following two specific implementation modes:
  • Method 1 After receiving the user's application query operation, query the process identifier of the process that is playing the sound;
  • Manner 2 After detecting that a process is playing a sound, query the process identifier of the process that is playing the sound.
  • the application query operation may be: a query operation of the running application, such as: an application manager startup operation, and an "application” option in the "setting” option.
  • Click operation of the "Running” option in which the application manager can start a variety of operations, such as a double-click operation on the Home button, a long-press operation on the Home button, and the like.
  • the application query operation may also be other operations, and the present invention is not limited herein.
  • the method 1 may also start the application manager to query the running application in the electronic device and display the icon of the queried application.
  • the functionality of the present invention can be added to an existing application manager such that when the application manager queries an application that is running in the electronic device, it simultaneously queries the process identification of the process that is playing the sound.
  • the functionality of the present invention can also be independent of the application manager.
  • the first method can query the process identifier of the process that is playing the sound after receiving the user's application query operation, so that when the user wants to find the application that is playing the sound, only the application query operation needs to be performed on the electronic device. .
  • the process identifier of the process that is playing the sound is automatically queried, and the user is not required to perform the operation, which is more convenient.
  • the user can select between mode one and mode two, or switch between the two modes at any time.
  • S100 may include: querying a process identifier of a process that is playing a sound of a preset sound type.
  • the sound played in the electronic device can be divided into a plurality of sound types, such as: RING type, MUSIC type, ALARM type, and NOTIFICATION type.
  • the above preset sound type may be any one of the four types, and preferably, may be of the MUSIC type.
  • the RING type sound is used to play the incoming call ringtone; the MUSIC type sound is used to play multimedia content such as music; the ALARM type sound is used to play the alarm ringtone; the NOTIFICATION type sound is used to play various notification sounds, such as short messages.
  • the operating system of the electronic device may be an Android native operating system or an operating system developed based on the Android native operating system.
  • the operating system of the electronic device can also set different priorities and outputs for different sound types.
  • Strategy For example, the ALARM type has a higher priority than the MUSIC type; at the output, the ALARM type sound is preferentially output from the speaker, and the MUSIC type is preferentially output from the headphone.
  • the core modules of the audio subsystem in the Android native operating system or operating system based on the Android native operating system include the audio policy manager module and the audio flinger module, which all run in the system process media server.
  • the application When the application wants to play the sound, it needs to pass the sound data from the process of its own through the audio output channel Audio Track to the audio flinger, and the audio flinger processes the volume, resampling, mixing, sound effects, etc. of the received sound data, and then Pass the hardware device (such as a speaker) specified by the audio policy manager to play the sound.
  • the hardware device such as a speaker
  • the S100 may specifically include: querying, by the application programming interface, a process identifier of a process that is transmitting sound data to the audio flinger module of the audio subsystem through the sound output channel Audio Track.
  • the application's process can command the Audio Track to enter the state of transmitting sound data by calling AudioTrack's play() function or start() function.
  • S200 Determine, according to a correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
  • an application can have one or more processes, and each process identifier can only correspond to one application.
  • the displayed icon can have a preset display effect.
  • the preset display effect can be various, such as a flashing effect, a ripple effect, a magnification effect, an aperture effect, and the like.
  • FIG. 2 is a schematic diagram of an icon of an application with a preset display effect according to an embodiment of the present invention. As can be seen from FIG. 2, since the displayed icon has a preset display effect, the user can find the icon more easily.
  • the method for determining the application that is playing the sound provided by the embodiment of the present invention may query the process identifier of the process that is playing the sound, and determine the application corresponding to the process identifier that is queried according to the correspondence between the process identifier and the application, and display the Determine the icon of the app. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
  • another method for determining an application provided by the embodiment of the present invention may further include:
  • the present invention can control the electronic device to display the interface of the application corresponding to the icon, so that the user can control the application through the interface, such as adjusting the volume.
  • another method for determining an application that is playing a sound may further include:
  • the process of receiving the user stops the operation, and stops the operation according to the process to stop the running of the process that is playing the sound.
  • the S500 can cause the user to perform a process stop operation immediately after determining that the application that is playing the sound is determined by S300, thereby stopping the operation of the process that is playing the sound.
  • the process stop operation may be various, for example, a click operation on the icon displayed by the S300, a sliding operation on the icon displayed on the S300, a shaking operation on the electronic device, and turning the electronic device to display it.
  • a click operation on the icon displayed by the S300 a sliding operation on the icon displayed on the S300
  • a shaking operation on the electronic device a shaking operation on the electronic device
  • turning the electronic device to display it The operation of the screen facing downwards, etc.
  • another method for determining an application for playing a sound may further include:
  • the volume adjustment operation is: a shaking operation of the electronic device, an operation of turning the electronic device to face the display screen downward or a pressing operation of a physical volume button of the electronic device.
  • the pressing operation of the physical volume button of the electronic device is an adjustment operation of the volume of all applications of all applications or preset types.
  • the volume of other applications or other applications of the same type as the application is also adjusted simultaneously.
  • this synchronization adjustment is not desired by the user, so when the volume adjustment operation is a pressing operation on the physical volume button of the electronic device, the present invention can only apply to the determined application according to the pressing operation on the physical volume button.
  • the playback volume of the program is adjusted, and the volume of other applications is not adjusted. This will avoid the above situation.
  • the S600 may specifically include: receiving a volume adjustment operation performed by the user within a preset time period after the icon is displayed in step S300, according to the volume adjustment operation, only the application corresponding to the displayed icon Play the volume to adjust.
  • the volume adjustment control may also be displayed above or on one side of the icon displayed on the S300, so that the user can directly operate the displayed volume adjustment control.
  • FIG. 6 is a schematic diagram of displaying a volume adjustment control on an icon side according to an embodiment of the present invention. As shown in FIG. 6, the displayed adjustment control is composed of a mute control 002 and a tuning control 001. When the user needs to control the application to stop playing the sound, you can directly click the mute control 002. When the user needs to adjust the volume of the sound played by the application, the user can drag the slider on the tuning control 001.
  • the embodiment of the present invention further provides a system for determining an application that is playing a sound.
  • a system for determining an application that is playing a sound is applied to an electronic device, and the system may include: a process query unit 100, an application determining unit 200, and an icon display unit 300.
  • the process query unit 100 is configured to query a process identifier of a process that is playing a sound.
  • the process query unit 100 may include: an operation query subunit or a detection query subunit.
  • the operation query subunit is configured to query a process identifier of a process that is playing a sound after receiving an application query operation of the user;
  • the detection query sub-unit is configured to query a process identifier of a process that is playing a sound after detecting that a process is playing a sound.
  • the application query operation may be: a query operation of the running application, such as: an application manager startup operation, and an "application" in the "Settings” option.
  • the click operation of the "Running" option of the option wherein the application manager can start a variety of operations, such as a double-click operation on the Home button, a long-press operation on the Home button, and the like.
  • the application query operation may also be other operations, and the present invention is not limited herein.
  • the operation query subunit can query the process identifier of the process that is playing the sound after receiving the user's application query operation, so that when the user wants to find the application that is playing the sound, only the application query operation needs to be performed on the electronic device. Just fine.
  • the detection query sub-unit can automatically query the process identifier of the process that is playing the sound after detecting that the process is playing the sound, and the user is not required to perform the operation, which is more convenient.
  • the process query unit may be specifically configured to: query a process identifier of a process that is playing a sound of a preset sound type.
  • the preset sound type may be a MUSIC type.
  • the process query unit may be specifically configured to: query, by using an application programming interface, a process identifier of a process that is transmitting sound data to an audio flinger module of an audio subsystem through a voice output channel Audio Track.
  • the application determining unit 200 is configured to determine, according to the correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
  • an application can have one or more processes, and each process identifier can only correspond to one application.
  • the icon display unit 300 is configured to display an icon of the determined application on a display screen of the electronic device.
  • the icon displayed by the icon display unit 300 may have a preset display effect.
  • the preset display effect can be various, such as a flashing effect, a ripple effect, a magnification effect, an aperture effect, and the like.
  • the system for determining an application may query a process identifier of a process that is playing a sound, determine an application corresponding to the process ID that is queried according to the correspondence between the process identifier and the application, and display the determined application. Icon. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
  • another system for determining an application that is playing a sound may further include: an interface display unit 400, configured to receive a click operation of the user for the icon, according to the click. The operation displays the interface of the determined application.
  • the present invention can control the electronic device to display the interface of the application corresponding to the icon, so that the user can control the application through the interface, such as adjusting the sound. Quantity and so on.
  • another system for determining an application for playing a sound may further include: a process stop unit 500, configured to receive a process stop of a user, and stop the operation according to the process. The running of the process that is playing the sound.
  • the process stop unit 500 can cause the user to perform a process stop operation immediately after determining that the application of the sound is being played by the icon display unit 300, thereby stopping the operation of the process that is playing the sound.
  • the process stop operation may be various, for example, a click operation on an icon displayed by the icon display unit 300, a slide operation on an icon displayed on the icon display unit 300, a shaking operation on the electronic device, and the electronic device Perform the operation of turning the face down so that the display screen faces downward.
  • another system for determining an application may further include: a volume adjustment unit 600, configured to receive a volume adjustment operation of a user, according to the volume adjustment operation, only determined The playback volume of the app is adjusted.
  • a volume adjustment unit 600 configured to receive a volume adjustment operation of a user, according to the volume adjustment operation, only determined The playback volume of the app is adjusted.
  • the volume adjustment operation is: a shaking operation of the electronic device, an operation of turning the electronic device to face the display screen downward or a pressing operation of a physical volume button of the electronic device.
  • the volume adjustment control may also be displayed above or on one side of the icon displayed by the icon display unit 300, so that the user can directly operate the displayed volume adjustment control.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Telephone Function (AREA)

Abstract

A method and system for determining an application program currently playing audio content. The method comprises: querying a progress identifier of a current playing progress of an audio content(S100), determining a corresponding application program of the queried progress identifier according to a corresponding relationship between the progress identifier and the application program (S200); displaying an icon of the determined application program on a display screen of an electronic device (S300). An application program currently playing an audio content can be automatically determined and an icon of the application program displayed, thus assisting a user to quickly find a controlling application program of an electronic device currently playing an audio content. In this way, a user opening different interfaces of application programs and resource consumption caused thereby can be avoided.

Description

确定正在播放声音的应用程序的方法及系统Method and system for determining an application that is playing a sound
本申请要求于2015年04月07日提交中国专利局、申请号为申请号201510160549.1、发明名称为“确定正在播放声音的应用程序的方法及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese Patent Application filed on April 7, 2015, the Chinese Patent Office, the application number 201510160549.1, and the invention titled "Method and System for Determining the Application of the Sound Playing". The citations are incorporated herein by reference.
技术领域Technical field
本发明涉及应用程序识别技术领域,特别是涉及确定正在播放声音的应用程序的方法及系统。The present invention relates to the field of application identification technology, and more particularly to a method and system for determining an application that is playing a sound.
背景技术Background technique
随着电子设备性能的提高,用户的手机、平板电脑、计算机等电子设备上安装的应用程序也越来越多。As the performance of electronic devices increases, more and more applications are installed on electronic devices such as mobile phones, tablets, and computers.
为了与用户进行交互时有更好的交互效果,许多应用程序都可以控制电子设备发出声音,例如各种音乐播放应用程序、视频播放应用程序、网络电台应用程序、有声阅读应用程序、语音聊天应用程序等。当用户的电子设备中运行有多个可以控制电子设备发出声音的应用程序时,如果电子设备发出了声音,用户可能并不知道是哪一个正在运行的应用程序发出的声音。如果用户希望对该正在控制电子设备发出声音的应用程序进行操作,需要首先找到该应用程序。根据现有的操作方式,用户需要分别打开正在运行的各应用程序的界面,进而根据界面的播放状态确定正在控制电子设备发出声音的应用程序。In order to interact better with users, many applications can control the sound of electronic devices, such as various music playback applications, video playback applications, Internet radio applications, audio reading applications, voice chat applications. Programs, etc. When there are multiple applications running on the user's electronic device that can control the sound of the electronic device, if the electronic device makes a sound, the user may not know which one of the running applications is sounding. If the user wishes to operate on an application that is controlling the sound of the electronic device, the application needs to be found first. According to the existing operation mode, the user needs to open the interface of each running application separately, and then determine the application that is controlling the sound of the electronic device according to the playing state of the interface.
可见,现有的操作方式效率较低,不仅不便于用户使用,而且多次打开应用程序的界面还会造成电子设备资源的不必要消耗,如何帮助用户快速找到正在控制电子设备发出声音的应用程序,仍是一个亟待解决的技术问题。It can be seen that the existing operation mode is inefficient, which is not only inconvenient for the user, but also opens the application interface multiple times, which also causes unnecessary consumption of electronic device resources, and how to help the user quickly find an application that is controlling the sound of the electronic device. , is still a technical problem to be solved urgently.
发明内容Summary of the invention
本发明的目的在于提供一种确定正在播放声音的应用程序的方法及系统,以帮助用户快速找到正在控制电子设备发出声音的应用程序。It is an object of the present invention to provide a method and system for determining an application that is playing a sound to help a user quickly find an application that is controlling the sound emitted by the electronic device.
为达到上述目的,本发明公开了一种确定正在播放声音的应用程序的方 法,应用于电子设备,所述方法包括:To achieve the above object, the present invention discloses a method for determining an application that is playing a sound. The method is applied to an electronic device, and the method comprises:
查询正在播放声音的进程的进程标识;Query the process ID of the process that is playing the sound;
根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;Determining, according to the correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
在所述电子设备的显示屏上,显示所确定的应用程序的图标。On the display of the electronic device, an icon of the determined application is displayed.
可选的,所显示的图标具有预设的显示效果。Optionally, the displayed icon has a preset display effect.
可选的,所述查询正在播放声音的进程的进程标识,包括:Optionally, the query identifies a process identifier of a process that is playing a sound, including:
在接收到用户的应用程序查询操作后,查询正在播放声音的进程的进程标识;After receiving the user's application query operation, query the process identifier of the process that is playing the sound;
或者,or,
在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。After detecting that a process is playing a sound, query the process ID of the process that is playing the sound.
可选的,还包括:Optionally, it also includes:
接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面;Receiving a click operation of the user for the icon, displaying an interface of the determined application according to the click operation;
或者,or,
接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。The process of receiving the user stops the operation, and stops the operation of the process that is playing the sound according to the process stop operation.
可选的,所述电子设备为移动终端,所述应用程序查询操作为:正在运行的应用程序的查询操作。Optionally, the electronic device is a mobile terminal, and the application query operation is: a query operation of a running application.
可选的,所述查询正在播放声音的进程的进程标识,包括:Optionally, the query identifies a process identifier of a process that is playing a sound, including:
通过应用程序编程接口查询正在通过声音输出通道的Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。The process identifier of the process that is transmitting sound data to the audio flinger module of the audio subsystem through the Audio Track of the sound output channel is queried through the application programming interface.
本发明还提供了一种确定正在播放声音的应用程序的系统,应用于电子设备,所述系统包括:进程查询单元、应用确定单元和图标显示单元,The present invention also provides a system for determining an application that is playing a sound, which is applied to an electronic device, the system comprising: a process query unit, an application determining unit, and an icon display unit,
所述进程查询单元,用于查询正在播放声音的进程的进程标识;The process query unit is configured to query a process identifier of a process that is playing a sound;
所述应用确定单元,用于根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;The application determining unit is configured to determine, according to a correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
所述图标显示单元,用于在所述电子设备的显示屏上,显示所确定的应用程序的图标。The icon display unit is configured to display an icon of the determined application on a display screen of the electronic device.
可选的,所显示的图标具有预设的显示效果。 Optionally, the displayed icon has a preset display effect.
可选的,所述进程查询单元,包括:操作查询子单元或检测查询自单元,Optionally, the process query unit includes: an operation query subunit or a detection query self unit,
所述操作查询子单元,用于在接收到用户的应用程序查询操作后,查询正在播放声音的进程标识;The operation query sub-unit is configured to query a process identifier of a sound being played after receiving an application query operation of the user;
所述检测查询子单元,用于在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。The detection query sub-unit is configured to query a process identifier of a process that is playing a sound after detecting that a process is playing a sound.
可选的,还包括:界面显示单元或进程停止单元,Optionally, the method further includes: an interface display unit or a process stop unit,
所述界面显示单元,用于接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面;The interface display unit is configured to receive a click operation of the user for the icon, and display an interface of the determined application according to the click operation;
所述进程停止单元,用于接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。The process stop unit is configured to receive a process stop of the user, and stop the operation of the process that is playing the sound according to the process stop operation.
可选的,所述电子设备为移动终端,所述应用程序查询操作为:正在运行的应用程序的查询操作。Optionally, the electronic device is a mobile terminal, and the application query operation is: a query operation of a running application.
可选的,所述进程查询单元,具体用于:通过应用程序编程接口查询正在通过声音输出通道Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。Optionally, the process query unit is specifically configured to: query, by using an application programming interface, a process identifier of a process that is transmitting sound data to an audio flinger module of an audio subsystem through a voice output channel Audio Track.
本发明提供的确定正在播放声音的应用程序的方法及系统,可以查询正在播放声音的进程的进程标识,根据进程标识与应用程序的对应关系,确定查询到的进程标识对应的应用程序,显示所确定的应用程序的图标。因此,本发明可以自动确定正在播放声音的应用程序并且将该应用程序的图标显示出来,从而帮助用户快速找到正在控制电子设备发出声音的应用程序。因此,本发明可以避免由于用户多次打开应用程序界面带来的资源消耗。The method and system for determining an application that is playing a sound can query the process identifier of the process that is playing the sound, and determine the application corresponding to the process ID that is queried according to the correspondence between the process identifier and the application, and display the Determine the icon of the app. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
附图说明DRAWINGS
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the description of the prior art will be briefly described below. Obviously, the drawings in the following description are only It is a certain embodiment of the present invention, and other drawings can be obtained from those skilled in the art without any creative work.
图1为本发明实施例提供的一种确定正在播放声音的应用程序的方法的流程图;1 is a flowchart of a method for determining an application that is playing a sound according to an embodiment of the present invention;
图2为本发明实施例提供的一种带有预设的显示效果的应用程序的图标 示意图;2 is an icon of an application with a preset display effect according to an embodiment of the present invention. schematic diagram;
图3为本发明实施例提供的另一种确定正在播放声音的应用程序的方法的流程图;3 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention;
图4为本发明实施例提供的另一种确定正在播放声音的应用程序的方法的流程图;4 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention;
图5为本发明实施例提供的另一种确定正在播放声音的应用程序的方法的流程图;FIG. 5 is a flowchart of another method for determining an application that is playing a sound according to an embodiment of the present invention;
图6为本发明实施例提供的一种在图标一侧显示音量调节控件的示意图;FIG. 6 is a schematic diagram of displaying a volume adjustment control on an icon side according to an embodiment of the present invention;
图7为本发明实施例提供的一种确定正在播放声音的应用程序的系统的结构示意图;FIG. 7 is a schematic structural diagram of a system for determining an application that is playing a sound according to an embodiment of the present invention;
图8为本发明实施例提供的另一种确定正在播放声音的应用程序的系统的结构示意图;FIG. 8 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present disclosure;
图9为本发明实施例提供的另一种确定正在播放声音的应用程序的系统的结构示意图;FIG. 9 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present invention;
图10为本发明实施例提供的另一种确定正在播放声音的应用程序的系统的结构示意图。FIG. 10 is a schematic structural diagram of another system for determining an application that is playing a sound according to an embodiment of the present invention.
具体实施方式detailed description
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, but not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
如图1所示,本发明实施例提供的一种确定应用程序的方法,应用于电子设备,该方法可以包括:As shown in FIG. 1 , a method for determining an application is provided in an embodiment of the present invention, and the method may be applied to an electronic device, where the method may include:
S100、查询正在播放声音的进程的进程标识;S100. Query a process identifier of a process that is playing a sound.
本发明中的电子设备可以为手机、平板电脑、计算机等设备,本发明尤其适用于手机中。The electronic device in the present invention may be a mobile phone, a tablet computer, a computer, etc., and the present invention is particularly suitable for use in a mobile phone.
其中,S100的实施过程可以为如下两种具体执行方式中的任一种:The implementation process of the S100 may be any one of the following two specific implementation modes:
方式一、在接收到用户的应用程序查询操作后,查询正在播放声音的进程的进程标识; Method 1: After receiving the user's application query operation, query the process identifier of the process that is playing the sound;
方式二、在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。Manner 2: After detecting that a process is playing a sound, query the process identifier of the process that is playing the sound.
在方式一中,当电子设备为手机等移动终端时,应用程序查询操作可以为:正在运行的应用程序的查询操作,如:应用管理器启动操作、对“设置”选项中的“应用”选项的“正在运行”选项的点击操作,其中,应用管理器启动操作可以有多种,如对Home键的双击操作、对Home键的长按操作等。当然,该应用程序查询操作也可以为其他操作,本发明在此不作限定。In the first method, when the electronic device is a mobile terminal such as a mobile phone, the application query operation may be: a query operation of the running application, such as: an application manager startup operation, and an "application" option in the "setting" option. Click operation of the "Running" option, in which the application manager can start a variety of operations, such as a double-click operation on the Home button, a long-press operation on the Home button, and the like. Of course, the application query operation may also be other operations, and the present invention is not limited herein.
当然,方式一在接收到用户的应用管理器启动操作后,还可以启动应用程序管理器查询电子设备中正在运行的应用程序并显示查询到的应用程序的图标。本发明的功能可以添加到现有的应用管理器中,这样,当应用管理器在查询电子设备中正在运行的应用程序时就会同时查询正在播放声音的进程的进程标识。当然,本发明的功能也可以独立于应用管理器。Of course, after receiving the user's application manager startup operation, the method 1 may also start the application manager to query the running application in the electronic device and display the icon of the queried application. The functionality of the present invention can be added to an existing application manager such that when the application manager queries an application that is running in the electronic device, it simultaneously queries the process identification of the process that is playing the sound. Of course, the functionality of the present invention can also be independent of the application manager.
方式一可以在接收到用户的应用程序查询操作后查询正在播放声音的进程的进程标识,这样,当用户想找到正在播放声音的应用程序时,只需要对电子设备做出应用程序查询操作即可。The first method can query the process identifier of the process that is playing the sound after receiving the user's application query operation, so that when the user wants to find the application that is playing the sound, only the application query operation needs to be performed on the electronic device. .
方式二可以在检测到有进程正在播放声音后,自动查询正在播放声音的进程的进程标识,无需用户进行操作,更加方便。In the second mode, after detecting that a process is playing a sound, the process identifier of the process that is playing the sound is automatically queried, and the user is not required to perform the operation, which is more convenient.
在实际应用中,用户可在方式一和方式二中进行选择,也可以随时切换这两种方式。In practical applications, the user can select between mode one and mode two, or switch between the two modes at any time.
在实际应用中,S100可以包括:查询正在播放预设声音类型的声音的进程的进程标识。In practical applications, S100 may include: querying a process identifier of a process that is playing a sound of a preset sound type.
其中,电子设备中播放的声音可以分为多种声音类型,例如:RING类型、MUSIC类型、ALARM类型和NOTIFICATION类型。上述预设声音类型可以为这四种类型中的任一种,优选的,可以为MUSIC类型。Among them, the sound played in the electronic device can be divided into a plurality of sound types, such as: RING type, MUSIC type, ALARM type, and NOTIFICATION type. The above preset sound type may be any one of the four types, and preferably, may be of the MUSIC type.
其中,RING类型的声音用于播放来电铃声;MUSIC类型的声音用于播放音乐等多媒体内容;ALARM类型的声音用于播放闹钟铃声;NOTIFICATION类型的声音用于播放各种通知声,如短信。Among them, the RING type sound is used to play the incoming call ringtone; the MUSIC type sound is used to play multimedia content such as music; the ALARM type sound is used to play the alarm ringtone; the NOTIFICATION type sound is used to play various notification sounds, such as short messages.
其中,在电子设备为手机时,电子设备的操作系统可以为安卓原生操作系统或基于安卓原生操作系统开发的操作系统。Wherein, when the electronic device is a mobile phone, the operating system of the electronic device may be an Android native operating system or an operating system developed based on the Android native operating system.
电子设备的操作系统还可以为不同的声音类型设置不同的优先级及输出 策略。例如:ALARM类型的优先级高于MUSIC类型;在输出时,ALARM类型的声音优先选择从扬声器输出,而MUSIC类型优先从耳机输出。The operating system of the electronic device can also set different priorities and outputs for different sound types. Strategy. For example, the ALARM type has a higher priority than the MUSIC type; at the output, the ALARM type sound is preferentially output from the speaker, and the MUSIC type is preferentially output from the headphone.
安卓原生操作系统或基于安卓原生操作系统开发的操作系统中的音频子系统的核心模块包括audio policy manager模块以及audio flinger模块,它们都运行在系统进程media server中。The core modules of the audio subsystem in the Android native operating system or operating system based on the Android native operating system include the audio policy manager module and the audio flinger module, which all run in the system process media server.
应用程序要播放声音时,需要从自己所在的进程通过声音输出通道Audio Track将声音数据传递给audio flinger,audio flinger对接收的声音数据进行音量、重采样、混音、音效等方面的处理,然后传递给audio policy manager指定的硬件设备(如扬声器)来播放声音。When the application wants to play the sound, it needs to pass the sound data from the process of its own through the audio output channel Audio Track to the audio flinger, and the audio flinger processes the volume, resampling, mixing, sound effects, etc. of the received sound data, and then Pass the hardware device (such as a speaker) specified by the audio policy manager to play the sound.
因此,S100可以具体包括:通过应用程序编程接口查询正在通过声音输出通道Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。Therefore, the S100 may specifically include: querying, by the application programming interface, a process identifier of a process that is transmitting sound data to the audio flinger module of the audio subsystem through the sound output channel Audio Track.
应用程序的进程可以通过调用AudioTrack的play()函数或start()函数来命令Audio Track进入传输声音数据的状态。The application's process can command the Audio Track to enter the state of transmitting sound data by calling AudioTrack's play() function or start() function.
S200、根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;S200: Determine, according to a correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
可以理解的是,一个应用程序可以具有一个或多个进程,每个进程标识仅可以与一个应用程序对应。It can be understood that an application can have one or more processes, and each process identifier can only correspond to one application.
S300、在所述电子设备的显示屏上,显示所确定的应用程序的图标。S300. Display an icon of the determined application on a display screen of the electronic device.
其中,所显示的图标可以具有预设的显示效果。该预设的显示效果可以有多种,例如闪动效果、波纹效果、放大效果、光圈效果等。Among them, the displayed icon can have a preset display effect. The preset display effect can be various, such as a flashing effect, a ripple effect, a magnification effect, an aperture effect, and the like.
图2为本发明实施例提供的一种带有预设的显示效果的应用程序的图标示意图。从图2可以看出,由于所显示的图标具有预设的显示效果,因此用户可以更加轻易的找到该图标。FIG. 2 is a schematic diagram of an icon of an application with a preset display effect according to an embodiment of the present invention. As can be seen from FIG. 2, since the displayed icon has a preset display effect, the user can find the icon more easily.
本发明实施例提供的确定正在播放声音的应用程序的方法,可以查询正在播放声音的进程的进程标识,根据进程标识与应用程序的对应关系,确定查询到的进程标识对应的应用程序,显示所确定的应用程序的图标。因此,本发明可以自动确定正在播放声音的应用程序并且将该应用程序的图标显示出来,从而帮助用户快速找到正在控制电子设备发出声音的应用程序。因此,本发明可以避免由于用户多次打开应用程序界面带来的资源消耗。 The method for determining the application that is playing the sound provided by the embodiment of the present invention may query the process identifier of the process that is playing the sound, and determine the application corresponding to the process identifier that is queried according to the correspondence between the process identifier and the application, and display the Determine the icon of the app. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
如图3所示,本发明实施例提供的另一种确定应用程序的方法,还可以包括:As shown in FIG. 3, another method for determining an application provided by the embodiment of the present invention may further include:
S400、接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面。S400. Receive a click operation of the user for the icon, and display an interface of the determined application according to the click operation.
用户点击显示的图标后,本发明就可以控制电子设备显示该图标对应的应用程序的界面,这样用户就可以通过界面对应用程序进行控制,如调节音量等。After the user clicks on the displayed icon, the present invention can control the electronic device to display the interface of the application corresponding to the icon, so that the user can control the application through the interface, such as adjusting the volume.
如图4所示,本发明实施例提供的另一种确定正在播放声音的应用程序的方法,还可以包括:As shown in FIG. 4, another method for determining an application that is playing a sound according to an embodiment of the present invention may further include:
S500、接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。S500. The process of receiving the user stops the operation, and stops the operation according to the process to stop the running of the process that is playing the sound.
在用户对正在播放声音的应用程序所要进行的多种操作中,停止声音播放是最紧急的操作。因此,S500可以使得用户在通过S300确定正在播放声音的应用程序后立即进行进程停止操作,从而停止正在播放声音的进程的运行。Among the various operations that the user has to perform on an application that is playing a sound, stopping the sound playback is the most urgent operation. Therefore, the S500 can cause the user to perform a process stop operation immediately after determining that the application that is playing the sound is determined by S300, thereby stopping the operation of the process that is playing the sound.
其中,进程停止操作可以有多种,例如:对S300显示的图标的点击操作、对S300显示的图标的滑动操作、对所述电子设备的摇动操作、对所述电子设备进行翻面使其显示屏朝向下方的操作等。The process stop operation may be various, for example, a click operation on the icon displayed by the S300, a sliding operation on the icon displayed on the S300, a shaking operation on the electronic device, and turning the electronic device to display it. The operation of the screen facing downwards, etc.
如图5所示,本发明实施例提供的另一种确定播放声音的应用程序的方法,还可以包括:As shown in FIG. 5, another method for determining an application for playing a sound according to an embodiment of the present invention may further include:
S600、接收用户的音量调节操作,根据所述音量调节操作,仅对所确定的应用程序的播放音量进行调节。S600. Receive a volume adjustment operation of the user, and adjust, according to the volume adjustment operation, only the played volume of the determined application.
其中,所述音量调节操作为:对所述电子设备的摇动操作、对所述电子设备进行翻面使其显示屏朝向下方的操作或对所述电子设备的实体音量按键的按压操作。The volume adjustment operation is: a shaking operation of the electronic device, an operation of turning the electronic device to face the display screen downward or a pressing operation of a physical volume button of the electronic device.
现有技术中,对电子设备的实体音量按键的按压操作是对所有应用程序或预设类型的所有应用程序的音量的调节操作。当用户通过实体音量按键对某一正在播放声音的应用程序的音量进行调节时,其他应用程序或与该应用程序为相同类型的其他应用程序的音量也被同步调节。而这种同步调节并不是用户所希望的,因此当音量调节操作为对所述电子设备的实体音量按键的按压操作时,本发明可以根据对实体音量按键的按压操作仅对所确定的应用 程序的播放音量进行调节,对其他应用程序的音量则不进行调节。这样就避免来上述情况的发生。In the prior art, the pressing operation of the physical volume button of the electronic device is an adjustment operation of the volume of all applications of all applications or preset types. When the user adjusts the volume of an application that is playing a sound through the physical volume button, the volume of other applications or other applications of the same type as the application is also adjusted simultaneously. And this synchronization adjustment is not desired by the user, so when the volume adjustment operation is a pressing operation on the physical volume button of the electronic device, the present invention can only apply to the determined application according to the pressing operation on the physical volume button. The playback volume of the program is adjusted, and the volume of other applications is not adjusted. This will avoid the above situation.
当然,在实际应用中,S600可以具体包括:接收用户在步骤S300显示图标后的预设时间段内做出的音量调节操作,根据所述音量调节操作,仅对所显示图标对应的应用程序的播放音量进行调节。Of course, in an actual application, the S600 may specifically include: receiving a volume adjustment operation performed by the user within a preset time period after the icon is displayed in step S300, according to the volume adjustment operation, only the application corresponding to the displayed icon Play the volume to adjust.
这样,当用户在上述预设时间段外做出音量调节操作时,可以采用现有技术的音量调节操作响应方式进行响应。In this way, when the user makes a volume adjustment operation outside the preset time period, the user can respond with the volume adjustment operation response mode of the prior art.
在本发明另一实施例中,还可以在S300显示的图标上方或一侧显示音量调节控件,这样,用户就可以直接对显示的音量调节控件进行操作。图6为本发明实施例提供的一种在图标一侧显示音量调节控件的示意图。如图6所示,所显示的调节控件由静音控件002及调音控件001组成。当用户需要控制该应用程序停止播放声音时,可以直接点击静音控件002。当用户需要调节该应用程序所播放的声音的音量时,用户可以拖动调音控件001上的滑块。In another embodiment of the present invention, the volume adjustment control may also be displayed above or on one side of the icon displayed on the S300, so that the user can directly operate the displayed volume adjustment control. FIG. 6 is a schematic diagram of displaying a volume adjustment control on an icon side according to an embodiment of the present invention. As shown in FIG. 6, the displayed adjustment control is composed of a mute control 002 and a tuning control 001. When the user needs to control the application to stop playing the sound, you can directly click the mute control 002. When the user needs to adjust the volume of the sound played by the application, the user can drag the slider on the tuning control 001.
与上述方法实施例相对应,本发明实施例还提供了一种确定正在播放声音的应用程序的系统。Corresponding to the above method embodiment, the embodiment of the present invention further provides a system for determining an application that is playing a sound.
如图7所示,本发明实施例提供的一种确定正在播放声音的应用程序的系统,应用于电子设备,该系统可以包括:进程查询单元100、应用确定单元200和图标显示单元300,As shown in FIG. 7 , a system for determining an application that is playing a sound is applied to an electronic device, and the system may include: a process query unit 100, an application determining unit 200, and an icon display unit 300.
进程查询单元100,用于查询正在播放声音的进程的进程标识;The process query unit 100 is configured to query a process identifier of a process that is playing a sound.
其中,进程查询单元100,可以包括:操作查询子单元或检测查询子单元,The process query unit 100 may include: an operation query subunit or a detection query subunit.
所述操作查询子单元,用于在接收到用户的应用程序查询操作后,查询正在播放声音的进程的进程标识;The operation query subunit is configured to query a process identifier of a process that is playing a sound after receiving an application query operation of the user;
所述检测查询子单元,用于在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。The detection query sub-unit is configured to query a process identifier of a process that is playing a sound after detecting that a process is playing a sound.
对操作查询子单元,当电子设备为手机等移动终端时,应用程序查询操作可以为:正在运行的应用程序的查询操作,如:应用管理器启动操作,对“设置”选项中的“应用”选项的“正在运行”选项的点击操作,其中,应用管理器启动操作可以有多种,如对Home键的双击操作、对Home键的长按操作等。当然,该应用程序查询操作也可以为其他操作,本发明在此不作限定。 For the operation query subunit, when the electronic device is a mobile terminal such as a mobile phone, the application query operation may be: a query operation of the running application, such as: an application manager startup operation, and an "application" in the "Settings" option. The click operation of the "Running" option of the option, wherein the application manager can start a variety of operations, such as a double-click operation on the Home button, a long-press operation on the Home button, and the like. Of course, the application query operation may also be other operations, and the present invention is not limited herein.
操作查询子单元可以在接收到用户的应用程序查询操作后查询正在播放声音的进程的进程标识,这样,当用户想找到正在播放声音的应用程序时,只需要对电子设备做出应用程序查询操作即可。The operation query subunit can query the process identifier of the process that is playing the sound after receiving the user's application query operation, so that when the user wants to find the application that is playing the sound, only the application query operation needs to be performed on the electronic device. Just fine.
检测查询子单元可以在检测到有进程正在播放声音后,自动查询正在播放声音的进程的进程标识,无需用户进行操作,更加方便。The detection query sub-unit can automatically query the process identifier of the process that is playing the sound after detecting that the process is playing the sound, and the user is not required to perform the operation, which is more convenient.
在实际应用中,进程查询单元可以具体用于:查询正在播放预设声音类型的声音的进程的进程标识。优选的,预设声音类型可以为MUSIC类型。In an actual application, the process query unit may be specifically configured to: query a process identifier of a process that is playing a sound of a preset sound type. Preferably, the preset sound type may be a MUSIC type.
其中,所述进程查询单元,可以具体用于:通过应用程序编程接口查询正在通过声音输出通道Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。The process query unit may be specifically configured to: query, by using an application programming interface, a process identifier of a process that is transmitting sound data to an audio flinger module of an audio subsystem through a voice output channel Audio Track.
应用确定单元200,用于根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;The application determining unit 200 is configured to determine, according to the correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
可以理解的是,一个应用程序可以具有一个或多个进程,每个进程标识仅可以与一个应用程序对应。It can be understood that an application can have one or more processes, and each process identifier can only correspond to one application.
图标显示单元300,用于在所述电子设备的显示屏上,显示所确定的应用程序的图标。The icon display unit 300 is configured to display an icon of the determined application on a display screen of the electronic device.
其中,图标显示单元300所显示的图标可以具有预设的显示效果。该预设的显示效果可以有多种,例如闪动效果、波纹效果、放大效果、光圈效果等。The icon displayed by the icon display unit 300 may have a preset display effect. The preset display effect can be various, such as a flashing effect, a ripple effect, a magnification effect, an aperture effect, and the like.
本发明实施例提供的确定应用程序的系统,可以查询正在播放声音的进程的进程标识,根据进程标识与应用程序的对应关系,确定查询到的进程标识对应的应用程序,显示所确定的应用程序的图标。因此,本发明可以自动确定正在播放声音的应用程序并且将该应用程序的图标显示出来,从而帮助用户快速找到正在控制电子设备发出声音的应用程序。因此,本发明可以避免由于用户多次打开应用程序界面带来的资源消耗。The system for determining an application provided by the embodiment of the present invention may query a process identifier of a process that is playing a sound, determine an application corresponding to the process ID that is queried according to the correspondence between the process identifier and the application, and display the determined application. Icon. Therefore, the present invention can automatically determine an application that is playing a sound and display an icon of the application, thereby helping the user to quickly find an application that is controlling the sound of the electronic device. Therefore, the present invention can avoid resource consumption due to the user opening the application interface multiple times.
如图8所示,本发明实施例提供的另一种确定正在播放声音的应用程序的系统,还可以包括:界面显示单元400,用于接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面。As shown in FIG. 8 , another system for determining an application that is playing a sound according to an embodiment of the present invention may further include: an interface display unit 400, configured to receive a click operation of the user for the icon, according to the click. The operation displays the interface of the determined application.
用户点击显示的图标后,本发明就可以控制电子设备显示该图标对应的应用程序的界面,这样用户就可以通过界面对应用程序进行控制,如调节音 量等。After the user clicks on the displayed icon, the present invention can control the electronic device to display the interface of the application corresponding to the icon, so that the user can control the application through the interface, such as adjusting the sound. Quantity and so on.
如图9所示,本发明实施例提供的另一种确定正在播放声音的应用程序的系统,还可以包括:进程停止单元500,用于接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。As shown in FIG. 9, another system for determining an application for playing a sound according to an embodiment of the present invention may further include: a process stop unit 500, configured to receive a process stop of a user, and stop the operation according to the process. The running of the process that is playing the sound.
在用户对正在播放声音的应用程序所要进行的多种操作中,停止声音播放是最紧急的操作。因此,进程停止单元500可以使得用户在通过图标显示单元300确定正在播放声音的应用程序后立即进行进程停止操作,从而停止正在播放声音的进程的运行。Among the various operations that the user has to perform on an application that is playing a sound, stopping the sound playback is the most urgent operation. Therefore, the process stop unit 500 can cause the user to perform a process stop operation immediately after determining that the application of the sound is being played by the icon display unit 300, thereby stopping the operation of the process that is playing the sound.
其中,进程停止操作可以有多种,例如:对图标显示单元300显示的图标的点击操作、对图标显示单元300显示的图标的滑动操作、对所述电子设备的摇动操作、对所述电子设备进行翻面使其显示屏朝向下方的操作等。The process stop operation may be various, for example, a click operation on an icon displayed by the icon display unit 300, a slide operation on an icon displayed on the icon display unit 300, a shaking operation on the electronic device, and the electronic device Perform the operation of turning the face down so that the display screen faces downward.
如图10所示,本发明实施例提供的另一种确定应用程序的系统,还可以包括:音量调节单元600,用于接收用户的音量调节操作,根据所述音量调节操作,仅对所确定的应用程序的播放音量进行调节。As shown in FIG. 10, another system for determining an application provided by an embodiment of the present invention may further include: a volume adjustment unit 600, configured to receive a volume adjustment operation of a user, according to the volume adjustment operation, only determined The playback volume of the app is adjusted.
其中,所述音量调节操作为:对所述电子设备的摇动操作、对所述电子设备进行翻面使其显示屏朝向下方的操作或对所述电子设备的实体音量按键的按压操作。The volume adjustment operation is: a shaking operation of the electronic device, an operation of turning the electronic device to face the display screen downward or a pressing operation of a physical volume button of the electronic device.
在本发明另一实施例中,还可以在图标显示单元300显示的图标上方或一侧显示音量调节控件,这样,用户就可以直接对显示的音量调节控件进行操作。In another embodiment of the present invention, the volume adjustment control may also be displayed above or on one side of the icon displayed by the icon display unit 300, so that the user can directly operate the displayed volume adjustment control.
需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。 It should be noted that, in this context, relational terms such as first and second are used merely to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply such entities or operations. There is any such actual relationship or order between them. Furthermore, the term "comprises" or "comprises" or "comprises" or any other variations thereof is intended to encompass a non-exclusive inclusion, such that a process, method, article, or device that comprises a plurality of elements includes not only those elements but also Other elements, or elements that are inherent to such a process, method, item, or device. An element that is defined by the phrase "comprising a ..." does not exclude the presence of additional equivalent elements in the process, method, item, or device that comprises the element.
本说明书中的各个实施例均采用相关的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于系统实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。The various embodiments in the present specification are described in a related manner, and the same or similar parts between the various embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description of the method embodiment.
以上所述仅为本发明的较佳实施例而已,并非用于限定本发明的保护范围。凡在本发明的精神和原则之内所作的任何修改、等同替换、改进等,均包含在本发明的保护范围内。 The above is only the preferred embodiment of the present invention and is not intended to limit the scope of the present invention. Any modifications, equivalents, improvements, etc. made within the spirit and scope of the invention are intended to be included within the scope of the invention.

Claims (12)

  1. 一种确定正在播放声音的应用程序的方法,应用于电子设备,其特征在于,所述方法包括:A method for determining an application that is playing a sound is applied to an electronic device, the method comprising:
    查询正在播放声音的进程的进程标识;Query the process ID of the process that is playing the sound;
    根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;Determining, according to the correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
    在所述电子设备的显示屏上,显示所确定的应用程序的图标。On the display of the electronic device, an icon of the determined application is displayed.
  2. 根据权利要求1所述的方法,其特征在于,所显示的图标具有预设的显示效果。The method of claim 1 wherein the displayed icon has a preset display effect.
  3. 根据权利要求1或2所述的方法,其特征在于,所述查询正在播放声音的进程的进程标识,包括:The method according to claim 1 or 2, wherein the querying the process identifier of the process that is playing the sound comprises:
    在接收到用户的应用程序查询操作后,查询正在播放声音的进程的进程标识;After receiving the user's application query operation, query the process identifier of the process that is playing the sound;
    或者,or,
    在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。After detecting that a process is playing a sound, query the process ID of the process that is playing the sound.
  4. 根据权利要求1所述的方法,其特征在于,还包括:The method of claim 1 further comprising:
    接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面;Receiving a click operation of the user for the icon, displaying an interface of the determined application according to the click operation;
    或者,or,
    接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。The process of receiving the user stops the operation, and stops the operation of the process that is playing the sound according to the process stop operation.
  5. 根据权利要求3所述的方法,其特征在于,所述电子设备为移动终端,所述应用程序查询操作为:正在运行的应用程序的查询操作。The method according to claim 3, wherein the electronic device is a mobile terminal, and the application query operation is: a query operation of a running application.
  6. 根据权利要求1或2所述的方法,其特征在于,所述查询正在播放声音的进程的进程标识,包括:The method according to claim 1 or 2, wherein the querying the process identifier of the process that is playing the sound comprises:
    通过应用程序编程接口查询正在通过声音输出通道Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。The process identifier of the process that is transmitting sound data to the audio flinger module of the audio subsystem through the sound output channel Audio Track is queried through the application programming interface.
  7. 一种确定正在播放声音的应用程序的系统,应用于电子设备,其特征在于,所述系统包括:进程查询单元、应用确定单元和图标显示单元, A system for determining an application that is playing a sound is applied to an electronic device, the system comprising: a process query unit, an application determining unit, and an icon display unit,
    所述进程查询单元,用于查询正在播放声音的进程的进程标识;The process query unit is configured to query a process identifier of a process that is playing a sound;
    所述应用确定单元,用于根据进程标识与应用程序的对应关系,确定查询到的所述进程标识对应的应用程序;The application determining unit is configured to determine, according to a correspondence between the process identifier and the application, an application corresponding to the process identifier that is queried;
    所述图标显示单元,用于在所述电子设备的显示屏上,显示所确定的应用程序的图标。The icon display unit is configured to display an icon of the determined application on a display screen of the electronic device.
  8. 根据权利要求7所述的系统,其特征在于,所显示的图标具有预设的显示效果。The system of claim 7 wherein the displayed icon has a predetermined display effect.
  9. 根据权利要求7或8所述的系统,其特征在于,所述进程查询单元,包括:操作查询子单元或检测查询子单元,The system according to claim 7 or 8, wherein the process query unit comprises: an operation query subunit or a detection query subunit,
    所述操作查询子单元,用于在接收到用户的应用程序查询操作后,查询正在播放声音的进程的进程标识;The operation query subunit is configured to query a process identifier of a process that is playing a sound after receiving an application query operation of the user;
    所述检测查询子单元,用于在检测到有进程正在播放声音后,查询正在播放声音的进程的进程标识。The detection query sub-unit is configured to query a process identifier of a process that is playing a sound after detecting that a process is playing a sound.
  10. 根据权利要求7所述的系统,其特征在于,还包括:界面显示单元或进程停止单元,The system according to claim 7, further comprising: an interface display unit or a process stop unit,
    所述界面显示单元,用于接收用户针对所述图标的点击操作,根据所述点击操作显示所确定的应用程序的界面;The interface display unit is configured to receive a click operation of the user for the icon, and display an interface of the determined application according to the click operation;
    所述进程停止单元,用于接收用户的进程停止操作,根据所述进程停止操作停止正在播放声音的进程的运行。The process stop unit is configured to receive a process stop of the user, and stop the operation of the process that is playing the sound according to the process stop operation.
  11. 根据权利要求9所述的系统,其特征在于,所述电子设备为移动终端,所述应用程序查询操作为:正在运行的应用程序的查询操作。The system according to claim 9, wherein the electronic device is a mobile terminal, and the application query operation is: a query operation of a running application.
  12. 根据权利要求7或8所述的系统,其特征在于,所述进程查询单元,具体用于:通过应用程序编程接口查询正在通过声音输出通道Audio Track向音频子系统的audio flinger模块传输声音数据的进程的进程标识。 The system according to claim 7 or 8, wherein the process query unit is configured to: query, through the application programming interface, that the sound data is being transmitted to the audio flinger module of the audio subsystem through the sound output channel Audio Track The process ID of the process.
PCT/CN2016/076484 2015-04-07 2016-03-16 Method and system for determining application program currently playing audio content WO2016161877A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510160549.1 2015-04-07
CN201510160549.1A CN104731604B (en) 2015-04-07 2015-04-07 Determine the method and system for being playing the application program of sound

Publications (1)

Publication Number Publication Date
WO2016161877A1 true WO2016161877A1 (en) 2016-10-13

Family

ID=53455523

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/076484 WO2016161877A1 (en) 2015-04-07 2016-03-16 Method and system for determining application program currently playing audio content

Country Status (2)

Country Link
CN (1) CN104731604B (en)
WO (1) WO2016161877A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112000411A (en) * 2020-08-18 2020-11-27 青岛海信移动通信技术股份有限公司 Mobile terminal and display method of recording channel occupation information thereof

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104731604B (en) * 2015-04-07 2019-04-19 北京字节跳动网络技术有限公司 Determine the method and system for being playing the application program of sound
CN105426218A (en) * 2015-12-10 2016-03-23 小米科技有限责任公司 Method and device for controlling audio playing
CN105657632B (en) * 2016-01-08 2019-05-14 深圳市金立通信设备有限公司 A kind of audio testing method, terminal and system
CN110392878B (en) * 2017-03-15 2022-03-11 华为技术有限公司 Sound control method and mobile terminal
CN107040815A (en) * 2017-05-09 2017-08-11 微鲸科技有限公司 Multimedia method and its device are played in a kind of many applications jointly
CN108766436A (en) * 2018-05-31 2018-11-06 广州酷狗计算机科技有限公司 A kind of sound control method and system of multimedia equipment
CN113721880A (en) * 2020-05-26 2021-11-30 青岛海信移动通信技术股份有限公司 Application program sound control implementation method and electronic equipment
CN112433698A (en) * 2020-11-30 2021-03-02 上海米哈游天命科技有限公司 Resource display method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101650725A (en) * 2009-04-30 2010-02-17 北京搜狗科技发展有限公司 Method and system for controlling sound in browser
CN103177104A (en) * 2013-03-26 2013-06-26 北京小米科技有限责任公司 Searching method and device of application program
CN103345403A (en) * 2013-06-08 2013-10-09 广东欧珀移动通信有限公司 Method and terminal device for deeply controlling sound playing through earphones
WO2015043316A1 (en) * 2013-09-26 2015-04-02 Tencent Technology (Shenzhen) Company Limited Method, device and electronic equipment for controlling displaying
CN104731604A (en) * 2015-04-07 2015-06-24 锤子软件(北京)有限公司 Method and system for determining application program playing sound currently

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101355766A (en) * 2008-09-11 2009-01-28 青岛海信移动通信技术股份有限公司 Mobile terminal and control method for playing multimedia thereof
CN103294940A (en) * 2013-05-23 2013-09-11 广东欧珀移动通信有限公司 Android system authority control method and intelligent mobile terminal
CN104346256B (en) * 2013-07-23 2018-06-01 贝壳网际(北京)安全技术有限公司 Method and device for acquiring power consumption information of application program and mobile terminal
CN103412708B (en) * 2013-07-31 2016-12-28 华为技术有限公司 Task management method on terminal unit and terminal unit
CN104135504B (en) * 2014-02-11 2015-12-30 腾讯科技(深圳)有限公司 A kind of service providing method, Apparatus and system based on application

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101650725A (en) * 2009-04-30 2010-02-17 北京搜狗科技发展有限公司 Method and system for controlling sound in browser
CN103177104A (en) * 2013-03-26 2013-06-26 北京小米科技有限责任公司 Searching method and device of application program
CN103345403A (en) * 2013-06-08 2013-10-09 广东欧珀移动通信有限公司 Method and terminal device for deeply controlling sound playing through earphones
WO2015043316A1 (en) * 2013-09-26 2015-04-02 Tencent Technology (Shenzhen) Company Limited Method, device and electronic equipment for controlling displaying
CN104731604A (en) * 2015-04-07 2015-06-24 锤子软件(北京)有限公司 Method and system for determining application program playing sound currently

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112000411A (en) * 2020-08-18 2020-11-27 青岛海信移动通信技术股份有限公司 Mobile terminal and display method of recording channel occupation information thereof

Also Published As

Publication number Publication date
CN104731604A (en) 2015-06-24
CN104731604B (en) 2019-04-19

Similar Documents

Publication Publication Date Title
WO2016161877A1 (en) Method and system for determining application program currently playing audio content
US11750734B2 (en) Methods for initiating output of at least a component of a signal representative of media currently being played back by another device
US11683408B2 (en) Methods and interfaces for home media control
CA2894751C (en) Managing audio at the tab level for user notification and control
US9032315B2 (en) Portable terminal reflecting user's environment and method for operating the same
CN107636541B (en) Method on computing device, system for alarm and machine readable medium
TW201629750A (en) Dynamic thresholds for always listening speech trigger
JP2009253970A (en) Mobile terminal and menu control method therefor
WO2017032080A1 (en) Method and device for address book control and mobile terminal
US11974338B2 (en) Pairing devices by proxy
CN106161776B (en) Volume adjusting method and mobile terminal
US10311254B2 (en) Electronic apparatus and information access control method thereof
WO2019200614A1 (en) Do-not-disturb method and terminal
US11297369B2 (en) Remotely controlling playback devices
CN106537933B (en) Portable loudspeaker
KR100618278B1 (en) Mobile communication device of supporting multitasking by resizing display-screen and method for operating the device
US7634071B2 (en) Auto switch system and method thereof for IP phone and default audio device
JP6407293B2 (en) Keyboard style switching method and apparatus
WO2019011270A1 (en) Method and terminal for playing audio, and computer-readable storage medium
WO2023207807A1 (en) Audio playback method, system, and electronic device
WO2019033434A1 (en) Volume control method and apparatus, storage medium, and mobile terminal
US12034994B2 (en) Remotely controlling playback devices
WO2022204861A1 (en) Call method, terminal, and non-transitory computer-readable storage medium
CN115705180A (en) Audio processing method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16776052

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16776052

Country of ref document: EP

Kind code of ref document: A1