MediaSFU Vue
Preparing search index...
useBackgroundModal
Function useBackgroundModal
useBackgroundModal
(
initialParameters
?:
Partial
<
BackgroundModalParameters
>
,
)
:
{
isBackgroundModalVisible
:
Ref
<
boolean
,
boolean
>
;
backgroundModalParameters
:
ComputedRef
<
{
customImage
?:
string
;
selectedImage
?:
string
;
segmentVideo
?:
{}
|
null
;
selfieSegmentation
?:
|
{
setOptions
(
options
:
Record
<
string
,
unknown
>
)
:
void
;
initialize
()
:
Promise
<
void
>
;
onResults
(
callback
:
(
results
:
SelfieSegmentationResults
)
=>
void
)
:
void
;
send
(
input
:
SelfieSegmentationInput
)
:
Promise
<
void
>
;
}
|
null
;
pauseSegmentation
?:
boolean
;
processedStream
?:
{}
|
null
;
keepBackground
?:
boolean
;
backgroundHasChanged
?:
boolean
;
virtualStream
?:
{}
|
null
;
mainCanvas
?:
HTMLCanvasElement
|
null
;
prevKeepBackground
?:
boolean
;
appliedBackground
?:
boolean
;
autoClickBackground
?:
boolean
;
videoAlreadyOn
?:
boolean
;
audioOnlyRoom
?:
boolean
;
islevel
?:
string
;
localStreamVideo
?:
{}
|
null
;
recordStarted
?:
boolean
;
recordResumed
?:
boolean
;
recordPaused
?:
boolean
;
recordStopped
?:
boolean
;
recordingMediaOptions
?:
string
;
mediaDevices
?:
{}
;
vidCons
?:
any
;
frameRate
?:
number
;
targetResolution
?:
string
;
videoProducer
?:
any
;
transportCreated
?:
boolean
;
videoParams
?:
Record
<
string
,
unknown
>
;
showAlert
?:
any
;
updateCustomImage
?:
(
image
:
string
)
=>
void
;
updateSelectedImage
?:
(
image
:
string
)
=>
void
;
updateSegmentVideo
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updateSelfieSegmentation
?:
(
segmentation
:
SelfieSegmentation
|
null
,
)
=>
void
;
updatePauseSegmentation
?:
(
pause
:
boolean
)
=>
void
;
updateProcessedStream
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updateKeepBackground
?:
(
keep
:
boolean
)
=>
void
;
updateBackgroundHasChanged
?:
(
changed
:
boolean
)
=>
void
;
updateVirtualStream
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updatePrevKeepBackground
?:
(
prev
:
boolean
)
=>
void
;
updateAppliedBackground
?:
(
applied
:
boolean
)
=>
void
;
updateVideoParams
?:
(
params
:
Record
<
string
,
unknown
>
)
=>
void
;
updateAutoClickBackground
?:
(
auto
:
boolean
)
=>
void
;
createSendTransport
?:
(
options
:
Record
<
string
,
unknown
>
)
=>
Promise
<
void
>
;
connectSendTransportVideo
?:
(
options
:
Record
<
string
,
unknown
>
,
)
=>
Promise
<
void
>
;
disconnectSendTransportVideo
?:
(
options
:
Record
<
string
,
unknown
>
,
)
=>
Promise
<
void
>
;
onScreenChanges
?:
(
options
:
Record
<
string
,
unknown
>
)
=>
Promise
<
void
>
;
sleep
?:
(
options
:
{
ms
:
number
}
)
=>
Promise
<
void
>
;
getUpdatedAllParams
?:
()
=>
BackgroundModalParameters
;
[
key
:
string
]:
unknown
;
}
,
>
;
toggleBackgroundModal
:
(
next
?:
Partial
<
BackgroundModalParameters
>
)
=>
void
;
openBackgroundModal
:
(
next
?:
Partial
<
BackgroundModalParameters
>
)
=>
void
;
closeBackgroundModal
:
()
=>
void
;
}
Parameters
Optional
initialParameters
:
Partial
<
BackgroundModalParameters
>
Returns
{
isBackgroundModalVisible
:
Ref
<
boolean
,
boolean
>
;
backgroundModalParameters
:
ComputedRef
<
{
customImage
?:
string
;
selectedImage
?:
string
;
segmentVideo
?:
{}
|
null
;
selfieSegmentation
?:
|
{
setOptions
(
options
:
Record
<
string
,
unknown
>
)
:
void
;
initialize
()
:
Promise
<
void
>
;
onResults
(
callback
:
(
results
:
SelfieSegmentationResults
)
=>
void
)
:
void
;
send
(
input
:
SelfieSegmentationInput
)
:
Promise
<
void
>
;
}
|
null
;
pauseSegmentation
?:
boolean
;
processedStream
?:
{}
|
null
;
keepBackground
?:
boolean
;
backgroundHasChanged
?:
boolean
;
virtualStream
?:
{}
|
null
;
mainCanvas
?:
HTMLCanvasElement
|
null
;
prevKeepBackground
?:
boolean
;
appliedBackground
?:
boolean
;
autoClickBackground
?:
boolean
;
videoAlreadyOn
?:
boolean
;
audioOnlyRoom
?:
boolean
;
islevel
?:
string
;
localStreamVideo
?:
{}
|
null
;
recordStarted
?:
boolean
;
recordResumed
?:
boolean
;
recordPaused
?:
boolean
;
recordStopped
?:
boolean
;
recordingMediaOptions
?:
string
;
mediaDevices
?:
{}
;
vidCons
?:
any
;
frameRate
?:
number
;
targetResolution
?:
string
;
videoProducer
?:
any
;
transportCreated
?:
boolean
;
videoParams
?:
Record
<
string
,
unknown
>
;
showAlert
?:
any
;
updateCustomImage
?:
(
image
:
string
)
=>
void
;
updateSelectedImage
?:
(
image
:
string
)
=>
void
;
updateSegmentVideo
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updateSelfieSegmentation
?:
(
segmentation
:
SelfieSegmentation
|
null
,
)
=>
void
;
updatePauseSegmentation
?:
(
pause
:
boolean
)
=>
void
;
updateProcessedStream
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updateKeepBackground
?:
(
keep
:
boolean
)
=>
void
;
updateBackgroundHasChanged
?:
(
changed
:
boolean
)
=>
void
;
updateVirtualStream
?:
(
stream
:
MediaStream
|
null
)
=>
void
;
updatePrevKeepBackground
?:
(
prev
:
boolean
)
=>
void
;
updateAppliedBackground
?:
(
applied
:
boolean
)
=>
void
;
updateVideoParams
?:
(
params
:
Record
<
string
,
unknown
>
)
=>
void
;
updateAutoClickBackground
?:
(
auto
:
boolean
)
=>
void
;
createSendTransport
?:
(
options
:
Record
<
string
,
unknown
>
)
=>
Promise
<
void
>
;
connectSendTransportVideo
?:
(
options
:
Record
<
string
,
unknown
>
,
)
=>
Promise
<
void
>
;
disconnectSendTransportVideo
?:
(
options
:
Record
<
string
,
unknown
>
,
)
=>
Promise
<
void
>
;
onScreenChanges
?:
(
options
:
Record
<
string
,
unknown
>
)
=>
Promise
<
void
>
;
sleep
?:
(
options
:
{
ms
:
number
}
)
=>
Promise
<
void
>
;
getUpdatedAllParams
?:
()
=>
BackgroundModalParameters
;
[
key
:
string
]:
unknown
;
}
,
>
;
toggleBackgroundModal
:
(
next
?:
Partial
<
BackgroundModalParameters
>
)
=>
void
;
openBackgroundModal
:
(
next
?:
Partial
<
BackgroundModalParameters
>
)
=>
void
;
closeBackgroundModal
:
()
=>
void
;
}
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
MediaSFU
MediaSFU Vue - v1.0.1
Loading...