How to add sound to a video in WindowsPhone using c#? RRS feed

  • 常规讨论

  • Recently, i am trying to using screenCapture to capture a video from sceen. At the same time, i need to capture sound from microphone, and add the sound to the video.

    var screenCapture = Windows.Media.Capture.ScreenCapture.GetForCurrentView();
     // Set the MediaCaptureInitializationSettings to use the ScreenCapture as the audio and video source.
    var mcis = new Windows.Media.Capture.MediaCaptureInitializationSettings();
    mcis.VideoSource = screenCapture.VideoSource;
    mcis.AudioSource = screenCapture.AudioSource;

    Here is the problem, i cant set the audio source to microphone, while Microsoft.Xna.Framework.Audio.Microphone stores sound in a stream and than an audio file like(wav). So, my question is how to add sound to the video during both are capturing or after capture( the screenCapture stores in a mp4 and sound stores in a wav)?

    2014年7月23日 8:41