Webex Meetings
Virtual Background
Enhance your video appearance and maintain professionalism, privacy, and focus by using a virtual background in meetings.
This article describes how you can use the Webex iOS Meetings SDK to work with virtual backgrounds in your app.
anchorVirtual Background Notes
anchorWhen using custom virtual backgrounds, consider the following guidelines:
- Supported image formats for custom backgrounds are JPG and PNG.
- The SDK resizes images larger than 1280x720 to avoid excessive CPU usage.
- Application storage will increase based on the custom images used.
- High CPU usage by the Virtual Background feature may trigger
CallObserver.onCpuHitThreshold()
. If that happens, consider disabling the feature.
anchorVirtual Background Types
anchorThe Webex iOS Meetings SDK lets you choose from three options:
- None
- Blur
- Custom
None
Removes any custom or blurred background, effectively disabling the virtual background feature. This is the default setting:
Blur
Applies a blur effect to the background.
Custom
Allows the use of a personal image as the background.
anchorHow to Use Virtual Background
anchorThe following sections describe how to use the virtual background functionality in the Webex iOS Meetings SDK.
Check Device Compatibility
To check if the device supports virtual backgrounds:
isVirtualBackgroundSupported: Bool
Fetch Available Virtual Backgrounds
To retrieve available virtual backgrounds:
fetchVirtualBackgrounds(completionHandler: @escaping (_ result: Result<[VirtualBackground]>) -> Void)
Upload a Custom Virtual Background
To upload a custom virtual background:
func addVirtualBackground(image: LocalFile, completionHandler: @escaping (_ result: Result<VirtualBackground>) -> Void)
Apply Virtual Background
To apply a virtual background:
func applyVirtualBackground(background: VirtualBackground, mode: VirtualBackgroundMode, completionHandler: @escaping (_ result: Result<Bool>) -> Void)
Specify the display mode, set either preview
or call
, depending on your requirements.
Remove Virtual Background
To remove a virtual background:
func removeVirtualBackground(background: VirtualBackground, completionHandler: @escaping (_ result: Result<Bool>) -> Void)
Manage Virtual Background Limit
Set the number of virtual backgrounds that you want to support. The default limit is 3.
var virtualBackgroundLimit: Int