필터 지우기
필터 지우기

Time stamping when audio begins to play

조회 수: 7 (최근 30일)
Alice
Alice 2016년 9월 28일
답변: Walter Roberson 2016년 9월 28일
Is there a way of getting a timestamp for when you start playing audio similar to how you can get a timestamp for a Screen flip?
So far I read an audiofile in and load it using audioread and audioplayer. I want a way of noting the time that the player starts playing the file.
Any help is greatly appreciated!!!

답변 (1개)

Walter Roberson
Walter Roberson 2016년 9월 28일
As far as I know, getting the timestamp for a screen flip is something that would require the third-party Psychtoolbox, but if you know a MATLAB way, then I would be interested in seeing that.
audioplayer has a StartFcn callback that you could use now() or datetime() with to get a timestamp. However, I would be suspicious about the accuracy of that, since functions can take arbitrary time to execute.

카테고리

Help CenterFile Exchange에서 Timing and presenting 2D and 3D stimuli에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by