Meeting Class Properties - Unity
ParticipantId
The ParticipantId
property returns the unique participant ID associated with the current VideoSurface
instance.
Type
string
Usage
Use this property to reference or compare participant identities when managing video surfaces.
Example
string participantId = participant.ParticipantId;
Debug.Log("Participant ID: " + participantId);
IsLocal
The IsLocal
property indicates whether the participant associated with the current VideoSurface
is the local participant. Returns true
if the associated participant is the local user, otherwise false
.
Type
bool
Usage
Use this property to apply logic specific to the local participant, such as toggling local media controls or preventing actions intended only for remote participants.
Example
if (participant.IsLocal)
{
Debug.Log("This is the local participant.");
}
else
{
Debug.Log("This is a remote participant.");
}
ParticipantName
The ParticipantName
property returns the display name of the participant associated with the current VideoSurface
.
Type
string
Usage
Use this property to display participant names in the UI or for logging purposes.
Example
string name = participant.ParticipantName;
Debug.Log("Participant Name: " + name);
CamEnabled
The CamEnabled
property indicates whether the camera (video stream) is currently enabled for the participant associated with the VideoSurface
. Returns true
if the participant's camera is enabled; otherwise, returns false
.
Type
bool
Usage
Use this property to update UI elements or apply logic based on the participant's video stream status.
Example
if (participant.CamEnabled)
{
Debug.Log("Camera is enabled.");
}
else
{
Debug.Log("Camera is disabled.");
}
MicEnabled
The MicEnabled
property indicates whether the microphone (audio stream) is currently enabled for the participant associated with the VideoSurface
. Returns true
if the participant's microphone is enabled; otherwise, returns false
.
Type
bool
Usage
Use this property to control UI elements or logic that depends on the participant's audio status.
Example
if (participant.MicEnabled)
{
Debug.Log("Microphone is enabled.");
}
else
{
Debug.Log("Microphone is disabled.");
}
FlipTexture
- The
FlipTexture
property is used to horizontally flip the video texture rendered on theVideoSurface
. - When set to
true
, the video stream is mirrored horizontally. This is commonly used for displaying the local participant’s video in a mirrored view (like a front-facing camera). Setting it tofalse
displays the video as-is.
Type
bool
Usage
Modify this property to change the orientation of the video stream at runtime.
Example
// Enable horizontal flip
participant.FlipTexture = true;
// Disable horizontal flip
participant.FlipTexture = false;
Got a Question? Ask us on discord