WO2020057578A1 - 一种音频通道的管理方法、终端及存储介质 - Google Patents

一种音频通道的管理方法、终端及存储介质 Download PDF

Info

Publication number
WO2020057578A1
WO2020057578A1 PCT/CN2019/106574 CN2019106574W WO2020057578A1 WO 2020057578 A1 WO2020057578 A1 WO 2020057578A1 CN 2019106574 W CN2019106574 W CN 2019106574W WO 2020057578 A1 WO2020057578 A1 WO 2020057578A1
Authority
WO
WIPO (PCT)
Prior art keywords
audio
channel
file
audio file
audio channel
Prior art date
Application number
PCT/CN2019/106574
Other languages
English (en)
French (fr)
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 WO2020057578A1 publication Critical patent/WO2020057578A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72442User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality for playing music files
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/725Cordless telephones

Definitions

  • the present invention relates to the technical field of terminals, and in particular, to a method for managing an audio channel, a terminal, and a storage medium.
  • dual display terminals With the rapid development of terminal technology and the improvement of user needs, terminals equipped with flexible screens with two independent display areas or two physically independent screens (terminals with flexible screens with dual display areas and terminals with two independent screens, (Hereafter referred to as dual display terminals) will become a popular trend.
  • a dual-screen mobile phone can enable the mobile phone to adapt to more use scenarios, which will bring better user experience compared to a single-screen mobile phone.
  • the mainstream terminal audio management strategy is based on a single-display terminal design.
  • dual-display terminals that can call or output different audio resources on separate screens
  • audio management strategies are still based on the processing scheme of single-display terminals when playing audio and video resources, playing audio resources started later, interrupting audio playback that has been started previously, and user experience.
  • the audio channel management scheme proposed in this article is aimed at the simultaneous playback of different audio resources by dual display terminals, and to a certain extent, it solves the user's pain points and other problems.
  • an object of the embodiments of the present invention is to provide a method, a system, and a storage medium for managing an audio channel, so as to solve a technical problem that a dual display terminal performs reasonable playback of different audio resources simultaneously.
  • a method for managing an audio channel includes:
  • the default audio channel is assigned to the first audio file or the currently playing audio file, and other audio channels other than the default audio channel are assigned to the first audio file according to a preset priority policy.
  • an apparatus for managing an audio channel includes:
  • An audio channel detection module configured to detect a currently available audio channel when there is a request for simultaneous playback of multiple audio files
  • Audio channel matching module which is used to assign the default audio channel to the first audio file or the currently playing audio file when it detects more than one audio channel, and to set other audio channels outside the default audio channel as preset A priority policy is assigned to a second audio file other than the first audio file or the audio file being played;
  • An audio playing module is configured to play the plurality of audio files respectively through hardware interfaces corresponding to the one or more audio channels.
  • a terminal includes a memory, a processor, and a computer program stored on the memory and executable on the processor.
  • the computer program is described by the computer program. When executed by a processor, the steps of the method for managing an audio channel are implemented.
  • a storage medium stores a computer program.
  • the computer program is executed by a processor, the steps of the foregoing audio channel management method are implemented.
  • the audio playback management method, terminal, and storage medium provided by the embodiments of the present invention introduce an audio channel strategy to allocate different audio channels for different audio playback requests, solving the problem that dual display terminals cannot simultaneously play different audio and video resources without interfering with each other. , Improving the user experience.
  • FIG. 1 is a schematic flowchart of an audio channel management method according to Embodiment 1 of the present invention
  • FIG. 2 is a schematic flowchart of a first preferred implementation manner of an audio channel management method according to a first embodiment
  • FIG. 3 is a schematic flowchart of a second preferred implementation manner of an audio channel management method according to the first embodiment
  • FIG. 5 is a schematic diagram of an Android audio system provided by Embodiment 2 of the present invention.
  • FIG. 6 is a structural block diagram of an audio channel management system according to a third embodiment of the present invention.
  • FIG. 1 is a flowchart of a method for managing an audio channel according to Embodiment 1 of the present invention. As shown in the figure, the method includes:
  • Step 101 When there is a request for simultaneous playback of multiple audio files, detect currently available audio channels;
  • step 102 when more than one audio channel is detected, the default audio channel is allocated to the first audio file or the currently playing audio file, and other audio channels other than the default audio channel are allocated according to a preset priority policy. Give a second audio file other than the first audio file or the audio file being played;
  • step 103 the plurality of audio files are respectively played through hardware interfaces corresponding to the one or more audio channels.
  • the presentation modes of Axon M include four modes: big A, AA, AB, and small A.
  • Extended mode dual screen as a whole display screen to display the application interface;
  • the pain points related to the present invention only occur in the AB split-screen mode, when different applications presented by the AB screen output or call different audio resources, respectively. In other modes, the content presented on the dual screen is unique, so there is no problem.
  • FIG. 2 it is a flowchart of a first preferred implementation manner of Example 1. As shown in the figure, it includes:
  • Step 201 Detect a current presentation mode of the video and audio terminal
  • Step 202 When the presentation mode is AB, detect a currently available audio channel;
  • Available audio channels include Speaker, headphones, Bluetooth, USB audio peripherals.
  • step 203 if a plurality of available audio channels are included, the default audio channel is assigned to the audio file played by the main screen, and other audio channels are assigned to the audio file played by the secondary screen according to a preset priority policy;
  • step 204 playback is performed by corresponding hardware.
  • conflicting audio playback requests are processed and played in different audio channels at the same time, which better adapts to dual-screen audio terminal devices and improves the user experience.
  • FIG. 3 it is a flowchart of a second preferred implementation manner of Example 1. As shown in the figure, it includes:
  • Step 301 when a new playback request is detected, detecting a current presentation mode of the audio terminal;
  • the premise of this embodiment is that the current user is playing video and audio, and a new playback request is detected at the same time.
  • Step 302 when the presentation mode is AB, detect other currently available audio channels;
  • the presentation mode is not AB, the currently playing video and audio are closed, and the new audio is played according to the new playback request. If the rendering mode is AB, continue to detect other available audio channels.
  • Step 303 If other audio playback channels are included, assign audio channels to the new playback request according to a preset priority policy;
  • Speaker Sound, headphones, Bluetooth, and USB audio peripherals.
  • Speaker While Speaker is in use, the speaker is regarded as the default audio channel, which does not affect its continuous playback. Instead, the headset is used as a preset priority policy.
  • the audio channel is assigned to a new audio playback request.
  • Step 304 Play new audio through the assigned audio channel.
  • the video and audio files being played can be played on the main screen or left on the secondary screen; if a video and audio file is being played on the secondary screen, it is obvious that it is necessary to detect whether the main screen has a connected headset or Bluetooth And play a new audio file with your headset or Bluetooth.
  • a new audio playback channel is searched for a new audio playback request, which completely avoids the impact on the audio currently being played, and greatly improves the user experience.
  • FIG. 4 is a schematic diagram of an existing Android audio system.
  • the uppermost layer is the audio application layer, that is, the Application layer, including various applications, such as Music, Game, Call, Recorder, and so on.
  • Audio Systerm of Android Various audio applications are connected to the audio system Audio Systerm of Android through the package call of Audio Track.
  • the middle layer is the Framework layer, and the middle layer is the Framework layer.
  • the calls between the application layer and the Framework layer interact through AudioSystem.
  • AudioSystem consists of two parts, namely AudioSystem (Java) and AudioSystem (Native).
  • AudioSystem (Java) provides an interface for managing AudioSystem (Native), which is only called internally by AudioService and is not open to users.
  • AudioSystem (Native) provides control of the audio system, such as volume, device status, and forceUse. Audio local framework layer AudioFlinger processes all AudioTrack's audio input and sends PCM to Audiohardware for playback.
  • Audio Systerm instructs Audio Flinger to select different playback devices through Audio Policy, which can be regarded as a route between Audio Track and playback devices.
  • FIG. 5 is a schematic diagram of an Android audio system according to the present invention.
  • Audio Channel Policy system Audio ChannelPolicy is introduced, including Audio Channel Settings Audio Channel Settings and Audio Channel Policy Library Audio Channel Policies.
  • Audio ChannelSetting is used to provide the upper layer with priority setting for audio channels, access to the audio policy system Audio Policy Service, and channel policy formulation.
  • the audio channel policy library stores existing audio channels according to their priorities.
  • the application layer sends an audio playback request
  • Audio Policy instructs Audio Flinger to assign different audio channels to different screens.
  • the request corresponding to the first audio or the currently playing audio in the audio request sent by the application layer is sent to the default audio channel; the audio request sent by the application layer is divided by the first A request corresponding to an audio file or a second audio other than the audio file being played is sent to a corresponding audio channel according to a preset priority policy.
  • This embodiment can extend the audio mixing system Audio Mixer in the audio system, so that the audio data streams in the multiple audio files no longer perform mixing processing with each other.
  • This embodiment improves the audio system architecture of Android, which fundamentally solves the pain point that users cannot play on two screens at the same time.
  • Audio Mixer By expanding Audio Mixer, the audio of different apps is no longer mixed, and different audios are passed respectively. Channels and hardware play, improving the user experience.
  • FIG. 6 is an audio channel management device provided in Embodiment 3 of the present invention.
  • the device includes:
  • An audio channel detection module 601 configured to detect a currently available audio channel when there is a request for simultaneous playback of multiple audio files
  • the presentation mode of the playback terminal should be detected; when the presentation mode is AB, other audio channels currently available are detected;
  • One is to apply for two or more playback requests at the same time
  • the second is that an audio is already playing and a new playback request appears.
  • An audio channel matching module 602 is configured to assign a default audio channel to a first audio file or an audio file currently being played when it detects more than one audio channel, and preset other audio channels outside the default audio channel as presets. Priority policy assigned to the second audio file other than the first audio file or the audio file being played;
  • Available audio channels include Speaker, headphones, Bluetooth, USB audio peripherals.
  • the default audio channel is assigned to the audio file played by the main screen; other audio channels are assigned to the audio file played by the secondary screen according to a preset priority policy;
  • the presentation mode is not AB, the currently playing video and audio are closed, and the new audio is played according to the new playback request. If the rendering mode is AB, continue to detect other available audio channels.
  • Speaker Sound, headphones, Bluetooth, and USB audio peripherals.
  • Speaker While Speaker is in use, the speaker is regarded as the default audio channel, which does not affect its continuous playback. Instead, the headset is used as a preset priority policy.
  • the audio channel is assigned to a new audio playback request.
  • the video and audio files being played can be played on the main screen or left on the secondary screen; if a video and audio file is being played on the secondary screen, it is obvious that it is necessary to detect whether the main screen has a connected headset or Bluetooth And play a new audio file with your headset or Bluetooth.
  • An audio playback module 603 is configured to play the multiple audio files respectively through hardware interfaces corresponding to the one or more audio channels.
  • the audio channel matching module 602 includes:
  • the main matching sub-module 6021 is configured to send the request corresponding to the first audio or the currently playing audio out of the audio requests sent by the application layer to the default audio channel through the audio channel management policy Audio Channel Policy.
  • the sub-matching sub-module 6022 is configured to send a request corresponding to the second audio except the first audio file or the audio file being played out of the audio requests sent by the application layer to the corresponding audio channel according to a preset priority policy.
  • the system further includes an audio channel setting module 600 for presetting the priority policy, including:
  • a setting submodule 6001 configured to obtain a user's priority setting for an audio channel
  • the saving submodule 6002 is configured to save the priority setting to the audio channel policy library Lib Audio Channel Policy.
  • This embodiment introduces an audio channel strategy to allocate different audio channels for different audio playback requests, solving the problem that dual display terminals cannot simultaneously play different audio and video resources without interfering with each other, improving the user experience.
  • An embodiment of the present invention provides a terminal.
  • the terminal includes a memory, a processor, and a computer program stored on the memory and executable on the processor.
  • the computer program is executed by the processor, the steps of the audio channel management method are implemented.
  • This embodiment provides a storage medium.
  • a computer program is stored on the storage medium.
  • the computer program is executed by a processor, the steps of the foregoing audio channel management method are implemented.
  • the above storage medium belongs to the same concept as the virtual machine remote control method embodiment, and its specific implementation process is detailed in the method embodiment, and the technical features in the method embodiment are correspondingly applicable to the storage medium, and will not be repeated here .
  • the audio playback management method, device, terminal, and storage medium provided by the embodiments of the present invention introduce an audio channel strategy to allocate different audio channels for different audio playback requests, which solves the problem that dual display terminals cannot simultaneously play different audio and video resources without interfering with each other. Problems that enhance the user experience.
  • the division between functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be composed of several physical The components execute cooperatively.
  • Some or all physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit .
  • Such software may be distributed on computer-readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media).
  • computer storage medium includes volatile and non-volatile implemented in any method or technology used to store information such as computer-readable instructions, data structures, program modules or other data.
  • Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or may Any other medium used to store desired information and which can be accessed by a computer.
  • a communication medium typically contains computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transmission mechanism, and may include any information delivery medium .

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • Circuit For Audible Band Transducer (AREA)

Abstract

本发明实施例公开了一种音频通道管理方法、终端及存储介质,属于终端技术领域。该方法包括:当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。本发明引入了音频信道策略为不同音频播放请求分配不同的音频通道,解决了双显终端无法同时互不干扰播放不同音视频资源的问题,提升了用户体验。

Description

一种音频通道的管理方法、终端及存储介质
本申请要求享有2018年09月19日提交的名称为“一种音频通道的管理方法、装置、终端及存储介质”的中国专利申请CN201811099816.9的优先权,其全部内容通过引用并入本文中。
技术领域
本发明涉及终端技术领域,特别涉及一种音频通道的管理方法、终端及存储介质。
背景技术
随着终端技术的快速发展和用户需求的提高,配置包括两个独立显示区域的柔性屏或者两块物理独立屏幕的终端(配置双显示区域的柔性屏的终端以及配置两块独立屏幕的终端,后面统一称为双显终端)将成为流行的趋势。如双屏手机,可以使手机能够适应更多的使用场景,相对单屏手机会带来更好的用户体验效果。
而目前主流的终端音频管理策略还是基于单显终端而设计的策略,对于可分屏调用或输出不同音频资源的双显终端来说,在使用上存在不足。比如,对于双显终端分别启动不同的视频播放软件,进行音视频资源播放时,音频管理策略还是基于单显终端的处理方案,播放后面启动的音频资源,中断前面已启动的音频播放,用户体验较差。本文提出的音频通道管理方案,针对双显终端同时进行不同音频资源的合理播放,在一定程度上,解决用户的使用痛点等问题。
发明内容
有鉴于此,本发明实施例的目的在于提供一种音频通道的管理方法、系统和存储介质,以解决双显终端同时进行不同音频资源的合理播放的技术问题。
为达到上述目的,根据本发明实施例的一个方面,提供一种音频通道的管理方法,该方法包括:
当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;
当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前 正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;
将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。
根据本发明实施例的另一个方面,提供一种音频通道的管理装置,该装置包括:
音频通道检测模块,用于当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;
音频通道匹配模块,用于当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;
音频播放模块,用于将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。
根据本发明实施例的再一个方面,提供一种终端,该终端包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,该所述计算机程序被所述处理器执行时,实现上述音频通道的管理方法的步骤。
根据本发明实施例的又一个方面,提供一种存储介质,所述存储介质上存储有计算机程序,所述计算机程序被处理器执行时,实现上述的音频通道的管理方法的步骤。
本发明实施例提供的音频播放的管理方法、终端及存储介质,引入了音频信道策略为不同音频播放请求分配不同的音频通道,解决了双显终端无法同时互不干扰播放不同音视频资源的问题,提升了用户体验。
附图说明
图1为本发明实施例一提供的一种音频通道的管理方法的流程示意图;
图2为实施例一音频通道的管理方法的第一优选实施方式流程示意图;
图3为实施例一音频通道的管理方法的第二优选实施方式流程示意图;
图4为现有的Android音频系统示意图;
图5为本发明实施例二提供的一种Android音频系统示意图;
图6为本发明实施例三提供的一种音频通道的管理系统的结构框图。
本发明目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
为了使本发明所要解决的技术问题、技术方案及有益效果更加清楚、明白,以下结合附图和实施例,对本发明进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅以解释本发明,并不用于限定本发明。
图1是本发明实施例一提供的一种音频通道的管理方法的流程图,如图所示,该方法包括:
步骤101,当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;
步骤102,当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;
步骤103,将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。
以下将结合2个实施方式以双显终端对本发明进行说明。
为更好的对本实施方式进行说明,在阐述本发明相关的现有实现技术之前,首先对本实施方式所涉及的双显终端的呈现模式进行说明:
以ZTE的Axon M双屏手机为例,Axon M的呈现模式包括:大A,AA,AB,小A四种模式。
延展模式(大A):将双屏作为一个整体显示屏,来显示应用界面;
镜像模式(AA):两个屏幕显示同样内容;
分屏模式(AB):两个屏幕显示不同应用的内容;
单屏模式(小A):一个屏幕熄灭,另外一个屏幕保持显示功能。
本发明涉及的痛点问题,仅仅针对AB分屏模式,当AB屏呈现的不同应用分别输出或者调用不同音频资源的时候,才会出现。其他模式下,双屏呈现的内容具有唯一性,因此不存在问题。
如图2所示,为实施例一的第一优选实施方式流程图,如图所示,包括:
步骤201,检测视音频终端的当前呈现方式;
步骤202,当呈现方式为AB时,检测当前可用的音频通道;
如:可用的音频通道包括Speaker、耳机、蓝牙、USB音频外设。
步骤203,如包括多个可用的音频通道,则将默认音频通道分配给主屏幕播放的音频文件,其他音频通道按预设的优先级策略分配给副屏幕播放的音频文件;
如,将Speaker作为默认音频通道分配给主屏幕,耳机分配给副屏幕。
步骤204,通过相应的硬件分别进行播放。
本实施方式对有冲突的音频播放请求,同时分不同音频通道进行处理和播放,更好的适应双屏音频终端设备,提升了用户的体验。
如图3所示,为实施例一的第二优选实施方式流程图,如图所示,包括:
步骤301,当检测到新的播放请求时,检测音频终端的当前呈现方式;
本实施方式的前提是,当前用户正在播放视音频,同时检测到新的播放请求。
步骤302,当呈现方式为AB时,检测当前可用的其他音频通道;
若呈现方式不为AB,则关闭当前正在播放的视音频,根据新的播放请求播放新的音频。如果呈现方式为AB,则继续检测其他可用的音频通道。
步骤303,如果包括其他的音频播放通道,则按照预设的优先级策略给新的播放请求分配音频通道;
需要说明的是,如果只有一个音频通道且正在使用,则提示用户,根据用户的操作执行;
假设包括Speaker、耳机、蓝牙、USB音频外设四个音频通道,而Speaker正在使用,则将Speaker视为默认音频通道,不影响其继续播放,而是根据预设的优先级策略,将耳机作为优选音频通道分配给新的音频播放请求。
步骤304,通过分配的音频通道播放新的音频。
需要说明的是,正在播放的视音频文件可以在主屏幕播放,也可以在副屏幕不放;如果在副屏幕正在播放一个视音频文件,很显然,要检测主屏幕是否有连接的耳机或蓝牙,然后用耳机或蓝牙播放新的音频文件。
本实施方式通过对新的音频播放请求寻找新的音频播放通道的方式,完全避免了对现在正在播放的音频的影响,大大提升了用户的体验。
实施例二
本实施例将从Android系统的音频系统实现上对本发明进行进一步说明。
图4为现有的Android音频系统示意图。
如图4所示,最上层是音频应用层,即Application层,包括各种应用程序,如Music,Game,Call,Recorder等。
各类音频应用通过音轨Audio Track的封装调用,接入到Android的音频系统Audio Systerm中。
中间层是Framework层,中间层是Framework层,应用层与Framework层之间的调用通过AudioSystem进行交互。AudioSystem由两部分组成,分别是AudioSystem(Java)和AudioSystem(Native)。AudioSystem(Java)提供管理AudioSystem(Native)的接口,只由AudioService内部调用,不对用户开放。AudioSystem(Native)提供对音频系统的控制,如音量、设备状态、forceUse等。Audio本地框架层AudioFlinger把所有AudioTrack的音频输入进行处理后,输送PCM到Audiohardware中进行播放。
Audio Systerm通过Audio Policy来指示Audio Flinger选择不同的播放设备,可以视为Audio Track和播放设备之间的路由。
如图5所示,为本发明的Android音频系统示意图。
如图所示,引入了音频通道的策略系统Audio Channel Policy,包括音频通道设置Audio Channel Setting以及音频通道策略库Audio Channel Policy。Audio Channel Setting用于提供给上层进行音频通道的优先级设置以及音频策略系统Audio Policy Service的访问和通道策略制定。音频通道策略库对已有音频通道按照优先级进行存储。
从时间先后顺序上,
①用户通过Audio Channel Setting对音频通道进行优先级设置;
②将所述优先级设置保存至音频通道策略库Lib Audio Channel Policy。
③应用层发送音频播放请求;
④根据预设的优先级,Audio Policy指示Audio Flinger将不同的音频通道分配给不同的屏幕。
如,通过音频通道的管理策略Audio Channel Policy,将应用层发送的音频请求中,第一音频或当前正在播放的音频对应的请求发送至默认音频通道;将应用层发送的音频请 求中,除第一音频文件或正在播放的音频文件外的第二音频对应的请求根据预设的优先级策略发送至相应的音频通道。
本实施例可对音频系统中的混音系统Audio Mixer进行扩展,以使所述多个音频文件中的音频数据流相互不再进行混音处理。
本实施例在Android的音频系统架构上进行了改进,从根本上解决了用户不能双屏同时播放的痛点,且通过扩展Audio Mixer,使不同App的音频不再进行混音,分别通过不同的音频信道及硬件进行播放,提升了用户的体验。
实施例三
图6为本发明实施例三提供的一种音频通道的管理装置,该装置包括:
音频通道检测模块601,用于当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;
以ZTE的Axon M双屏手机为例,当AB屏呈现的不同应用分别输出或者调用不同音频资源的时候,视为多个音频文件同时播放的请求。
本实施例当出现多于一个音频播放请求时,应当检测播放终端的呈现方式;呈现方式为AB时,检测当前可用的其他音频通道;
这里又包括两种情况:
一是两个或多个播放请求同时申请;
二是已经有一个音频在播放,出现一个新的播放请求。
音频通道匹配模块602,用于当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;
如上所述,以双拼显示终端为例,在上述第一种情况下,如同时出现两个音频播放请求,则检测当前可用的音频通道;
如:可用的音频通道包括Speaker、耳机、蓝牙、USB音频外设。
如包括多个可用的音频通道,则将默认音频通道分配给主屏幕播放的音频文件其他音频通道按预设的优先级策略分配给副屏幕播放的音频文件;
如,将Speaker作为默认音频通道分配给主屏幕,耳机分配给副屏幕。
在上述第二种情况下,即当前用户正在播放视音频,同时检测到新的播放请求,且呈现方式为AB时,检测当前可用的其他音频通道;
若呈现方式不为AB,则关闭当前正在播放的视音频,根据新的播放请求播放新的音频。如果呈现方式为AB,则继续检测其他可用的音频通道。
如果包括其他的音频播放通道,则按照预设的优先级策略给新的播放请求分配音频通道;
需要说明的是,如果只有一个音频通道且正在使用,则提示用户,根据用户的指令执行相应操作;
假设包括Speaker、耳机、蓝牙、USB音频外设四个音频通道,而Speaker正在使用,则将Speaker视为默认音频通道,不影响其继续播放,而是根据预设的优先级策略,将耳机作为优选音频通道分配给新的音频播放请求。
需要说明的是,正在播放的视音频文件可以在主屏幕播放,也可以在副屏幕不放;如果在副屏幕正在播放一个视音频文件,很显然,要检测主屏幕是否有连接的耳机或蓝牙,然后用耳机或蓝牙播放新的音频文件。
音频播放模块603,用于将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。
所述音频通道匹配模块602包括:
主匹配子模块6021,用于通过音频通道的管理策略Audio Channel Policy,将应用层发送的音频请求中,第一音频或当前正在播放的音频对应的请求发送至默认音频通道;
副匹配子模块6022,用于将应用层发送的音频请求中,除第一音频文件或正在播放的音频文件外的第二音频对应的请求根据预设的优先级策略发送至相应的音频通道。
该系统还包括音频通道设置模块600,用于对所述优先级策略进行预设,包括:
设置子模块6001,用于获取用户对音频通道的优先级设置;
保存子模块6002,用于将所述优先级设置保存至音频通道策略库Lib Audio Channel Policy。
本实施例引入了音频信道策略为不同音频播放请求分配不同的音频通道,解决了双显 终端无法同时互不干扰播放不同音视频资源的问题,提升了用户体验。
实施例四
本发明实施例提供一种终端,该终端包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,该计算机程序被处理器执行时,实现音频通道的管理方法的步骤。
需要说明的是,上述终端与音频通道的管理方法实施例属于同一构思,其具体实现过程详细见方法实施例,且方法实施例中的技术特征在终端均对应适用,这里不再赘述。
实施例五
本实施例提供一种存储介质,所述存储介质上存储有计算机程序,所述计算机程序被处理器执行时,实现上述的音频通道的管理方法的步骤。
需要说明的是,上述存储介质,与虚拟机远程控制方法实施例属于同一构思,其具体实现过程详细见方法实施例,且方法实施例中的技术特征在存储介质均对应适用,这里不再赘述。
本发明实施例提供的音频播放的管理方法、装置、终端及存储介质,引入了音频信道策略为不同音频播放请求分配不同的音频通道,解决了双显终端无法同时互不干扰播放不同音视频资源的问题,提升了用户体验。
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统、装置中的功能模块/单元可以被实施为软件、固件、硬件及其适当的组合。
在硬件实施方式中,在以上描述中提及的功能模块/单元之间的划分不一定对应于物理组件的划分;例如,一个物理组件可以具有多个功能,或者一个功能或步骤可以由若干物理组件合作执行。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公 知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。
以上参照附图说明了本发明的优选实施例,并非因此局限本发明的权利范围。本领域技术人员不脱离本发明的范围和实质内所作的任何修改、等同替换和改进,均应在本发明的权利范围之内。

