VirtualBackgroundSource
Used to set a custom virtual background.
struct VirtualBackgroundSource {
BACKGROUND_SOURCE_TYPE background_source_type;
unsigned int color;
const char* source;
BACKGROUND_BLUR_DEGREE blur_degree;
};
Properties
- background_source_type
- Custom background type. See BACKGROUND_SOURCE_TYPE.
- color
- Color of the custom background image. The color format is a hexadecimal integer defined by RGB, without the # symbol. For example, 0xFFB6C1 represents light pink. Default is 0xFFFFFF (white). Range is [0x000000, 0xFFFFFF]. If the value is invalid, the SDK replaces the original background image with a white image.
Note: This parameter applies only to the following custom background types:
BACKGROUND_COLOR: The background image is a solid color image of the specified color.BACKGROUND_IMG: If the image insourcehas a transparent background, the transparent part will be filled with the color specified by this parameter.
- source
- Absolute local path of the custom background image. Supports PNG, JPG, MP4, AVI, MKV, and FLV formats. If the path is invalid, the SDK uses the original background image or a solid color image specified by
color.Note: This parameter takes effect only when the custom background type isBACKGROUND_IMGorBACKGROUND_VIDEO. - blur_degree
- Blur level of the background image. See BACKGROUND_BLUR_DEGREE.
Note: This parameter takes effect only when the custom background type is
BACKGROUND_BLUR.