MediaSFU Angular
    Preparing search index...

    Class CardVideoDisplay

    CardVideoDisplay component displays a video stream with options for full display, mirroring, and background color customization.

    app-card-video-display

    true

    CommonModule

    • remoteProducerId (string): Identifier for the remote producer.
    • eventType (EventType): Type of event, such as 'webinar'. Default is 'webinar'.
    • forceFullDisplay (boolean): Forces full video display if true. Default is false.
    • videoStream (MediaStream | null): The media stream to display in the video element.
    • backgroundColor (string): Background color for the video container. Default is 'transparent'.
    • doMirror (boolean): Mirrors the video if true. Default is false.
    • ngOnInit(): Initializes the video stream and sets the container style on component load.
    • ngOnChanges(changes: SimpleChanges): Updates the video stream or container style when inputs change.
    • updateVideoStream(): Assigns the video stream to the video element if it differs from the current stream.
    • setVideoContainerStyle(): Sets the style of the video container based on the provided background color.
    • getBaseVideoContainerStyle(): Returns base styles for the video container.
    • getVideoStyle(): Returns styles for the video element, including optional mirroring and sizing.
    <app-card-video-display
    [remoteProducerId]="producerId"
    [eventType]="'conference'"
    [forceFullDisplay]="true"
    [videoStream]="stream"
    [backgroundColor]="'black'"
    [doMirror]="true">
    </app-card-video-display>

    Implements

    • OnInit
    • OnChanges
    Index

    Constructors

    Methods

    • A callback method that is invoked immediately after the default change detector has checked the directive's data-bound properties for the first time, and before any of the view or content children have been checked. It is invoked only once when the directive is instantiated.

      Returns void

    • A callback method that is invoked immediately after the default change detector has checked data-bound properties if at least one has changed, and before the view and content children are checked.

      Parameters

      • changes: SimpleChanges

        The changed properties.

      Returns void

    • Returns {
          display: string;
          justifyContent: string;
          alignItems: string;
          width: string;
          height: string;
          backgroundColor: string;
      }

    Properties

    remoteProducerId: string = ''
    eventType: EventType = 'webinar'
    forceFullDisplay: boolean = false
    videoStream: MediaStream | null = null
    backgroundColor: string = 'transparent'
    doMirror: boolean = false
    videoElement: ElementRef<HTMLVideoElement>
    videoContainerStyle: any