这是 实验性技术
检查 浏览器兼容性表格 要小心谨慎在生产中使用这之前。

ImageBitmapRenderingContext interface is a canvas rendering context that provides the functionality to replace the canvas's contents with the given ImageBitmap . Its context id (the first argument to HTMLCanvasElement.getContext() or OffscreenCanvas.getContext() ) is "bitmaprenderer" .

This interface is available in both the window and the worker 上下文。

方法

ImageBitmapRenderingContext.transferFromImageBitmap()

显示给定 ImageBitmap in the canvas associated with this rendering context. Ownership of the ImageBitmap is transferred to the canvas. This was previously named transferImageBitmap() , but was renamed in a spec change. The old name is being kept as an alias to avoid code breakage.

规范

规范 状态 注释
HTML 实时标准
The definition of 'ImageBitmapRenderingContext' in that specification.
实时标准

浏览器兼容性

The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request. 更新 GitHub 上的兼容性数据
桌面 移动
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
ImageBitmapRenderingContext Chrome 66 Edge ≤79 Firefox 46 IE 不支持 No Opera Yes Safari 不支持 No WebView Android 66 Chrome Android 66 Firefox Android 46 Opera Android Yes Safari iOS ? Samsung Internet Android 9.0
transferFromImageBitmap Chrome 66 Edge ≤79 Firefox 52
52
46 — 52 Alternate Name
Alternate Name Uses the non-standard name: transferImageBitmap
IE 不支持 No Opera Yes Safari 不支持 No WebView Android 66 Chrome Android 66 Firefox Android 52
52
46 — 52 Alternate Name
Alternate Name Uses the non-standard name: transferImageBitmap
Opera Android Yes Safari iOS ? Samsung Internet Android 9.0

图例

完整支持

完整支持

不支持

不支持

兼容性未知 ?

兼容性未知

实验。期望将来行为有所改变。

实验。期望将来行为有所改变。

使用非标名称。

使用非标名称。

另请参阅

元数据

  • 最后修改: