VideoEffectsConfig class
Configuration for the video effects pipeline.
One whole document, not independent switches: anything not set goes back to its default on every push, so build the full config from your UI state each time. pipeline picks the engine that renders them: the CPU engine on VideoEffectsPipeline.LEGACY (the default), the GPU engine on VideoEffectsPipeline.GRAPH. See VideoSDK.setVideoEffects.
final applied = await VideoSDK.setVideoEffects(
VideoEffectsConfig(
pipeline: VideoEffectsConfig.Pipeline.GRAPH,
lighting: VideoEffectsLighting(enabled: true),
filter: VideoEffectsFilter(lut: VideoEffectsConfig.Lut.WARM),
),
);
if (applied?['applied'] != true) {
print('effects not running: ${applied?['reason']}');
}
Constructors
-
VideoEffectsConfig({VideoEffectsPipeline pipeline = VideoEffectsPipeline.LEGACY, VideoEffectsFraming framing = const VideoEffectsFraming(), VideoEffectsLighting lighting = const VideoEffectsLighting(), VideoEffectsStyle style = const VideoEffectsStyle(), VideoEffectsFilter filter = const VideoEffectsFilter(), VideoEffectsBackground background = const VideoEffectsBackground(), Map<
String, Object> extra = const {}}) -
A full set of effects, applied together.
const
Properties
- background → VideoEffectsBackground
-
Background blur. Off by default. CPU engine only.
final
-
extra
→ Map<
String, Object> -
Extra settings merged into the configuration. Only
String,numandboolvalues are applied; nested maps and lists are dropped.final - filter → VideoEffectsFilter
-
Color grade. Off by default.
final
- framing → VideoEffectsFraming
-
Auto-framing. Off by default. On the CPU engine it follows a detected
face; on the GPU engine it follows the box published through
VideoSDK.publishFramingSubject.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- lighting → VideoEffectsLighting
-
Low-light correction. Off by default.
final
- pipeline → VideoEffectsPipeline
-
Capture pipeline. Defaults to VideoEffectsPipeline.LEGACY.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- style → VideoEffectsStyle
-
Stylized look. Off by default.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- Lut → const _Lut
- VideoEffectsLut values, spelled as on Android and iOS.
- Pipeline → const _Pipeline
- VideoEffectsPipeline values, spelled as on Android and iOS.
- StylePreset → const _StylePreset
- VideoEffectsStylePreset values, spelled as on Android and iOS.