Skip to content

Instantly share code, notes, and snippets.

View ikatake's full-sized avatar

ikatake ikatake

View GitHub Profile
@ikatake
ikatake / annotate_on_arc.rb
Created December 30, 2017 05:55
rmagick annotate on arc
require 'rmagick'
iclude Math
def annotate_on_arc(img, str, wc, r, x0, y0, theta0, font, fill, stroke, size)
# img rmagick draw Macick::Image object
# str annotate string
# wc width of one charator[px]
# r, x0 ,y0 radius and center point[px] of circle(arc)
# theta0 angle at center of string[rad]
# font, size font familiy and font size[pt?]