MCPcopy
hub / github.com/fogleman/nes / copyImage

Function copyImage

ui/util.go:151–155  ·  view source on GitHub ↗
(src image.Image)

Source from the content-addressed store, hash-verified

149}
150
151func copyImage(src image.Image) *image.RGBA {
152 dst := image.NewRGBA(src.Bounds())
153 draw.Draw(dst, dst.Rect, src, image.ZP, draw.Src)
154 return dst
155}
156
157func loadPNG(path string) (image.Image, error) {
158 file, err := os.Open(path)

Callers 2

UpdateMethod · 0.85
loadMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected