Duix-Mobile icon indicating copy to clipboard operation
Duix-Mobile copied to clipboard

iOS 播放没有声音

Open gavin-tang opened this issue 1 year ago • 7 comments

下载 demo 能跑起来,但是播放没有声音,而且内存增长飞快,存在内存泄漏

gavin-tang avatar Jun 21 '24 02:06 gavin-tang

/* *wavPath 音频的本地路径 *1通道 16位深 16000采样率的wav本地文件 / -(void)toSpeakWithPath:(NSString)wavPath;

songwei01 avatar Jun 21 '24 05:06 songwei01

或者使用demo自带的音频测试

songwei01 avatar Jun 21 '24 05:06 songwei01

我这边下载demo测试 内存在295M左右 CPU最高在55%左右 3

songwei01 avatar Jun 21 '24 05:06 songwei01

使用的是项目中的 3.wav,在 iPhone 11 上没有声音,在 macOS 上有声音。

gavin-tang avatar Jun 21 '24 05:06 gavin-tang

使用的是项目中的 3.wav,在 iPhone 11 上没有声音,在 macOS 上有声音。 您的系统版本?有嘴形吗?

songwei01 avatar Jun 21 '24 08:06 songwei01

嘴型有, iPhone 11 -> 17.5.1 iPhone X -> 17.0 这2个机型都不行,可能是工程对iPhone的支持问题?

gavin-tang avatar Jun 21 '24 08:06 gavin-tang

AVAudioSession *audioSession = [AVAudioSession sharedInstance]; [audioSession setCategory:AVAudioSessionCategoryPlayAndRecord withOptions:AVAudioSessionCategoryOptionDefaultToSpeaker error:nil]; [audioSession setActive:YES error:nil]; 设置为扬声器播放 发自我的iPhone

------------------ 原始邮件 ------------------ From: gavin.tang @.> 发送时间: 06/21/2024, 16:19 To: GuijiAI/duix.ai @.> 抄送: songwei01 @.>, Comment @.> Subject: Re: [GuijiAI/duix.ai] iOS 播放没有声音 (Issue #22)

嘴型有, iPhone 11 -> 17.5.1 iPhone X -> 17.0 这2个机型都不行,可能是工程对iPhone的支持问题?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

songwei01 avatar Jun 21 '24 13:06 songwei01