EncoderConfig class
Configuration for a video encoder.
Constructors
-
EncoderConfig({required VideoCodec codec, required int width, required int height, required int bitrateBps, int gopLength = 0, int frameRateNumerator = 30, int frameRateDenominator = 1, MiniAVPixelFormat inputPixelFormat = MiniAVPixelFormat.nv12, HwAccelPreference hwAccel = HwAccelPreference.preferred, RateControl rateControl = RateControl.vbr, int? crfQuality, EncoderProfile profile = EncoderProfile.high, EncoderLevel? level, int bFrameCount = 0, Map<
String, String> backendOptions = const {}}) -
const
Properties
-
backendOptions
→ Map<
String, String> -
Backend-specific options as key-value strings (e.g. NVENC
preset=p4).final - bFrameCount → int
-
Maximum number of B-frames between P-frames. 0 disables.
final
- bitrateBps → int
-
final
- codec → VideoCodec
-
final
- crfQuality → int?
-
CRF / ICQ quality (codec-dependent range, typically 0–51).
final
- frameRateDenominator → int
-
final
- frameRateNumerator → int
-
final
- gopLength → int
-
Keyframe interval in frames. 0 = encoder default.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → int
-
final
- hwAccel → HwAccelPreference
-
final
- inputPixelFormat → MiniAVPixelFormat
-
Pixel format the encoder will receive (post-upload). Most hardware
encoders want NV12; software encoders often want YUV420P.
final
- level → EncoderLevel?
-
final
- profile → EncoderProfile
-
final
- rateControl → RateControl
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- width → int
-
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited