VideoFrame: close() method

Baseline 2024
Newly available

Since September 2024, this feature works across the latest devices and browser versions. This feature might not work in older devices or browsers.

Note: This feature is available in Dedicated Web Workers.

Phương thức close() của giao diện VideoFrame xóa tất cả trạng thái và giải phóng tham chiếu đến tài nguyên media.

Cú pháp

js
close()

Tham số

Không có.

Giá trị trả về

Undefined.

Ví dụ

Ví dụ sau cho thấy đối tượng VideoFrame đang được đóng.

js
VideoFrame.close();

Thông số kỹ thuật

Thông số kỹ thuật
WebCodecs
# dom-videoframe-close

Tương thích trình duyệt