How to implement Custom Audio Capcha in ASP.Net

前端 未结 4 1854
礼貌的吻别
礼貌的吻别 2021-01-06 12:11

We have created a Custom Capcha generator using C#.Net. Now we have requirement to upgrade our Capcha to include audio feature(Listen Capcha). Our major constraint is that w

4条回答
  •  有刺的猬
    2021-01-06 12:29

    The idea is very simple.

    For every character your have, you record it in audio, and then you simple play the recorded audio in the same order as you show the characters.

    So for the character A, you spell it and record it on a wav file that when you hear it says "alpha" clear and loud.

    Read this answer for how to play them: How to play audio and video files in web browser?

    sound edit on code behind

    If you like to connect the audio to one file, you can select an audio library with all ready existing functions for this mix.

    I know that one of the best is the bass audio library at http://www.un4seen.com/

    Of course because you only need to add two audio maybe you can do that direct with the windows media library, check the SDK of it http://msdn.microsoft.com/en-us/library/windows/desktop/dd757738(v=vs.85).aspx

    Windows media are ready to use functions inside the windows that do many thinks with media like audio.

提交回复
热议问题