Documentation ¶
Overview ¶
Package client implements communication with the asciist service.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
A Client provides convenient interaction with the asciist service.
func New ¶
New creates a new Client for a service rooted at the given url. It uses the default net/http Client to talk to the service.
func NewWithHTTP ¶
NewWithHTTP creates a new Client for a service rooted at the given url, using the given http Client for communication.
func (*Client) Convert ¶
Convert asks the service to create ASCII art based on the image whose contents can be read out of the given reader. The art returned will be `width` characters wide, with a height chosen by the service to match the input image's aspect ratio when drawn with typical monospace fonts at a typical line height.
func (*Client) ConvertBytes ¶
ConvertBytes asks the service to create ASCII art based on the image whose contents are contained in the given byte slice. The art returned will be `width` characters wide, with a height chosen by the service to match the input image's aspect ratio when drawn with typical monospace fonts at a typical line height.
func (*Client) ConvertFile ¶
ConvertFile asks the service to create ASCII art based on the image with the given filename. The art returned will be `width` characters wide, with a height chosen by the service to match the input image's aspect ratio when drawn with typical monospace fonts at a typical line height.