mirror of
https://github.com/golang/go
synced 2024-11-25 04:07:55 -07:00
doc/articles/image_draw.html: Change ColorImage to Uniform
Fixes #3474. R=nigeltao CC=golang-dev https://golang.org/cl/6048050
This commit is contained in:
parent
5694ebf057
commit
e03dd509d4
@ -89,7 +89,7 @@ interface which has a <code>Set</code> method.
|
|||||||
|
|
||||||
<p>
|
<p>
|
||||||
To fill a rectangle with a solid color, use an <code>image.Uniform</code>
|
To fill a rectangle with a solid color, use an <code>image.Uniform</code>
|
||||||
source. The <code>ColorImage</code> type re-interprets a <code>Color</code> as a
|
source. The <code>Uniform</code> type re-interprets a <code>Color</code> as a
|
||||||
practically infinite-sized <code>Image</code> of that color. For those
|
practically infinite-sized <code>Image</code> of that color. For those
|
||||||
familiar with the design of Plan 9's draw library, there is no need
|
familiar with the design of Plan 9's draw library, there is no need
|
||||||
for an explicit "repeat bit" in Go's slice-based image types; the
|
for an explicit "repeat bit" in Go's slice-based image types; the
|
||||||
@ -189,7 +189,7 @@ To draw an image through a circular mask with center <code>p</code> and radius
|
|||||||
|
|
||||||
<p>
|
<p>
|
||||||
To draw a font glyph in blue starting from a point <code>p</code>, draw with
|
To draw a font glyph in blue starting from a point <code>p</code>, draw with
|
||||||
an <code>image.ColorImage</code> source and an <code>image.Alpha mask</code>. For
|
an <code>image.Uniform</code> source and an <code>image.Alpha mask</code>. For
|
||||||
simplicity, we aren't performing any sub-pixel positioning or
|
simplicity, we aren't performing any sub-pixel positioning or
|
||||||
rendering, or correcting for a font's height above a baseline.
|
rendering, or correcting for a font's height above a baseline.
|
||||||
</p>
|
</p>
|
||||||
|
Loading…
Reference in New Issue
Block a user