/drivers/peripheral/audio/supportlibs/alsa_adapter/src/ |
H A D | vendor_render.c | 83 static int32_t RenderGetVolumeImpl(struct AlsaRender *renderIns, long *volume)
in RenderGetVolumeImpl() argument 86 CHECK_NULL_PTR_RETURN_DEFAULT(volume);
in RenderGetVolumeImpl() 97 AUDIO_FUNC_LOGE("Read left volume fail!");
in RenderGetVolumeImpl() 102 AUDIO_FUNC_LOGE("Read right volume fail!");
in RenderGetVolumeImpl() 105 *volume = (volLeft + volRight) >> 1;
in RenderGetVolumeImpl() 110 static int32_t RenderSetVolumeImpl(struct AlsaRender *renderIns, long volume)
in RenderSetVolumeImpl() argument 119 ret = SndElementWriteInt(cardIns, &priData->ctrlLeftVolume, volume);
in RenderSetVolumeImpl() 121 AUDIO_FUNC_LOGE("Write left volume fail!");
in RenderSetVolumeImpl() 124 ret = SndElementWriteInt(cardIns, &priData->ctrlRightVolume, volume);
in RenderSetVolumeImpl() 126 AUDIO_FUNC_LOGE("Write right volume fai in RenderSetVolumeImpl() 190 RenderGetGainImpl(struct AlsaRender *renderIns, float *volume) RenderGetGainImpl() argument 196 RenderSetGainImpl(struct AlsaRender *renderIns, float volume) RenderSetGainImpl() argument [all...] |
H A D | vendor_capture.c | 83 static int32_t CaptureGetVolumeImpl(struct AlsaCapture *captureIns, long *volume)
in CaptureGetVolumeImpl() argument 86 CHECK_NULL_PTR_RETURN_DEFAULT(volume);
in CaptureGetVolumeImpl() 97 AUDIO_FUNC_LOGE("Read left volume fail!");
in CaptureGetVolumeImpl() 102 AUDIO_FUNC_LOGE("Read right volume fail!");
in CaptureGetVolumeImpl() 105 *volume = (volLeft + volRight) >> 1;
in CaptureGetVolumeImpl() 110 static int32_t CaptureSetVolumeImpl(struct AlsaCapture *captureIns, long volume)
in CaptureSetVolumeImpl() argument 118 ret = SndElementWriteInt(cardIns, &priData->ctrlLeftVolume, volume);
in CaptureSetVolumeImpl() 120 AUDIO_FUNC_LOGE("Write left volume fail!");
in CaptureSetVolumeImpl() 123 ret = SndElementWriteInt(cardIns, &priData->ctrlRightVolume, volume);
in CaptureSetVolumeImpl() 125 AUDIO_FUNC_LOGE("Write right volume fai in CaptureSetVolumeImpl() 180 CaptureGetGainImpl(struct AlsaCapture *captureIns, float *volume) CaptureGetGainImpl() argument 186 CaptureSetGainImpl(struct AlsaCapture *captureIns, float volume) CaptureSetGainImpl() argument [all...] |
/drivers/peripheral/audio/interfaces/include/ |
H A D | audio_volume.h | 30 * @brief Declares APIs for audio volume. 42 * @brief Provides volume-related APIs for audio rendering or capturing, including functions to 43 * set the mute operation, volume, and gain. 72 * @brief Sets the audio volume. 74 * The volume ranges from 0.0 to 1.0. If the volume level in an audio service ranges from 0 to 15, 75 * <b>0.0</b> indicates that the audio is muted, and <b>1.0</b> indicates the maximum volume level (15). 78 * @param volume Indicates the volume to set. The value ranges from 0.0 to 1.0. 82 int32_t (*SetVolume)(AudioHandle handle, float volume); [all...] |
H A D | audio_capture.h | 47 * scenes, and volume, and capturing audio frames. 70 * @brief Defines audio volume. For details, see {@link AudioVolume}. 72 struct AudioVolume volume; member
|
/drivers/peripheral/distributed_audio/interface/audio/v1_0/ |
H A D | i_audio_volume.h | 27 virtual int32_t SetVolume(const float volume) = 0; 29 virtual int32_t GetVolume(float &volume) = 0;
|
/drivers/peripheral/audio/interfaces/2.0/include/ |
H A D | audio_volume.h | 30 * @brief Declares APIs for audio volume. 42 * @brief Provides volume-related APIs for audio rendering or capturing, including functions to 43 * set the mute operation, volume, and gain. 72 * @brief Sets the audio volume. 74 * The volume ranges from 0.0 to 1.0. If the volume level in an audio service ranges from 0 to 15, 75 * <b>0.0</b> indicates that the audio is muted, and <b>1.0</b> indicates the maximum volume level (15). 78 * @param volume Indicates the volume to set. The value ranges from 0.0 to 1.0. 82 int32_t (*SetVolume)(AudioHandle handle, float volume); [all...] |
H A D | audio_capture.h | 48 * scenes, and volume, and capturing audio frames. 71 * @brief Defines audio volume. For details, see {@link AudioVolume}. 73 struct AudioVolume volume; member
|
/drivers/peripheral/bluetooth/audio/interfaces/include/ |
H A D | audio_volume.h | 30 * @brief Declares APIs for audio volume. 42 * @brief Provides volume-related APIs for audio rendering or capturing, including functions to 43 * set the mute operation, volume, and gain. 72 * @brief Sets the audio volume. 74 * The volume ranges from 0.0 to 1.0. If the volume level in an audio service ranges from 0 to 15, 75 * <b>0.0</b> indicates that the audio is muted, and <b>1.0</b> indicates the maximum volume level (15). 78 * @param volume Indicates the volume to set. The value ranges from 0.0 to 1.0. 82 int32_t (*SetVolume)(AudioHandle handle, float volume); [all...] |
/drivers/peripheral/bluetooth/audio/hal/hdi_passthrough/src/ |
H A D | audio_adapter.cpp | 51 hwRender->common.volume.SetMute = FastRenderSetMute; in GetFastRenderFuncs() 52 hwRender->common.volume.GetMute = FastRenderGetMute; in GetFastRenderFuncs() 53 hwRender->common.volume.SetVolume = FastRenderSetVolume; in GetFastRenderFuncs() 54 hwRender->common.volume.GetVolume = FastRenderGetVolume; in GetFastRenderFuncs() 55 hwRender->common.volume.GetGainThreshold = FastRenderGetGainThreshold; in GetFastRenderFuncs() 56 hwRender->common.volume.GetGain = FastRenderGetGain; in GetFastRenderFuncs() 57 hwRender->common.volume.SetGain = FastRenderSetGain; in GetFastRenderFuncs() 89 hwRender->common.volume.SetMute = AudioRenderSetMute; in GetNormalRenderFuncs() 90 hwRender->common.volume.GetMute = AudioRenderGetMute; in GetNormalRenderFuncs() 91 hwRender->common.volume in GetNormalRenderFuncs() [all...] |
H A D | fast_audio_render.cpp | 168 int32_t FastRenderSetVolume(AudioHandle handle, float volume)
in FastRenderSetVolume() argument 172 (void)volume;
in FastRenderSetVolume() 176 int32_t FastRenderGetVolume(AudioHandle handle, float *volume)
in FastRenderGetVolume() argument 180 (void)volume;
in FastRenderGetVolume()
|
/drivers/peripheral/audio/test/systemtest/hdi_service/common/capture/src/ |
H A D | audio_idl_hdicapture_volume_test.cpp | 177 * @tc.desc Test AudioCaptureSetVolume interface , return 0 if the audiocapture sets volume successfully. 215 * @tc.desc Test AudioCaptureSetVolume,return -3 if volume is set maximum value or minimum value. 255 float volume = 0; in HWTEST_F() local 259 ret = capture->SetVolume(captureNull, volume); in HWTEST_F() 270 float volume = 0.60; in HWTEST_F() local 274 ret = capture->SetVolume(capture, volume); in HWTEST_F() 276 ret = capture->GetVolume(capture, &volume); in HWTEST_F() 278 EXPECT_EQ(defaultVolume, volume); in HWTEST_F() 288 float volume = 0.60; in HWTEST_F() local 294 ret = capture->SetVolume(capture, volume); in HWTEST_F() 311 float volume = 0.30; HWTEST_F() local [all...] |
/drivers/peripheral/audio/test/systemtest/hdi_service/common/render/src/ |
H A D | audio_idl_hdirender_volume_test.cpp | 412 * @tc.desc Test AudioRenderSetVolume interface , return 0 if the audiocapture sets volume successfully. 451 * @tc.desc Test AudioRenderSetVolume,return 0 if volume is set maximum value or minimum value. 491 float volume = 0; in HWTEST_F() local 495 ret = render->SetVolume(renderNull, volume); in HWTEST_F() 506 float volume = 0.30; in HWTEST_F() local 510 ret = render->SetVolume(render, volume); in HWTEST_F() 512 ret = render->GetVolume(render, &volume); in HWTEST_F() 514 EXPECT_EQ(volumeDefault, volume); in HWTEST_F() 524 float volume = 0.30; in HWTEST_F() local 531 ret = render->SetVolume(render, volume); in HWTEST_F() 548 float volume = 0.3; HWTEST_F() local [all...] |
/drivers/peripheral/audio/hal/hdi_binder/server/src/ |
H A D | hdf_audio_server_render.c | 490 if (render == NULL || render->volume.GetMute == NULL) { in HdiServiceRenderGetMute() 494 ret = render->volume.GetMute((AudioHandle)render, &mute); in HdiServiceRenderGetMute() 522 if (render == NULL || render->volume.SetMute == NULL) { in HdiServiceRenderSetMute() 526 return render->volume.SetMute((AudioHandle)render, mute); in HdiServiceRenderSetMute() 535 uint32_t volume = 0; in HdiServiceRenderSetVolume() local 541 if (!HdfSbufReadUint32(data, &volume)) { in HdiServiceRenderSetVolume() 544 float setVolume = (float)volume / VOLUME_CHANGE; in HdiServiceRenderSetVolume() 545 if (render == NULL || render->volume.SetVolume == NULL) { in HdiServiceRenderSetVolume() 549 return render->volume.SetVolume((AudioHandle)render, setVolume); in HdiServiceRenderSetVolume() 558 float volume; in HdiServiceRenderGetVolume() local [all...] |
H A D | hdf_audio_server_capture.c | 488 if (capture == NULL || capture->volume.GetMute == NULL) { in HdiServiceCaptureGetMute() 492 ret = capture->volume.GetMute((AudioHandle)capture, &mute); in HdiServiceCaptureGetMute() 522 if (capture == NULL || capture->volume.SetMute == NULL) { in HdiServiceCaptureSetMute() 526 return capture->volume.SetMute((AudioHandle)capture, mute); in HdiServiceCaptureSetMute() 536 uint32_t volume = 0; in HdiServiceCaptureSetVolume() local 542 if (!HdfSbufReadUint32(data, &volume)) { in HdiServiceCaptureSetVolume() 545 float setVolume = (float)volume / VOLUME_CHANGE; in HdiServiceCaptureSetVolume() 546 if (capture == NULL || capture->volume.SetVolume == NULL) { in HdiServiceCaptureSetVolume() 550 return capture->volume.SetVolume((AudioHandle)capture, setVolume); in HdiServiceCaptureSetVolume() 560 float volume; in HdiServiceCaptureGetVolume() local [all...] |
/drivers/peripheral/audio/test/systemtest/supportlibs/hardwaredependence/capture/src/ |
H A D | audio_libcapture_hardwaredependence_test.cpp | 153 hwCapture->captureParam.captureMode.ctlParam.volume = volumeThresholdValueMax - 1;
in HWTEST_F() 158 volumeValue = hwCapture->captureParam.captureMode.ctlParam.volume;
in HWTEST_F() 161 hwCapture->captureParam.captureMode.ctlParam.volume = volumeThresholdValueMin + 1;
in HWTEST_F() 166 volumeValue = hwCapture->captureParam.captureMode.ctlParam.volume;
in HWTEST_F() 195 hwCapture->captureParam.captureMode.ctlParam.volume = volumeThresholdValueMin;
in HWTEST_F() 200 volumeValue = hwCapture->captureParam.captureMode.ctlParam.volume;
in HWTEST_F() 203 hwCapture->captureParam.captureMode.ctlParam.volume = volumeThresholdValueMax;
in HWTEST_F() 208 volumeValue = hwCapture->captureParam.captureMode.ctlParam.volume;
in HWTEST_F() 236 hwCapture->captureParam.captureMode.ctlParam.volume = volumeThresholdValueMax + 1;
in HWTEST_F() 239 hwCapture->captureParam.captureMode.ctlParam.volume in HWTEST_F() [all...] |
/drivers/peripheral/bluetooth/audio/hal/hdi_binder/server/src/ |
H A D | hdf_audio_server_render.cpp | 441 ret = render->volume.GetMute((AudioHandle)render, &mute); in HdiServiceRenderGetMute() 469 return render->volume.SetMute((AudioHandle)render, mute); in HdiServiceRenderSetMute() 478 uint32_t volume = 0; in HdiServiceRenderSetVolume() local 484 if (!HdfSbufReadUint32(data, &volume)) { in HdiServiceRenderSetVolume() 487 float setVolume = (float)volume / VOLUME_CHANGE; in HdiServiceRenderSetVolume() 488 return render->volume.SetVolume((AudioHandle)render, setVolume); in HdiServiceRenderSetVolume() 497 float volume; in HdiServiceRenderGetVolume() local 503 ret = render->volume.GetVolume((AudioHandle)render, &volume); in HdiServiceRenderGetVolume() 507 uint32_t tempVolume = (uint32_t)(volume * VOLUME_CHANG in HdiServiceRenderGetVolume() [all...] |
/drivers/peripheral/audio/test/systemtest/supportlibs/hardwaredependence/render/src/ |
H A D | audio_librender_hardwaredependence_test.cpp | 169 hwRender->renderParam.renderMode.ctlParam.volume = volumeThresholdValueMaxIn - 1;
in HWTEST_F() 174 volumeValue = hwRender->renderParam.renderMode.ctlParam.volume;
in HWTEST_F() 177 hwRender->renderParam.renderMode.ctlParam.volume = volumeThresholdValueMinIn + 1;
in HWTEST_F() 182 volumeValue = hwRender->renderParam.renderMode.ctlParam.volume;
in HWTEST_F() 184 hwRender->renderParam.renderMode.ctlParam.volume = volumeBoundaryValueIn;
in HWTEST_F() 189 volumeValue = hwRender->renderParam.renderMode.ctlParam.volume;
in HWTEST_F() 216 hwRender->renderParam.renderMode.ctlParam.volume = volumeThresholdValueMinIn;
in HWTEST_F() 221 volumeValue = hwRender->renderParam.renderMode.ctlParam.volume;
in HWTEST_F() 224 hwRender->renderParam.renderMode.ctlParam.volume = volumeThresholdValueMaxIn;
in HWTEST_F() 229 volumeValue = hwRender->renderParam.renderMode.ctlParam.volume;
in HWTEST_F() [all...] |
/drivers/peripheral/audio/interfaces/sound/v1_0/ |
H A D | iaudio_render_vdi.h | 47 int32_t (*SetVolume)(struct IAudioRenderVdi *self, float volume); 48 int32_t (*GetVolume)(struct IAudioRenderVdi *self, float *volume);
|
H A D | iaudio_capture_vdi.h | 39 int32_t (*SetVolume)(struct IAudioCaptureVdi *self, float volume); 40 int32_t (*GetVolume)(struct IAudioCaptureVdi *self, float *volume);
|
/drivers/peripheral/bluetooth/audio/hal/hdi_binder/proxy/include/ |
H A D | audio_proxy_internal.h | 52 int32_t AudioProxyRenderSetVolume(const AudioHandle handle, float volume); 53 int32_t AudioProxyRenderGetVolume(const AudioHandle handle, float *volume);
|
/drivers/peripheral/bluetooth/audio/hal/hdi_passthrough/include/ |
H A D | fast_audio_render.h | 38 int32_t FastRenderSetVolume(AudioHandle handle, float volume);
39 int32_t FastRenderGetVolume(AudioHandle handle, float *volume);
|
/drivers/peripheral/audio/test/hal_mock/ |
H A D | audio_render_mock.c | 181 static int32_t SetVolume(struct IAudioRenderVdi* render, float volume)
in SetVolume() argument 187 (void)volume;
in SetVolume() 192 static int32_t GetVolume(struct IAudioRenderVdi* render, float *volume)
in GetVolume() argument 198 (void *)volume;
in GetVolume()
|
/drivers/peripheral/distributed_audio/hdi_service/audio/v1_0/src/ |
H A D | audio_capture_ext_impl.cpp | 211 int32_t AudioCaptureExtImpl::SetVolume(float volume) in SetVolume() argument 214 (void)volume; in SetVolume() 218 int32_t AudioCaptureExtImpl::GetVolume(float &volume) in GetVolume() argument 221 (void)volume; in GetVolume()
|
H A D | audio_capture_interface_impl.cpp | 249 int32_t AudioCaptureInterfaceImpl::SetVolume(float volume) in SetVolume() argument 252 (void)volume; in SetVolume() 256 int32_t AudioCaptureInterfaceImpl::GetVolume(float &volume) in GetVolume() argument 259 (void)volume; in GetVolume()
|
/drivers/peripheral/distributed_audio/hdi_service/audio/v1_0/test/unittest/audio_capture_extension/src/ |
H A D | audio_capture_ext_impl_test.cpp | 226 float volume = 0.0; in HWTEST_F() local 235 EXPECT_EQ(HDF_SUCCESS, audioCapturelatencyImpl_->SetVolume(volume)); in HWTEST_F() 237 EXPECT_EQ(HDF_SUCCESS, audioCapturelatencyImpl_->SetGain(volume)); in HWTEST_F() 238 EXPECT_EQ(HDF_SUCCESS, audioCapturelatencyImpl_->GetGain(volume)); in HWTEST_F()
|