期望对于InnerAudioContext的缓存管理更完善一些

小游戏 企业微信 微信支付 小程序 文章 2020-07-30 17:28 639 0 全屏看文

AI助手支持GPT4.0

期望对于InnerAudioContext的缓存管理更完善一些
框架类型 问题类型 API/组件名称 终端类型 微信版本 基础库版本
小游戏 需求 InnerAudioContext.play 微信安卓客户端 7.0 2.12

InnerAudioContext.play 并不会产生soundchannel实例,这是否意味着我若需要播放同一个声音的多个副本,就要创建N个InnerAudioContext

吗?另外,我设置了url以后,只能缓存一部分,是否可以提供缓存整个sound的函数或参数?

在当前API支持下,如果我创建多个InnerAudioContext,设置了同一个url,请问他们是会调用本地缓存,还是依然使用网络流来播放。

这些一系列的需求,影响到我们对于音频的核心稳定性优化,希望微信的大佬们,给我们一定的支持,无论是解答还是增加功能,都行。万分感谢。

Framework type problem type API / component name terminal type wechat version basic library version game requirements InnerAudioContext.play Wechat Android client 7.02.12 InnerAudioContext.play Soundchannel instances are not generated. Does this mean that if I need to play multiple copies of the same sound, I need to create n innereaudiocontext? In addition, after I set the URL, I can only cache part of it. Can I provide functions or parameters to cache the whole sound? Under the current API support, if I create multiple innereaudiocontexts and set the same URL, will they call the local cache or still use the network stream to play. These a series of requirements affect our core stability optimization of audio. We hope that the leaders of wechat can give us some support, whether it is to answer or add functions. Thank you very much.

回答:

侃掰掰:

本地容量有限,且不能解决长音乐跳转之类的问题。

在普通场景下,是否本地影响不大,在重用场景下,本地只是一种下下策,并不能完全解决问题。还会影响加载速度

李伟:可以自己存本地 url也用本地的

-EOF-

AI助手支持GPT4.0