draw android in green thanks to my wife, rename exp/draw to image/draw
This commit is contained in:
parent
f4c73f5f01
commit
bfefaf854b
10 changed files with 11 additions and 11 deletions
|
@ -2,8 +2,8 @@ package main
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"exp/draw"
|
||||
"exp/draw/x11"
|
||||
"image/draw"
|
||||
"image/draw/x11"
|
||||
"image"
|
||||
"math"
|
||||
"draw2d.googlecode.com/hg/draw2d"
|
||||
|
|
|
@ -91,7 +91,7 @@ func android(gc draw2d.GraphicContext, x, y float64) {
|
|||
|
||||
func main() {
|
||||
i, gc := initGc(width, height)
|
||||
gc.SetFillColor(image.RGBAColor{0xff, 0x44, 0x44, 0xff})
|
||||
gc.SetFillColor(image.RGBAColor{0x44, 0xff, 0x44, 0xff})
|
||||
gc.SetStrokeColor(image.RGBAColor{0x44, 0x44, 0x44, 0xff})
|
||||
android(gc, 10, 10)
|
||||
saveToPngFile("TestAndroid", i)
|
||||
|
|
|
@ -9,7 +9,7 @@ import (
|
|||
"image"
|
||||
"time"
|
||||
"image/png"
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"draw2d.googlecode.com/hg/draw2d"
|
||||
)
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ import (
|
|||
"bufio"
|
||||
"image"
|
||||
"image/png"
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"draw2d.googlecode.com/hg/draw2d/raster"
|
||||
)
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
package draw2d
|
||||
|
||||
import (
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"image"
|
||||
"log"
|
||||
"freetype-go.googlecode.com/hg/freetype"
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
package draw2d
|
||||
|
||||
import (
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"image"
|
||||
"freetype-go.googlecode.com/hg/freetype/raster"
|
||||
)
|
||||
|
@ -40,7 +40,7 @@ func (r *NRGBAPainter) Paint(ss []raster.Span, done bool) {
|
|||
}
|
||||
base := s.Y * r.Image.Stride
|
||||
p := r.Image.Pix[base+s.X0 : base+s.X1]
|
||||
// This code is duplicated from drawGlyphOver in $GOROOT/src/pkg/exp/draw/draw.go.
|
||||
// This code is duplicated from drawGlyphOver in $GOROOT/src/pkg/image/draw/draw.go.
|
||||
// TODO(nigeltao): Factor out common code into a utility function, once the compiler
|
||||
// can inline such function calls.
|
||||
ma := s.A >> 16
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
package raster
|
||||
|
||||
import (
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"image"
|
||||
)
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
package draw2d
|
||||
|
||||
import (
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"image"
|
||||
"math"
|
||||
)
|
||||
|
|
|
@ -2,7 +2,7 @@ package draw2dgl
|
|||
|
||||
import (
|
||||
"image"
|
||||
"exp/draw"
|
||||
"image/draw"
|
||||
"gl"
|
||||
"freetype-go.googlecode.com/hg/freetype/raster"
|
||||
"draw2d.googlecode.com/hg/draw2d"
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 4.5 KiB |
Loading…
Reference in a new issue