locked
Audio API for Metro app development with HTML5

    Question

  • does the WINRT have an audio library  where I can find out the sound frequency of the track in an <audio> tag? I am planning to use an audio api in my metro app development. 
    Wednesday, September 19, 2012 2:57 AM

Answers

  • You would need to write a custom Media Foundation Transform (MFT) in C++ to filter the frequency. You can add an MFT to the audio tag with the msInsertAudioEffect function. The tricky part will be communicating back from the MFT to the app in a performant manner. You will want to make sure the communication isn't too chatty, so you will want to limit how often you report / request the sounds.

    See the MediaStreamSource media extension sample for an example audio MFT.

    --Rob

    • Marked as answer by Dino He Thursday, October 11, 2012 2:42 PM
    Wednesday, September 19, 2012 10:03 PM
    Moderator

All replies

  • does the WINRT have an audio library  where I can find out the sound frequency of the track in an <audio> tag? I am planning to use an audio api in my metro app development. 
    Wednesday, September 19, 2012 2:57 AM
  • You would need to write a custom Media Foundation Transform (MFT) in C++ to filter the frequency. You can add an MFT to the audio tag with the msInsertAudioEffect function. The tricky part will be communicating back from the MFT to the app in a performant manner. You will want to make sure the communication isn't too chatty, so you will want to limit how often you report / request the sounds.

    See the MediaStreamSource media extension sample for an example audio MFT.

    --Rob

    • Marked as answer by Dino He Thursday, October 11, 2012 2:42 PM
    Wednesday, September 19, 2012 10:03 PM
    Moderator