0.0
No release in over 3 years
Low commit activity in last 3 years
Convert ASCII art to PNGs in pure Ruby.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0
~> 2.14.1

Runtime

~> 1.2.9
 Project Readme

ASCII paint

Convert ASCII art to PNG.

Usage

text = "
 !!!!! @@@@@ $$$$$ %%%%% ^^^^^       @@@@@ $$$$$ %%%%% ^   ^ !!!!! 
 !   ! @     $       %     ^         @   @ $   $   %   ^^  ^   !   
 !!!!! @@@@@ $       %     ^         @@@@@ $$$$$   %   ^ ^ ^   !   
 !   !     @ $       %     ^         @     $   $   %   ^  ^^   !   
 !   ! @@@@@ $$$$$ %%%%% ^^^^^ !!!!! @     $   $ %%%%% ^   ^   !   
"
AsciiPaint.paint(text, 'out.png')

Configuration

Use AsciiPaint.config to define your personal painting style.

AsciiPaint.config do |config|
  config.character_width = 10
  config.character_height = 10
  config.color_map = { '!' => :blue, '@' => :red, '$' => :yellow }
end

You can also customize individual paintings by passing options to AsciiPaint.paint

AsciiPaint.paint(text, 'out.png', character_width: 10, character_height: 10)

Demonstration

ASCII paint logo

License

MIT