MOV Output
This guide explains how to use the MOV output functionality in VisioForge SDKs for video encoding and processing.
The MOVOutput class provides functionality for configuring and generating MOV video files. It supports various video and audio encoders, custom processing blocks, and sink settings.
Basic Usage
Here's a basic example of creating a MOV output:
// Create a new MOV output with specified filename
var movOutput = new MOVOutput("output.mov");
By default, this will:
- Use NVENC H264 encoder if available, otherwise fallback to OpenH264
- Use MF AAC encoder on Windows, or VO-AAC on other platforms
- Create a MOV sink with the specified filename
Video Encoder Configuration
The MOV output supports multiple video encoders:
- OpenH264
- NVENC H264 (NVIDIA)
- QSV H264 (Intel Quick Sync)
- AMF H264 (AMD)
- MF HEVC (Windows only)
- NVENC HEVC
- QSV HEVC
- AMF H265
Example of setting a specific video encoder:
// Configure NVENC H264 encoder
movOutput.Video = new NVENCH264EncoderSettings();
// Or use OpenH264
movOutput.Video = new OpenH264EncoderSettings();
Audio Encoder Configuration
Supported audio encoders include:
- MP3
- VO-AAC
- AVENC AAC
- MF AAC (Windows only)
Example of setting an audio encoder:
Use the MP3 encoder:
// Configure MP3 encoder
movOutput.Audio = new MP3EncoderSettings();
Or use AAC:
// Or use AAC
movOutput.Audio = new MFAACEncoderSettings(); // Windows
// or
movOutput.Audio = new VOAACEncoderSettings(); // Cross-platform
Custom Processing
The MOV output supports custom video and audio processing through media blocks:
// Add custom video processing
movOutput.CustomVideoProcessor = new MediaBlock();
// Add custom audio processing
movOutput.CustomAudioProcessor = new MediaBlock();
Sink Settings
You can configure the MOV sink settings:
// Access sink settings
movOutput.Sink.Filename = "new_output.mov";
Getting Available Encoders
You can programmatically get lists of supported encoders:
// Get available video encoders
var videoEncoders = movOutput.GetVideoEncoders();
// Get available audio encoders
var audioEncoders = movOutput.GetAudioEncoders();
Platform Considerations
Windows-specific features:
- MF HEVC video encoder
- MF AAC audio encoder
Cross-platform features:
- All other video encoders (OpenH264, NVENC, QSV, AMF)
- VO-AAC and AVENC AAC audio encoders
Complete Example
Here's a complete example showing common configuration options:
// Create MOV output
var movOutput = new MOVOutput("output.mov");
// Configure video encoder (using NVENC if available)
if (NVENCH264EncoderSettings.IsAvailable())
{
movOutput.Video = new NVENCH264EncoderSettings();
}
else
{
movOutput.Video = new OpenH264EncoderSettings();
}
// Configure audio encoder
#if NET_WINDOWS
movOutput.Audio = new MFAACEncoderSettings();
#else
movOutput.Audio = new VOAACEncoderSettings();
#endif
// Configure any custom processing if needed
movOutput.CustomVideoProcessor = new MediaBlock();
movOutput.CustomAudioProcessor = new MediaBlock();
Add the MOV output to the Video Capture SDK core instance:
var core = new VideoCaptureCoreX();
core.Outputs_Add(mkvOutput, true);
Set the output format for the Video Edit SDK core instance:
var core = new VideoEditCoreX();
core.Output_Format = mkvOutput;
Create a Media Blocks MOV output instance:
var aac = new VOAACEncoderSettings();
var h264 = new OpenH264EncoderSettings();
var movSinkSettings = new MOVSinkSettings("output.mov");
var movOutput = new MP4OutputBlock(movSinkSettings, h264, aac); // MP4OutputBlock is used for MOV output, as MOV is a subset of MP4