Skip to content

haashemi/painter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎨 Painter (WIP)

A simple utility Golang package to help you with drawing on images

This package is currently work-in-progress and subject to change at any time.

Installation

$ go get github.com/haashemi/painter@main

Example

There are some examples in drawers_test.go, but here is one of them:

package main

import (
	"image/color"
	"math"

	"github.com/haashemi/painter"
)

func main() {
	img := painter.New(width, height)

	black := color.NRGBA{0, 0, 0, 255}
	white := color.NRGBA{255, 255, 255, 255}

	painter.DrawLinearGradient(img, img.Rect, math.Pi/4, black, white)

	painter.SavePNG(img, "painter.png")
}

Contributions

All type of contributions are highly appreciated. <3

About

🎨 A simple NRGBA image drawing package for Go

Resources

License

Stars

Watchers

Forks

Contributors 2

  •  
  •  

Languages