Claims (8)

  1. 一种音频通道的管理方法,该方法包括:
    当存在多个音频文件同时播放的请求时,检测当前可用的音频通道;
    当检测到存在一种以上的音频通道时,将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件;
    将所述多个音频文件分别通过与所述一种以上的音频通道一一对应的硬件接口进行播放。
  2. 根据权利要求1所述的方法,其中,所述存在多个音频文件同时播放的请求包括:
    当前视音频播放终端为双显终端,其呈现模式为分屏分别显示不同内容的模式。
  3. 根据权利要求2所述的方法,其中:将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件,包括:
    所述第一音频文件为所述双显终端中的主屏幕播放的音频文件;
    所述除第一音频文件外的第二音频文件为所述双显终端中的副屏幕播放的音频文件。
  4. 根据权利要求1所述的方法,其中,所述将默认音频通道分配给第一音频文件或当前正在播放的音频文件,将默认音频通道外的其他音频通道按预设的优先级策略分配给除第一音频文件或正在播放的音频文件外的第二音频文件包括:
    通过音频通道的管理策略,将应用层发送的音频请求中,第一音频或当前正在播放的音频对应的请求发送至默认音频通道;将应用层发送的音频请求中,除第一音频文件或正在播放的音频文件外的第二音频对应的请求根据预设的优先级策略发送至相应的音频通道。
  5. 根据权利要求4所述的方法,其中,所述优先级策略的预设包括:
    获取用户对音频通道的优先级设置;
    将所述优先级设置保存至音频通道策略库。
  6. 根据权利要求5所述的方法,其中,所述优先级策略的预设还包括:
    对Android音频架构中的混音系统进行扩展,以使所述多个音频文件中的音频数据 流相互不再进行混音处理。
  7. 一种终端,其中,该终端包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,该所述计算机程序被所述处理器执行时,实现如权利要求1至6中任一项所述的音频通道的管理方法的步骤。
  8. 一种存储介质,其中,该存储介质上存储有计算机程序,所述计算机程序被处理器执行时,实现如权利要求1至6中任一项所述的音频通道的管理方法的步骤。
PCT/CN2019/106574 2018-09-19 2019-09-19 一种音频通道的管理方法、终端及存储介质 WO2020057578A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811099816.9A CN110933221A (zh) 2018-09-19 2018-09-19 一种音频通道的管理方法、装置、终端及存储介质
CN201811099816.9 2018-09-19

Publications (1)

Publication Number Publication Date
WO2020057578A1 true WO2020057578A1 (zh) 2020-03-26

Family

ID=69856087

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/106574 WO2020057578A1 (zh) 2018-09-19 2019-09-19 一种音频通道的管理方法、终端及存储介质

Country Status (2)

Country Link
CN (1) CN110933221A (zh)
WO (1) WO2020057578A1 (zh)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111580781A (zh) * 2020-05-27 2020-08-25 重庆蓝岸通讯技术有限公司 一种移动终端音频输出方法及移动终端
CN113050912B (zh) * 2020-09-30 2024-06-04 惠州华阳通用电子有限公司 一种音频文件输出方法及装置
CN113360117B (zh) * 2021-06-28 2024-06-25 北京字节跳动网络技术有限公司 电子设备的控制方法、装置、终端和存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100008523A1 (en) * 2008-07-14 2010-01-14 Sony Ericsson Mobile Communications Ab Handheld Devices Including Selectively Enabled Audio Transducers
CN103593127A (zh) * 2013-11-25 2014-02-19 华为终端有限公司 音频输出设备的选择方法与终端
CN105096981A (zh) * 2015-09-25 2015-11-25 福州瑞芯微电子股份有限公司 一种多路声音播放方法、装置和系统
CN105244048A (zh) * 2015-09-25 2016-01-13 小米科技有限责任公司 音频播放控制方法和装置
CN106686211A (zh) * 2016-11-30 2017-05-17 努比亚技术有限公司 一种分屏模式下声音播放的处理方法及终端
CN107450874A (zh) * 2017-07-24 2017-12-08 宇龙计算机通信科技(深圳)有限公司 一种多媒体数据双屏播放方法及系统

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR0164703B1 (ko) * 1995-11-28 1999-03-20 배순훈 이중 스크린시 메인 서브 음성 기록 장치
US8803816B2 (en) * 2008-09-08 2014-08-12 Qualcomm Incorporated Multi-fold mobile device with configurable interface
CN106131322A (zh) * 2016-06-30 2016-11-16 努比亚技术有限公司 双屏移动终端播放声音的方法及装置
CN106201425A (zh) * 2016-07-12 2016-12-07 乐视控股(北京)有限公司 一种智能终端音频输出的方法及装置
CN108132769A (zh) * 2017-01-03 2018-06-08 中兴通讯股份有限公司 一种音频数据播放方法和双屏移动终端

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100008523A1 (en) * 2008-07-14 2010-01-14 Sony Ericsson Mobile Communications Ab Handheld Devices Including Selectively Enabled Audio Transducers
CN103593127A (zh) * 2013-11-25 2014-02-19 华为终端有限公司 音频输出设备的选择方法与终端
CN105096981A (zh) * 2015-09-25 2015-11-25 福州瑞芯微电子股份有限公司 一种多路声音播放方法、装置和系统
CN105244048A (zh) * 2015-09-25 2016-01-13 小米科技有限责任公司 音频播放控制方法和装置
CN106686211A (zh) * 2016-11-30 2017-05-17 努比亚技术有限公司 一种分屏模式下声音播放的处理方法及终端
CN107450874A (zh) * 2017-07-24 2017-12-08 宇龙计算机通信科技(深圳)有限公司 一种多媒体数据双屏播放方法及系统

