Class AMAHEVCEncoderSettings
- Assembly
- VisioForge.Core.dll
Configuration settings for the AMD AMA (Alveo MA35D) hardware HEVC encoder (ama_h265enc).
public class AMAHEVCEncoderSettings : IHEVCEncoderSettings, IVideoEncoder, IMediaBlockSettings, IEncoderTextInfoInheritance
Implements
Inherited Members
Remarks
Available on Linux only and requires the AMD AMA Video SDK (kernel driver + GStreamer plugins). Property values are stable across AMA SDK v1.0/v1.1/v1.2. Properties that vary by SDK version are applied best-effort — an absent property on an older SDK build is ignored, not fatal. The encoder consumes device memory, so the SDK inserts an ama_upload element in front of it automatically when the source is in system memory.
Constructors
AMAHEVCEncoderSettings()
Initializes a new instance of the VisioForge.Core.Types.X.VideoEncoders.AMAHEVCEncoderSettings class.
public AMAHEVCEncoderSettings()AMAHEVCEncoderSettings(VideoQuality)
Initializes a new instance of the VisioForge.Core.Types.X.VideoEncoders.AMAHEVCEncoderSettings class with a specified quality level.
public AMAHEVCEncoderSettings(VideoQuality quality)Parameters
qualityVideoQuality-
The video quality level that determines bitrate settings.
Fields
Name
Gets the display name of this encoder.
public static readonly string NameField Value
Properties
BFrames
Gets or sets the number of B-frames between P-frames (-1..3). -1 (default) = auto.
public int BFrames { get; set; }Property Value
Bitrate
Gets or sets the target bitrate in Kbps. Default 5000 (5 Mbps).
public uint Bitrate { get; set; }Property Value
Device
Gets or sets the numeric ID of the MA35D device to encode on. -1 (default) auto-selects a card. Use this to pin encoding to a specific Alveo MA35D when several AMD devices are present.
public int Device { get; set; }Property Value
ForcedIDR
Gets or sets a value indicating whether all intra frames are encoded as IDR frames. Default true.
public bool ForcedIDR { get; set; }Property Value
GOPLength
Gets or sets the maximum I-frame distance (GOP length). -1 (default) = auto.
public int GOPLength { get; set; }Property Value
HEVCParseInferTimestamps
Gets or sets h265parse infer-ts setting. Defaults to true. Set to null to use GStreamer default.
public bool? HEVCParseInferTimestamps { get; set; }Property Value
- bool?
HEVCParsePtsInterpolation
Gets or sets h265parse pts-interpolation setting. Defaults to true.
public bool? HEVCParsePtsInterpolation { get; set; }Property Value
- bool?
LatencyMs
Gets or sets the encoder latency target in milliseconds (-1..60000). -1 (default) = auto.
public int LatencyMs { get; set; }Property Value
LookaheadDepth
Gets or sets the number of future frames analyzed (look-ahead depth). -1 (default) = auto.
public int LookaheadDepth { get; set; }Property Value
MaxBitrate
Gets or sets the maximum (peak) bitrate in Kbps for VBR/CVBR modes. -1 (default) = auto.
public int MaxBitrate { get; set; }Property Value
MaxQP
Gets or sets the maximum allowed QP (0-51). Default 51.
public int MaxQP { get; set; }Property Value
MinQP
Gets or sets the minimum allowed QP (0-51). Default 0.
public int MinQP { get; set; }Property Value
ParseStream
Gets or sets a value indicating whether to parse the video stream. True by default. Disable it for SRT streaming.
public bool ParseStream { get; set; }Property Value
QP
Gets or sets the fixed quantization parameter used in constant-QP mode. -1 (default) = disabled.
public int QP { get; set; }Property Value
QPBOffset
Gets or sets the QP offset for P/B-frames (-51..51). Default 0.
public int QPBOffset { get; set; }Property Value
QPIOffset
Gets or sets the QP offset for I-frames (-51..51). Default 0.
public int QPIOffset { get; set; }Property Value
QPMode
Gets or sets the QP control mode.
public AMAQPMode QPMode { get; set; }Property Value
RateControl
Gets or sets the rate-control mode.
public AMARateControl RateControl { get; set; }Property Value
Slice
Gets or sets which slice (sub-engine) of the selected MA35D device to use. -1 (default) = auto.
public int Slice { get; set; }Property Value
SpatialAQ
Gets or sets a value indicating whether spatial adaptive quantization is enabled. Default true.
public bool SpatialAQ { get; set; }Property Value
SpatialAQGain
Gets or sets the spatial AQ strength (0-255). Default 255.
public int SpatialAQGain { get; set; }Property Value
TemporalAQ
Gets or sets a value indicating whether temporal adaptive quantization is enabled. Default true.
public bool TemporalAQ { get; set; }Property Value
TemporalAQGain
Gets or sets the temporal AQ strength (0-255). Default 255.
public int TemporalAQGain { get; set; }Property Value
Tier
Gets or sets the HEVC tier.
public AMATier Tier { get; set; }Property Value
TuneMetrics
Gets or sets the objective quality metric to tune for.
public AMATuneMetrics TuneMetrics { get; set; }Property Value
Methods
CreateBlock()
Creates a new HEVC encoder block with these settings.
public MediaBlock CreateBlock()Returns
- MediaBlock
-
A configured VisioForge.Core.MediaBlocks.MediaBlock instance for HEVC encoding.
GetCaps()
Gets the GStreamer capabilities string for this encoder.
public string GetCaps()Returns
- string
-
The output capabilities string.
GetEncoderType()
Gets the type of the encoder.
public HEVCEncoderType GetEncoderType()Returns
- HEVCEncoderType
-
The VisioForge.Core.Types.X.VideoEncoders.HEVCEncoderType value for the AMA HEVC encoder.
GetParameters()
Gets a human-readable representation of the encoder parameters.
public string GetParameters()Returns
- string
-
A string describing the ama_h265enc parameters.
IsAvailable()
Determines whether this encoder is available on the current machine.
public static bool IsAvailable()Returns
- bool
-
trueif the ama_h265enc and ama_upload elements are present; otherwise,false.
ToString()
Returns a String that represents this instance.
public override string ToString()