NERtcVideoView.withInternalRenderer constructor
const
NERtcVideoView.withInternalRenderer({
- Key? key,
- int? uid,
- bool subStream = false,
- ValueListenable<
bool> ? mirrorListenable, - NERtcVideoRendererEventListener? rendererEventLister,
- NERtcVideoViewFitType fitType = NERtcVideoViewFitType.cover,
- WidgetBuilder? placeholderBuilder,
- Color backgroundColor = const Color(0xFF292933),
创建用户视频渲染组件。
在该模式下渲染所需的画布对象不需要外部传入,组件内部在使用时会自动创建,不再使用时会自动销毁,不会造成内存泄漏。 推荐使用该模式创建视频渲染组件。
Implementation
const NERtcVideoView.withInternalRenderer({
Key? key,
this.uid,
this.subStream = false,
this.mirrorListenable,
this.rendererEventLister,
this.fitType = NERtcVideoViewFitType.cover,
this.placeholderBuilder,
this.backgroundColor = const Color(0xFF292933),
}) : renderer = null,
autoAttach = true,
super(key: key);