如何检测用户是否听到此音频?
答案 0 :(得分:0)
首先使用iPhone Proximity Sensor检测接近传感器的状态 然后使用电话扬声器Play audio through upper (phone call) speaker
播放音频答案 1 :(得分:0)
[[UIDevice currentDevice] setProximityMonitoringEnabled:YES]
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(sensorStateChange:)
name:@"UIDeviceProximityStateDidChangeNotification" object:nil];