diff --git a/distributed_audio/audioext/v2_0/IDAudioCallback.idl b/distributed_audio/audioext/v2_0/IDAudioCallback.idl index 2b25a533e0772d35a7ac6bb08ad26fc8eb6ef444..3a2738c2101a8f49b3325451889c2610dbad6bdd 100644 --- a/distributed_audio/audioext/v2_0/IDAudioCallback.idl +++ b/distributed_audio/audioext/v2_0/IDAudioCallback.idl @@ -145,4 +145,31 @@ import ohos.hdi.distributed_audio.audioext.v2_0.Types; * @version 2.0 */ RefreshAshmemInfo([in] int streamId, [in] FileDescriptor fd, [in] int ashmemLength, [in] int lengthPerTrans); + + /** + * @brief Get the latency of the distributed audio device. + * + * @param streamId Stream ID for distributed audio devices. + * @param ms Latency in milliseconds. + * + * @return a value of 0 if success, return a negative value if failed. + * + * @since 6.0 + * @version 2.0 + */ + GetLatency([in] int streamId, [out] unsigned int ms); + + /** + * @brief Get the current render position and timestamp of the distributed audio device. + * + * @param streamId Stream ID for distributed audio devices. + * @param frames Current frame number. + * @param time Current timestamp. + * + * @return a value of 0 if success, return a negative value if failed. + * + * @since 6.0 + * @version 2.0 + */ + GetRenderPosition([in] int streamId, [out] unsigned long frames, [out] struct CurrentTime time); } \ No newline at end of file