Code sample - Video capture to DV file with and without recompression
Delphi and C# (ActiveX) sample code.
Without recompression
Select the DV file type
VideoCapture1.DV_Capture_Type2 := rbDVType2.Checked;
VideoCapture1.DV_Capture_Type2 = rbDVType2.Checked;
Use DirectStream_DV format for output
VideoCapture1.OutputFormat := Format_DirectStream_DV;
VideoCapture1.OutputFormat = VisioForge_Video_Capture_5.TxVFOutputFormat.Format_DirectStream_DV;
Set video capture mode
VideoCapture1.Mode := Mode_Video_Capture;
VideoCapture1.Mode = VisioForge_Video_Capture_5.TxVFMode.Mode_Video_Capture;
Start capture
VideoCapture1.Start;
VideoCapture1.Start();
With recompression
Set DV parameters
VideoCapture1.DV_Capture_Audio_Channels := strtoint(cbDVChannels.Items[cbDVChannels.ItemIndex]);
VideoCapture1.DV_Capture_Audio_SampleRate := strtoint(cbDVSampleRate.Items[cbDVSampleRate.ItemIndex]);
if rbDVPAL.Checked then
VideoCapture1.DV_Capture_Video_Format := DVF_PAL
else
VideoCapture1.DV_Capture_Video_Format := DVF_NTSC;
VideoCapture1.DV_Capture_Audio_Channels = Convert.ToInt32(cbDVChannels.Text);
VideoCapture1.DV_Capture_Audio_SampleRate = Convert.ToInt32(cbDVSampleRate.Text);
if (rbDVPAL.Checked)
VideoCapture1.DV_Capture_Video_Format = VisioForge_Video_Capture_5.TxVFDVVideoFormat.DVF_PAL;
else
VideoCapture1.DV_Capture_Video_Format = VisioForge_Video_Capture_5.TxVFDVVideoFormat.DVF_NTSC;
Select the DV file type
VideoCapture1.DV_Capture_Type2 := rbDVType2.Checked;
VideoCapture1.DV_Capture_Type2 = rbDVType2.Checked;
Use DV format for output
VideoCapture1.OutputFormat := Format_DV;
VideoCapture1.Mode := Mode_Video_Capture;
VideoCapture1.OutputFormat = VisioForge_Video_Capture_5.TxVFOutputFormat.Format_DV;
VideoCapture1.Mode = VisioForge_Video_Capture_5.TxVFMode.Mode_Video_Capture;
Start capture
VideoCapture1.Start;
VideoCapture1.Start();
Please get in touch with support to get help with this tutorial. Visit our GitHub page to get more code samples.