ascii

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 20, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

The ascii package can convert a image pixel to a raw char base on it's RGBA value, in another word, input a image pixel output a raw char ascii.

Index

Constants

This section is empty.

Variables

View Source
var DefaultOptions = Options{
	Pixels:  []byte(" .,:;i1tfLCG08@"),
	Reverse: false,
	Colored: true,
}

Default options

Functions

func ConvertPixelToASCII

func ConvertPixelToASCII(pixel color.Color, options *Options) string

Convert a pixel to a ASCII char string

Types

type Options

type Options struct {
	Pixels  []byte
	Reverse bool
	Colored bool
}

Convert options

func NewOptions

func NewOptions() Options

Create a new options

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL