StaticcreateA factory method that will call the private constructor to instantiate the processor and asynchronously initialize the worker, wasm, and ML models. Upon completion of the initialization the promise will either be resolved or rejected.
Optionalspec: BackgroundFilterSpecThe spec defines the assets that will be used for adding background filter to a frame
Optionaloptions: BackgroundReplacementOptionsBackground replacement options including image path
StaticisThis method will detect the environment in which it is being used and determine if background replacement can be used.
Optionalspec: BackgroundFilterSpecThe BackgroundFilterSpec spec that will be used to initialize assets
Optionaloptions: BackgroundReplacementOptionsoptions such as logger and imagePath
a boolean promise that will resolve to true if supported and false if not
Protected StaticresolveBased on the options that are passed in set defaults for options
the options that are passed in
An updated set of options with defaults set
Protected StaticresolveBased on the spec that is passed in set defaults for spec
Optionalspec: BackgroundFilterSpecthe spec that was passed in
An updated spec with defaults set
[[BackgroundReplacementVideoFrameProcessor]] Creates a background replacement processor which identifies the foreground person and replaces the background.