Windows phone 8 Windows Phone-将缩略图预览保存到录制视频的独立存储中

Windows phone 8 Windows Phone-将缩略图预览保存到录制视频的独立存储中,windows-phone-8,windows-phone,Windows Phone 8,Windows Phone,我有一个应用程序,我想允许用户录制视频,然后将该视频与表示该视频的图像一起保存到独立存储中。我从这里的一些示例代码中找到了视频部分: ' Set recording state: start recording. Private Sub StartVideoRecording() Try ... App.ViewModel.IsDataLoaded = False ' Connect fileSink to captureSource. If capt

我有一个应用程序,我想允许用户录制视频,然后将该视频与表示该视频的图像一起保存到独立存储中。我从这里的一些示例代码中找到了视频部分:

' Set recording state: start recording.
Private Sub StartVideoRecording()
Try
         ...
    App.ViewModel.IsDataLoaded = False

    ' Connect fileSink to captureSource.
    If captureSource.VideoCaptureDevice IsNot Nothing AndAlso captureSource.State = CaptureState.Started Then
        captureSource.Stop()

        ' Connect the input and output of fileSink.
        fileSink.CaptureSource = captureSource
        fileSink.IsolatedStorageFileName = isoVideoFileName
    End If

    ' Begin recording.
    If captureSource.VideoCaptureDevice IsNot Nothing AndAlso captureSource.State = CaptureState.Stopped Then
        captureSource.Start()
    End If

    ' Set the button states and the message.
    UpdateUI(ButtonState.Recording, "Recording...")


Catch e As Exception
    ' If recording fails, display an error.
    Me.Dispatcher.BeginInvoke(Sub() txtDebug.Text = "ERROR: " & e.Message.ToString())
End Try
End Sub

' Set the recording state: stop recording.
Private Sub StopVideoRecording()
Try
    ' Stop recording.
    If captureSource.VideoCaptureDevice IsNot Nothing AndAlso captureSource.State = CaptureState.Started Then
        captureSource.Stop()

        ' Disconnect fileSink.
        fileSink.CaptureSource = Nothing
        fileSink.IsolatedStorageFileName = Nothing

        ' Set the button states and the message.
        UpdateUI(ButtonState.NoChange, "Preparing viewfinder...")

        StartVideoPreview()
    End If
Catch e As Exception
    ' If stop fails, display an error.
    Me.Dispatcher.BeginInvoke(Sub() txtDebug.Text = "ERROR: " & e.Message.ToString())
End Try
End Sub

是否可以在不强制用户拍照的情况下自动从录制的视频中提取缩略图?

您很高兴知道会生成一个自动缩略图。文件名的扩展名为.jpg。您可以查找IsolatedStorage browser以查看结果。

我正在使用windows phone power tools进行浏览,但没有看到生成的任何jpg文件。。。