Also Published As

Publication number Publication date
CN110933221A (zh) 2020-03-27

Similar Documents

Publication Publication Date Title
WO2020057578A1 (zh) 一种音频通道的管理方法、终端及存储介质
KR101657112B1 (ko) 표시 레이턴시를 감소하기 위한 방법 및 장치
CN109542614B (zh) 资源配置方法、装置、终端及存储介质
US20130067050A1 (en) Playback manager
EP3282734B1 (en) Data transmission method and terminal
US20160301617A1 (en) Bandwidth prioritization
US9826572B2 (en) Wireless enhanced projector
WO2022078056A1 (zh) 音频播放方法、装置、电子设备及存储介质
CN103888832A (zh) 一种播放终端接入数据源切换的处理方法和装置
US20150012973A1 (en) Methods and apparatus for sharing a service between multiple virtual machines
WO2016197654A1 (zh) 一种投影终端及其实现多终端同屏投影的方法
WO2022262433A1 (zh) 资源分配方法、终端和计算机可读存储介质
WO2021253895A1 (zh) 媒资播放方法及显示设备
US20160127768A1 (en) Usb sharing method for combo tv set, combo tv set and computer readable storage medium
US8670556B2 (en) Multi-participant communication system with audio manager responsive to mode change requests
WO2020000291A1 (zh) 一种媒体信息显示方法及媒体信息显示装置
WO2023103599A1 (zh) 投屏方法、装置、存储介质及电子设备
US10425801B2 (en) Method and device for providing contents in communication system
TWI593287B (zh) 用於輸入/輸出(io)及入站視聽(av)的拓撲和頻寬管理
CN106408912A (zh) 一种基于设备类型的avrcp指令分配方法及系统
WO2012092706A1 (en) Hybrid operating system media integration
US20150012918A1 (en) Methods and apparatus for sharing a physical device between multiple virtual machines
CN112637957A (zh) 显示设备及显示设备与无线音箱的通信方法
US20150012654A1 (en) Methods and apparatus for sharing a physical device between multiple physical machines
EP4344162A1 (en) Information processing method, device, 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: 19861963

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: 19861963

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 06/08/2021)

122 Ep: pct application non-entry in european phase

Ref document number: 19861963

Country of ref document: EP

Kind code of ref document: A1