VideoCanvas
Properties of the video canvas object.
export class VideoCanvas {
view?: any
uid?: number;
subviewUid?: number;
backgroundColor?: number;
renderMode?: RenderModeType
mirrorMode?: VideoMirrorModeType
setupMode?: VideoViewSetupMode;
sourceType?: VideoSourceType
mediaPlayerId?: number;
cropArea?: Rectangle;
enableAlphaMask?: boolean;
position?: VideoModulePosition;
}
Properties
- uid
- User ID of the published video source.
- subviewUid
- Reserved parameter.
- view
- Video display window.
- renderMode
- Video rendering mode. See RenderModeType.
- mirrorMode
- View mirroring mode. See VideoMirrorModeType.
Note:
- Local view mirroring mode: If you use the front camera, local view mirroring is enabled by default; if you use the rear camera, it is disabled by default.
- Remote user view mirroring mode: Disabled by default.
- sourceType
- Type of video source. See VideoSourceType.
- setupMode
- View setup mode. See VideoViewSetupMode.
- mediaPlayerId
- Media player ID. You can get it via getMediaPlayerId.
- cropArea
- (Optional) Display area of the video frame. See Rectangle.
widthandheightrepresent the pixel width and height of the area. The default is an empty value (width or height is 0), which means the actual resolution of the video frame is displayed. - backgroundColor
- Background color of the video canvas in RGBA format. Default is 0x00000000, which represents black.
- enableAlphaMask
-
Note:(Optional) Whether to enable alpha mask rendering:
- The receiver can render alpha channel information only when the sender enables the alpha transmission feature.
- To enable the alpha transmission feature, please contact technical support.
- true: Enable alpha mask rendering.
- false: (Default) Disable alpha mask rendering.
- position
- Position of the video frame in the video pipeline. See VideoModulePosition.