Mosaic::Renderer
Mosaic represents a Unicode image renderer.
Example:
art = Mosaic::Renderer.new.width(100) # Limit to 100 cells
.scale(2) # Scale factor
.render(image)
Constructors
Instance methods
dither?
Sourceheight(height : Int) : self
Height sets the maximum height the image can have. Defaults to the image height.
invert_colors(invert : Bool) : self
InvertColors whether to invert the colors of the mosaic image.
invert_colors?
Sourceoutput_height
Sourceoutput_width
Sourcescale
Sourcesymbols
Sourcethreshold(threshold : Int) : self
Threshold sets the threshold level on [Renderer]. It expects a value between 0-255, anything else will be ignored.
threshold_level
Sourceuse_fg_bg_only?
Source