Class M4AOutput
- Namespace
- VisioForge.Core.Types.Output
- Assembly
- VisioForge.Core.dll
Represents configuration settings for M4A (MPEG-4 Audio) output using AAC compression.
public sealed class M4AOutput : IVideoEditBaseOutput, IVideoCaptureBaseOutputInheritance
Implements
Inherited Members
Remarks
M4A is an audio-only file format based on the MPEG-4 container, typically containing AAC-encoded audio. This format is widely used for music distribution, podcasts, and audiobooks due to its excellent compression efficiency and broad device compatibility.
Key features:
- Superior audio quality compared to MP3 at similar bitrates
- Efficient compression using AAC codec
- Support for metadata (album art, track info, etc.)
- Native support on Apple devices and most modern media players
- Lower CPU usage during decoding compared to some other formats
This output format is ideal for:
- Audio-only captures or conversions
- Music and podcast production
- Audio streaming applications
- Mobile device compatibility
Constructors
M4AOutput()
Initializes a new instance of the VisioForge.Core.Types.Output.M4AOutput class with default settings.
public M4AOutput()Remarks
Default configuration:
- Version: MPEG-4 AAC
- Object: Low Complexity (LC) profile
- Bitrate: 128 kbps
- Output: RAW AAC (suitable for M4A container)
These defaults provide good quality audio with broad compatibility.
Properties
Bitrate
Gets or sets the target audio bitrate in kilobits per second (kbps).
public int Bitrate { get; set; }Property Value
Remarks
Recommended bitrates for different quality levels:
- 64 kbps: Voice, podcasts, low quality
- 96 kbps: Acceptable music quality
- 128 kbps: Standard quality, good balance (default)
- 160-192 kbps: High quality music
- 256-320 kbps: Maximum quality, near-transparent
AAC typically achieves similar perceived quality to MP3 at lower bitrates.
Object
Gets or sets the AAC object type/profile to use for encoding.
public AACObject Object { get; set; }Property Value
Remarks
AAC-LC (Low Complexity) is the most widely supported profile and recommended for general use. It provides the best balance between quality, compression, and device compatibility.
Output
Gets or sets the AAC output format (RAW or ADTS).
public AACOutput Output { get; set; }Property Value
Remarks
RAW AAC is appropriate for container formats like M4A/MP4 that provide their own framing. ADTS adds frame headers and is used for streaming or standalone AAC files.
Version
Gets or sets the AAC version/standard to use for encoding.
public AACVersion Version { get; set; }Property Value
Remarks
MPEG-4 AAC is recommended for most applications as it provides better compression efficiency and support for additional features like HE-AAC (High Efficiency AAC).
Methods
GetInternalTypeVC()
Gets the internal output format identifier for video capture operations.
public VideoCaptureOutputFormat GetInternalTypeVC()Returns
- VideoCaptureOutputFormat
-
Returns VisioForge.Core.Types.VideoCapture.VideoCaptureOutputFormat.M4A to indicate this is an M4A audio output format.
Remarks
This method is used internally by the video capture system to identify the output format type.
GetInternalTypeVE()
Gets the internal output format identifier for video editing operations.
public VideoEditOutputFormat GetInternalTypeVE()Returns
- VideoEditOutputFormat
-
Returns VisioForge.Core.Types.VideoEdit.VideoEditOutputFormat.M4A to indicate this is an M4A audio output format.
Remarks
This method is used internally by the video editing system to identify the output format type.
Load(string)
Deserializes M4A output settings from a JSON string.
public static M4AOutput Load(string json)Parameters
jsonstring-
The JSON string containing the serialized M4A output settings.
Returns
- M4AOutput
-
A new VisioForge.Core.Types.Output.M4AOutput instance with settings restored from the JSON string.
Exceptions
- JsonException
-
Thrown when the JSON string is invalid or cannot be deserialized to an M4AOutput object.
Save()
Serializes the current M4A output settings to a JSON string.
public string Save()Returns
- string
-
A JSON string representation of the current settings that can be persisted or transmitted.
Remarks
The resulting JSON can be used to restore the settings later using the VisioForge.Core.Types.Output.M4AOutput.Load(System.String) method.