-
Notifications
You must be signed in to change notification settings - Fork 8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[zh-cn]: update the translation of CanvasRenderingContext2D.getImageData()
method
#22003
base: main
Are you sure you want to change the base?
Conversation
Preview URLs Flaws (1)URL:
External URLs (2)URL:
(comment last updated: 2024-07-07 16:16:18) |
- 定义此方法的接口:{{domxref("CanvasRenderingContext2D")}} | ||
- {{domxref("ImageData")}} object | ||
- {{domxref("CanvasRenderingContext2D.putImageData()")}} | ||
- [像素操作](/en-US/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[mdn-linter] reported by reviewdog 🐶
- [像素操作](/en-US/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas) | |
- [像素操作](/zh-CN/docs/Web/API/Canvas_API/Tutorial/Pixel_manipulation_with_canvas) |
--- | ||
|
||
{{APIRef}} | ||
|
||
**`CanvasRenderingContext2D.getImageData()`** 返回一个{{domxref("ImageData")}}对象,用来描述 canvas 区域隐含的像素数据,这个区域通过矩形表示,起始点为*(sx, sy)、*宽为*sw、*高为*sh。* | ||
Canvas 2D API 的 **`CanvasRenderingContext2D.getImageData()`** 返回一个{{domxref("ImageData")}}对象,用于描述 canvas 指定区域的隐含像素数据。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
空格
- : 要提取 `ImageData` 的矩形的高度。正值向下延伸,负值向上延伸。 | ||
- `settings` {{optional_inline}} | ||
- : 一个具有以下属性的对象: | ||
- `colorSpace`:指定图像数据的颜色空间。可以设置为 `"srgb"` 表示 [sRGB 色彩空间](https://zh.wikipedia.org/wiki/SRGB),或 `"display-p3"` 表示 [display-p3 色彩空间](https://zh.wikipedia.org/wiki/DCI-P3)。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sRGB 色彩空间的维基百科链接是不对的:https://zh.wikipedia.org/wiki/SRGB色彩空间
其他的几个 PR 里面也有类似的情况,请都修复一下。
@@ -1,76 +1,116 @@ | |||
--- | |||
title: CanvasRenderingContext2D.getImageData() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
标题更新,其他的 PR 也类似
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CanvasRenderingContext2D:getImageData() 方法
吗。之前合并的pr中有CanvasRenderingContext2D.getImageData()
,这之间是如何区别的
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
请沿用英文文档的格式,之前合并的那个 PR 我没有注意到标题
- : 要提取 `ImageData` 的矩形的高度。正值向下延伸,负值向上延伸。 | ||
- `settings` {{optional_inline}} | ||
- : 一个具有以下属性的对象: | ||
- `colorSpace`:指定图像数据的颜色空间。可以设置为 `"srgb"` 表示 [sRGB 色彩空间](https://zh.wikipedia.org/wiki/SRGB),或 `"display-p3"` 表示 [display-p3 色彩空间](https://zh.wikipedia.org/wiki/DCI-P3)。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- `colorSpace`:指定图像数据的颜色空间。可以设置为 `"srgb"` 表示 [sRGB 色彩空间](https://zh.wikipedia.org/wiki/SRGB),或 `"display-p3"` 表示 [display-p3 色彩空间](https://zh.wikipedia.org/wiki/DCI-P3)。 | |
- `colorSpace`:指定图像数据的颜色空间。可以设置为 `"srgb"` 表示 [sRGB 色彩空间](https://zh.wikipedia.org/wiki/SRGB色彩空间),或 `"display-p3"` 表示 [display-p3 色彩空间](https://zh.wikipedia.org/wiki/DCI-P3)。 |
files/zh-cn/web/api/canvasrenderingcontext2d/getimagedata/index.md
Outdated
Show resolved
Hide resolved
--- | ||
|
||
{{APIRef}} | ||
|
||
**`CanvasRenderingContext2D.getImageData()`** 返回一个{{domxref("ImageData")}}对象,用来描述 canvas 区域隐含的像素数据,这个区域通过矩形表示,起始点为*(sx, sy)、*宽为*sw、*高为*sh。* | ||
Canvas 2D API 的 **`CanvasRenderingContext2D.getImageData()`** 返回一个{{domxref("ImageData")}}对象,用于描述 canvas 指定区域的隐含像素数据。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Canvas 2D API 的 **`CanvasRenderingContext2D.getImageData()`** 返回一个{{domxref("ImageData")}}对象,用于描述 canvas 指定区域的隐含像素数据。 | |
Canvas 2D API 的 **`CanvasRenderingContext2D.getImageData()`** 返回一个 {{domxref("ImageData")}} 对象,用于描述 canvas 指定区域的隐含像素数据。 |
|
||
## 示例 | ||
|
||
### 使用 `getImageData` 方法 | ||
Here is the translation of the example and its details into Chinese: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?
|
||
## 示例 | ||
|
||
### 使用 `getImageData` 方法 | ||
Here is the translation of the example and its details into Chinese: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here is the translation of the example and its details into Chinese: |
…Data()` method
Description
Motivation
Additional details
Related issues and pull requests