image_paradise 0.4.8

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of image_paradise might be problematic. Click here for more details.

Files changed (649) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.md +38 -0
  3. data/README.md +928 -0
  4. data/USAGE.md +10 -0
  5. data/bin/black_white +10 -0
  6. data/bin/confree_generator +7 -0
  7. data/bin/create_new_image +7 -0
  8. data/bin/display_text_from_this_image +7 -0
  9. data/bin/draw_as_specified_from_the_yaml_file +7 -0
  10. data/bin/embed_the_filename_into_this_image +7 -0
  11. data/bin/image_paradise +7 -0
  12. data/bin/image_paradise_shell +7 -0
  13. data/bin/image_to_ascii +54 -0
  14. data/bin/image_to_pdf +7 -0
  15. data/bin/imageparadise_img2pdf +12 -0
  16. data/bin/img_text +14 -0
  17. data/bin/interlace +7 -0
  18. data/bin/jpg_to_pdf +12 -0
  19. data/bin/magic_card_border +8 -0
  20. data/bin/make_this_image_transparent +7 -0
  21. data/bin/morph_these_images +7 -0
  22. data/bin/optimize_this_image +7 -0
  23. data/bin/quality +7 -0
  24. data/bin/resize_by_percent +10 -0
  25. data/bin/rotate_left +7 -0
  26. data/bin/rotate_right +7 -0
  27. data/bin/round_the_corner +7 -0
  28. data/bin/ruby_montage +7 -0
  29. data/bin/transparent +15 -0
  30. data/doc/README.gen +871 -0
  31. data/doc/todo/TODO_FOR_THE_GTK_GUI.md +9 -0
  32. data/doc/todo/TODO_FOR_THE_IMAGE_PARADISE_PROJECT.md +22 -0
  33. data/doc/todo/TODO_WORK_THROUGH_THESE_LINKS.md +3 -0
  34. data/doc/todo/todo_for_the_libui_gui.md +4 -0
  35. data/image_paradise.gemspec +46 -0
  36. data/images/IMAGE_PARADISE_LOGO.png +0 -0
  37. data/lib/image_paradise/base/base.rb +293 -0
  38. data/lib/image_paradise/cfdg/1dca_pattern.cfdg +48 -0
  39. data/lib/image_paradise/cfdg/3d_coloured_cube.cfdg +95 -0
  40. data/lib/image_paradise/cfdg/a_3D_spiral.cfdg +40 -0
  41. data/lib/image_paradise/cfdg/a_chaotic_city.cfdg +156 -0
  42. data/lib/image_paradise/cfdg/a_coloured_red.cfdg +21 -0
  43. data/lib/image_paradise/cfdg/a_daisy_flower.cfdg +66 -0
  44. data/lib/image_paradise/cfdg/a_decorated_window.cfdg +74 -0
  45. data/lib/image_paradise/cfdg/a_human_profile.cfdg +303 -0
  46. data/lib/image_paradise/cfdg/a_lost_heart.cfdg +28 -0
  47. data/lib/image_paradise/cfdg/a_plant_root.cfdg +26 -0
  48. data/lib/image_paradise/cfdg/a_rather_realistic_forest.cfdg +29 -0
  49. data/lib/image_paradise/cfdg/a_shoreline_next_to_a_forest.cfdg +127 -0
  50. data/lib/image_paradise/cfdg/a_simple_mini_brain.cfdg +17 -0
  51. data/lib/image_paradise/cfdg/a_simple_star.cfdg +22 -0
  52. data/lib/image_paradise/cfdg/adorned_tree.cfdg +58 -0
  53. data/lib/image_paradise/cfdg/adsorption.cfdg +19 -0
  54. data/lib/image_paradise/cfdg/alfabet_free.cfdg +346 -0
  55. data/lib/image_paradise/cfdg/alfreebet.cfdg +229 -0
  56. data/lib/image_paradise/cfdg/algal_flora.cfdg +25 -0
  57. data/lib/image_paradise/cfdg/alien_eyeball.cfdg +15 -0
  58. data/lib/image_paradise/cfdg/alien_flower.cfdg +35 -0
  59. data/lib/image_paradise/cfdg/alphabet_circles.cfdg +38 -0
  60. data/lib/image_paradise/cfdg/alveolo.cfdg +38 -0
  61. data/lib/image_paradise/cfdg/an_icosahedron.cfdg +134 -0
  62. data/lib/image_paradise/cfdg/an_oils_surface.cfdg +48 -0
  63. data/lib/image_paradise/cfdg/ancient_map.cfdg +30 -0
  64. data/lib/image_paradise/cfdg/ancient_scripts_tile.cfdg +96 -0
  65. data/lib/image_paradise/cfdg/angelfish.cfdg +58 -0
  66. data/lib/image_paradise/cfdg/angry_yarn.cfdg +82 -0
  67. data/lib/image_paradise/cfdg/apple_tree_small.cfdg +46 -0
  68. data/lib/image_paradise/cfdg/aqua_star.cfdg +27 -0
  69. data/lib/image_paradise/cfdg/army_explosion.cfdg +25 -0
  70. data/lib/image_paradise/cfdg/arrows_in_quadcity.cfdg +143 -0
  71. data/lib/image_paradise/cfdg/artificial_intelligence.cfdg +41 -0
  72. data/lib/image_paradise/cfdg/askew.cfdg +27 -0
  73. data/lib/image_paradise/cfdg/audio_diagram_waves.cfdg +54 -0
  74. data/lib/image_paradise/cfdg/autumn_fractal.cfdg +39 -0
  75. data/lib/image_paradise/cfdg/baignoire.cfdg +33 -0
  76. data/lib/image_paradise/cfdg/barcode.cfdg +781 -0
  77. data/lib/image_paradise/cfdg/basic_polygon_shapes.cfdg +311 -0
  78. data/lib/image_paradise/cfdg/basic_spreaders.cfdg +52 -0
  79. data/lib/image_paradise/cfdg/basic_square.cfdg +8 -0
  80. data/lib/image_paradise/cfdg/bats_hiding_in_foliage.cfdg +19 -0
  81. data/lib/image_paradise/cfdg/bees.cfdg +61 -0
  82. data/lib/image_paradise/cfdg/bent_squares.cfdg +46 -0
  83. data/lib/image_paradise/cfdg/benzo_dreaming.cfdg +54 -0
  84. data/lib/image_paradise/cfdg/beta_bet.cfdg +645 -0
  85. data/lib/image_paradise/cfdg/big_bang_theory.cfdg +31 -0
  86. data/lib/image_paradise/cfdg/big_pacman.cfdg +70 -0
  87. data/lib/image_paradise/cfdg/bigger_tree.cfdg +64 -0
  88. data/lib/image_paradise/cfdg/binary_connection.cfdg +34 -0
  89. data/lib/image_paradise/cfdg/birch_line.cfdg +57 -0
  90. data/lib/image_paradise/cfdg/blacksmith_masterpiece.cfdg +3 -0
  91. data/lib/image_paradise/cfdg/blocked_rectangles.cfdg +23 -0
  92. data/lib/image_paradise/cfdg/blood_tubes.cfdg +45 -0
  93. data/lib/image_paradise/cfdg/bloom.cfdg +23 -0
  94. data/lib/image_paradise/cfdg/blown_glass_spheres.cfdg +30 -0
  95. data/lib/image_paradise/cfdg/blue_daisies_in_detail.cfdg +101 -0
  96. data/lib/image_paradise/cfdg/blue_galaxy.cfdg +20 -0
  97. data/lib/image_paradise/cfdg/blue_moon.cfdg +36 -0
  98. data/lib/image_paradise/cfdg/boa_feathers.cfdg +53 -0
  99. data/lib/image_paradise/cfdg/bomb.cfdg +75 -0
  100. data/lib/image_paradise/cfdg/boxy_continent.cfdg +111 -0
  101. data/lib/image_paradise/cfdg/bright_coloured_neurons.cfdg +53 -0
  102. data/lib/image_paradise/cfdg/brightness_flower.cfdg +31 -0
  103. data/lib/image_paradise/cfdg/btp_71_beautiful_coloured_lines.cfdg +85 -0
  104. data/lib/image_paradise/cfdg/btp_73.cfdg +76 -0
  105. data/lib/image_paradise/cfdg/bubblesun.cfdg +46 -0
  106. data/lib/image_paradise/cfdg/burning_bush.cfdg +31 -0
  107. data/lib/image_paradise/cfdg/butterflies_in_the_moonlight.cfdg +55 -0
  108. data/lib/image_paradise/cfdg/cardiod_arc.cfdg +44 -0
  109. data/lib/image_paradise/cfdg/cardioid.cfdg +41 -0
  110. data/lib/image_paradise/cfdg/caros_wallpaper.cfdg +46 -0
  111. data/lib/image_paradise/cfdg/cartoony_face_arrays.cfdg +137 -0
  112. data/lib/image_paradise/cfdg/centerfold.cfdg +12 -0
  113. data/lib/image_paradise/cfdg/chain_link_fence.cfdg +31 -0
  114. data/lib/image_paradise/cfdg/chanukah.cfdg +109 -0
  115. data/lib/image_paradise/cfdg/chaos_red_sun.cfdg +42 -0
  116. data/lib/image_paradise/cfdg/chaotic_farn.cfdg +76 -0
  117. data/lib/image_paradise/cfdg/chaotic_fractal_shell.cfdg +41 -0
  118. data/lib/image_paradise/cfdg/charleston.cfdg +182 -0
  119. data/lib/image_paradise/cfdg/ciliasun.cfdg +109 -0
  120. data/lib/image_paradise/cfdg/cipal.cfdg +65 -0
  121. data/lib/image_paradise/cfdg/circuits.cfdg +176 -0
  122. data/lib/image_paradise/cfdg/city_map.cfdg +66 -0
  123. data/lib/image_paradise/cfdg/clifford_torus.cfdg +135 -0
  124. data/lib/image_paradise/cfdg/colonize_flat_colour_pattern.cfdg +14 -0
  125. data/lib/image_paradise/cfdg/colour_blind_squid.cfdg +30 -0
  126. data/lib/image_paradise/cfdg/colour_hole.cfdg +56 -0
  127. data/lib/image_paradise/cfdg/colour_wheel.cfdg +40 -0
  128. data/lib/image_paradise/cfdg/coloured_eyes.cfdg +40 -0
  129. data/lib/image_paradise/cfdg/coloured_forest.cfdg +133 -0
  130. data/lib/image_paradise/cfdg/coloured_tree.cfdg +50 -0
  131. data/lib/image_paradise/cfdg/colourful_lives.cfdg +123 -0
  132. data/lib/image_paradise/cfdg/colourful_neuronal_network.cfdg +32 -0
  133. data/lib/image_paradise/cfdg/complex_city_plans.cfdg +75 -0
  134. data/lib/image_paradise/cfdg/complex_kritworks.cfdg +75 -0
  135. data/lib/image_paradise/cfdg/complex_snowflake.cfdg +61 -0
  136. data/lib/image_paradise/cfdg/conspiracy_theory.cfdg +104 -0
  137. data/lib/image_paradise/cfdg/constellation_grid.cfdg +29 -0
  138. data/lib/image_paradise/cfdg/cool_caterpillar.cfdg +44 -0
  139. data/lib/image_paradise/cfdg/coolcubes.cfdg +70 -0
  140. data/lib/image_paradise/cfdg/crawler_battle.cfdg +93 -0
  141. data/lib/image_paradise/cfdg/crazy_octo.cfdg +48 -0
  142. data/lib/image_paradise/cfdg/cthulhu.cfdg +166 -0
  143. data/lib/image_paradise/cfdg/cubies.cfdg +43 -0
  144. data/lib/image_paradise/cfdg/cubist_sunset.cfdg +55 -0
  145. data/lib/image_paradise/cfdg/curled_tree.cfdg +37 -0
  146. data/lib/image_paradise/cfdg/curls.cfdg +45 -0
  147. data/lib/image_paradise/cfdg/curve_stiched.cfdg +59 -0
  148. data/lib/image_paradise/cfdg/curved_tubes.cfdg +20 -0
  149. data/lib/image_paradise/cfdg/cylinder_city.cfdg +27 -0
  150. data/lib/image_paradise/cfdg/cymbal.cfdg +38 -0
  151. data/lib/image_paradise/cfdg/d_mustard.cfdg +52 -0
  152. data/lib/image_paradise/cfdg/dance_party.cfdg +81 -0
  153. data/lib/image_paradise/cfdg/dance_party_and_background.cfdg +86 -0
  154. data/lib/image_paradise/cfdg/decreasing_aperture.cfdg +16 -0
  155. data/lib/image_paradise/cfdg/delicat_twist.cfdg +13 -0
  156. data/lib/image_paradise/cfdg/demo_text.cfdg +22 -0
  157. data/lib/image_paradise/cfdg/dennis_ritchie.cfdg +294 -0
  158. data/lib/image_paradise/cfdg/diablo.cfdg +47 -0
  159. data/lib/image_paradise/cfdg/different_flowers.cfdg +60 -0
  160. data/lib/image_paradise/cfdg/different_snowflakes_shapes.cfdg +149 -0
  161. data/lib/image_paradise/cfdg/dimensions.cfdg +33 -0
  162. data/lib/image_paradise/cfdg/domino_pieces.cfdg +166 -0
  163. data/lib/image_paradise/cfdg/dong.cfdg +41 -0
  164. data/lib/image_paradise/cfdg/drip_shape.cfdg +24 -0
  165. data/lib/image_paradise/cfdg/earthday2007b.cfdg +49 -0
  166. data/lib/image_paradise/cfdg/edera_circles.cfdg +55 -0
  167. data/lib/image_paradise/cfdg/eight_queens_problem.cfdg +85 -0
  168. data/lib/image_paradise/cfdg/electro_shock.cfdg +88 -0
  169. data/lib/image_paradise/cfdg/enter_the_force_field.cfdg +56 -0
  170. data/lib/image_paradise/cfdg/escargot_fleur.cfdg +98 -0
  171. data/lib/image_paradise/cfdg/european_city.cfdg +63 -0
  172. data/lib/image_paradise/cfdg/evil_eye.cfdg +74 -0
  173. data/lib/image_paradise/cfdg/evolving_coloured_spots.cfdg +47 -0
  174. data/lib/image_paradise/cfdg/excellines_nr2.cfdg +171 -0
  175. data/lib/image_paradise/cfdg/exoplanet_settlement.cfdg +117 -0
  176. data/lib/image_paradise/cfdg/explosion.cfdg +45 -0
  177. data/lib/image_paradise/cfdg/explosion_of_a_megabyte.cfdg +73 -0
  178. data/lib/image_paradise/cfdg/eye_of_katora.cfdg +20 -0
  179. data/lib/image_paradise/cfdg/family_tree.cfdg +169 -0
  180. data/lib/image_paradise/cfdg/feathers.cfdg +17 -0
  181. data/lib/image_paradise/cfdg/ferma_drawings.cfdg +23 -0
  182. data/lib/image_paradise/cfdg/fevrier.cfdg +66 -0
  183. data/lib/image_paradise/cfdg/fibmod.cfdg +25 -0
  184. data/lib/image_paradise/cfdg/field_of_boxes.cfdg +21 -0
  185. data/lib/image_paradise/cfdg/finetre.cfdg +34 -0
  186. data/lib/image_paradise/cfdg/fireblorks.cfdg +37 -0
  187. data/lib/image_paradise/cfdg/first_branch.cfdg +18 -0
  188. data/lib/image_paradise/cfdg/fish_with_coloured_bubbles.cfdg +77 -0
  189. data/lib/image_paradise/cfdg/fishing_lure.cfdg +30 -0
  190. data/lib/image_paradise/cfdg/flake.cfdg +20 -0
  191. data/lib/image_paradise/cfdg/flaming_spiro.cfdg +10 -0
  192. data/lib/image_paradise/cfdg/fleshflower.cfdg +25 -0
  193. data/lib/image_paradise/cfdg/flourescent_fish_btp.cfdg +48 -0
  194. data/lib/image_paradise/cfdg/flow_control_shape.cfdg +45 -0
  195. data/lib/image_paradise/cfdg/flower_galaxy.cfdg +57 -0
  196. data/lib/image_paradise/cfdg/flower_house.cfdg +115 -0
  197. data/lib/image_paradise/cfdg/flower_stories.cfdg +136 -0
  198. data/lib/image_paradise/cfdg/fluctuating_heart.cfdg +87 -0
  199. data/lib/image_paradise/cfdg/fly_agaric.cfdg +22 -0
  200. data/lib/image_paradise/cfdg/forest_and_ocean.cfdg +65 -0
  201. data/lib/image_paradise/cfdg/fractal_fern.cfdg +15 -0
  202. data/lib/image_paradise/cfdg/fractal_shell.cfdg +36 -0
  203. data/lib/image_paradise/cfdg/frost_bite.cfdg +23 -0
  204. data/lib/image_paradise/cfdg/fun_with_paper.cfdg +17 -0
  205. data/lib/image_paradise/cfdg/func_plot.cfdg +59 -0
  206. data/lib/image_paradise/cfdg/funky_squiggle.cfdg +40 -0
  207. data/lib/image_paradise/cfdg/fuzzy_sun.cfdg +47 -0
  208. data/lib/image_paradise/cfdg/galaxy.cfdg +59 -0
  209. data/lib/image_paradise/cfdg/gallery.cfdg +28 -0
  210. data/lib/image_paradise/cfdg/game1_turn6.cfdg +35 -0
  211. data/lib/image_paradise/cfdg/garland.cfdg +42 -0
  212. data/lib/image_paradise/cfdg/general_polygons.cfdg +20 -0
  213. data/lib/image_paradise/cfdg/generational_birds.cfdg +118 -0
  214. data/lib/image_paradise/cfdg/ghostly_spine.cfdg +24 -0
  215. data/lib/image_paradise/cfdg/gift_wrapping.cfdg +46 -0
  216. data/lib/image_paradise/cfdg/glass_cubes.cfdg +33 -0
  217. data/lib/image_paradise/cfdg/gleaming_bush.cfdg +33 -0
  218. data/lib/image_paradise/cfdg/glowing_bush.cfdg +33 -0
  219. data/lib/image_paradise/cfdg/go_grid.cfdg +32 -0
  220. data/lib/image_paradise/cfdg/gold_tiles.cfdg +21 -0
  221. data/lib/image_paradise/cfdg/golden_rectangle.cfdg +19 -0
  222. data/lib/image_paradise/cfdg/golden_sierpinski.cfdg +49 -0
  223. data/lib/image_paradise/cfdg/golgi_stain.cfdg +74 -0
  224. data/lib/image_paradise/cfdg/gothic_bath_tiles.cfdg +14 -0
  225. data/lib/image_paradise/cfdg/grass_land.cfdg +112 -0
  226. data/lib/image_paradise/cfdg/gray_matter.cfdg +110 -0
  227. data/lib/image_paradise/cfdg/great_forest.cfdg +91 -0
  228. data/lib/image_paradise/cfdg/growth.cfdg +46 -0
  229. data/lib/image_paradise/cfdg/gumtree.cfdg +28 -0
  230. data/lib/image_paradise/cfdg/haggards_bull.cfdg +92 -0
  231. data/lib/image_paradise/cfdg/haight_ashbury.cfdg +882 -0
  232. data/lib/image_paradise/cfdg/hair_pattern.cfdg +59 -0
  233. data/lib/image_paradise/cfdg/hairy.cfdg +43 -0
  234. data/lib/image_paradise/cfdg/hairy_branch.cfdg +48 -0
  235. data/lib/image_paradise/cfdg/hands_and_feet.cfdg +49 -0
  236. data/lib/image_paradise/cfdg/happy_new_year.cfdg +3435 -0
  237. data/lib/image_paradise/cfdg/hatagu_lila_spiral.cfdg +27 -0
  238. data/lib/image_paradise/cfdg/hexaeder_triangle.cfdg +43 -0
  239. data/lib/image_paradise/cfdg/hexclouds_textures.cfdg +75 -0
  240. data/lib/image_paradise/cfdg/hextiles.cfdg +73 -0
  241. data/lib/image_paradise/cfdg/hexy_continent.cfdg +83 -0
  242. data/lib/image_paradise/cfdg/human_ballet.cfdg +215 -0
  243. data/lib/image_paradise/cfdg/human_eyes.cfdg +102 -0
  244. data/lib/image_paradise/cfdg/hydra_tail.cfdg +57 -0
  245. data/lib/image_paradise/cfdg/i_like_it_dirty.cfdg +88 -0
  246. data/lib/image_paradise/cfdg/i_pix.cfdg +679 -0
  247. data/lib/image_paradise/cfdg/imaginary_star.cfdg +55 -0
  248. data/lib/image_paradise/cfdg/imaginery_forest.cfdg +61 -0
  249. data/lib/image_paradise/cfdg/impossible_stairs.cfdg +211 -0
  250. data/lib/image_paradise/cfdg/in_the_morning.cfdg +83 -0
  251. data/lib/image_paradise/cfdg/inertial_confinement.cfdg +150 -0
  252. data/lib/image_paradise/cfdg/infected_shell.cfdg +56 -0
  253. data/lib/image_paradise/cfdg/insect_fight.cfdg +316 -0
  254. data/lib/image_paradise/cfdg/insectivore.cfdg +80 -0
  255. data/lib/image_paradise/cfdg/interference.cfdg +43 -0
  256. data/lib/image_paradise/cfdg/interference_fields.cfdg +25 -0
  257. data/lib/image_paradise/cfdg/into_the_deep.cfdg +96 -0
  258. data/lib/image_paradise/cfdg/inverted_decorations.cfdg +85 -0
  259. data/lib/image_paradise/cfdg/irregular_galaxies.cfdg +29 -0
  260. data/lib/image_paradise/cfdg/iso_blocks.cfdg +35 -0
  261. data/lib/image_paradise/cfdg/jewelry_old_style.cfdg +31 -0
  262. data/lib/image_paradise/cfdg/just_some_flowers.cfdg +127 -0
  263. data/lib/image_paradise/cfdg/kaboom.cfdg +40 -0
  264. data/lib/image_paradise/cfdg/kaleidoskop.cfdg +27 -0
  265. data/lib/image_paradise/cfdg/kama_sutra.cfdg +182 -0
  266. data/lib/image_paradise/cfdg/kitakoa_akiyoshi_illusions_roller.cfdg +40 -0
  267. data/lib/image_paradise/cfdg/koch_snowflake.cfdg +11 -0
  268. data/lib/image_paradise/cfdg/kochlea.cfdg +43 -0
  269. data/lib/image_paradise/cfdg/kreepykrawler.cfdg +48 -0
  270. data/lib/image_paradise/cfdg/kw_expanded_explosion.cfdg +46 -0
  271. data/lib/image_paradise/cfdg/lapsang_abstrait.cfdg +51 -0
  272. data/lib/image_paradise/cfdg/laser.cfdg +51 -0
  273. data/lib/image_paradise/cfdg/last_pluto_dream.cfdg +95 -0
  274. data/lib/image_paradise/cfdg/lazy_dust.cfdg +42 -0
  275. data/lib/image_paradise/cfdg/lesson_one_two_three_four.cfdg +217 -0
  276. data/lib/image_paradise/cfdg/lila_lili.cfdg +60 -0
  277. data/lib/image_paradise/cfdg/lindenmayergrassef2_pretty_flowers.cfdg +94 -0
  278. data/lib/image_paradise/cfdg/lines_from_excel.cfdg +136 -0
  279. data/lib/image_paradise/cfdg/looking_out.cfdg +51 -0
  280. data/lib/image_paradise/cfdg/looking_up_in_the_sky.cfdg +43 -0
  281. data/lib/image_paradise/cfdg/lotus_logo.cfdg +49 -0
  282. data/lib/image_paradise/cfdg/lowercased_alphabet.cfdg +565 -0
  283. data/lib/image_paradise/cfdg/luma_smiley.cfdg +563 -0
  284. data/lib/image_paradise/cfdg/maggi_stars.cfdg +11 -0
  285. data/lib/image_paradise/cfdg/mandelbrot_3.cfdg +111 -0
  286. data/lib/image_paradise/cfdg/martini.cfdg +147 -0
  287. data/lib/image_paradise/cfdg/material_studies.cfdg +172 -0
  288. data/lib/image_paradise/cfdg/math_eye.cfdg +30 -0
  289. data/lib/image_paradise/cfdg/matrix_freestyle.cfdg +127 -0
  290. data/lib/image_paradise/cfdg/maze.cfdg +211 -0
  291. data/lib/image_paradise/cfdg/meaculpo.cfdg +46 -0
  292. data/lib/image_paradise/cfdg/medieval_madness.cfdg +140 -0
  293. data/lib/image_paradise/cfdg/menage_a_trois.cfdg +77 -0
  294. data/lib/image_paradise/cfdg/micky_mouse.cfdg +75 -0
  295. data/lib/image_paradise/cfdg/mistletoe_forest.cfdg +62 -0
  296. data/lib/image_paradise/cfdg/mixed_simple_bubbles.cfdg +20 -0
  297. data/lib/image_paradise/cfdg/mod4g_starhole.cfdg +27 -0
  298. data/lib/image_paradise/cfdg/moebius.cfdg +57 -0
  299. data/lib/image_paradise/cfdg/molecules.cfdg +30 -0
  300. data/lib/image_paradise/cfdg/momos_blossom.cfdg +70 -0
  301. data/lib/image_paradise/cfdg/mona_lisa.cfdg +7937 -0
  302. data/lib/image_paradise/cfdg/more_arrows_in_quadcity.cfdg +49 -0
  303. data/lib/image_paradise/cfdg/more_cats.cfdg +1002 -0
  304. data/lib/image_paradise/cfdg/mosaic_for_2D_games.cfdg +69 -0
  305. data/lib/image_paradise/cfdg/mr_bezier.cfdg +195 -0
  306. data/lib/image_paradise/cfdg/mtree.cfdg +33 -0
  307. data/lib/image_paradise/cfdg/multiple_triangles.cfdg +13 -0
  308. data/lib/image_paradise/cfdg/mycel.cfdg +88 -0
  309. data/lib/image_paradise/cfdg/mytohexagone.cfdg +56 -0
  310. data/lib/image_paradise/cfdg/nature_is_not_like_that.cfdg +48 -0
  311. data/lib/image_paradise/cfdg/negative_flowers.cfdg +85 -0
  312. data/lib/image_paradise/cfdg/neo_town.cfdg +41 -0
  313. data/lib/image_paradise/cfdg/nesting_pattern.cfdg +34 -0
  314. data/lib/image_paradise/cfdg/neuronal_network.cfdg +94 -0
  315. data/lib/image_paradise/cfdg/neuronal_root.cfdg +46 -0
  316. data/lib/image_paradise/cfdg/night.cfdg +82 -0
  317. data/lib/image_paradise/cfdg/nightwalker.cfdg +23 -0
  318. data/lib/image_paradise/cfdg/no_xcape.cfdg +41 -0
  319. data/lib/image_paradise/cfdg/noise.cfdg +12 -0
  320. data/lib/image_paradise/cfdg/octopodi.cfdg +51 -0
  321. data/lib/image_paradise/cfdg/octopussy.cfdg +49 -0
  322. data/lib/image_paradise/cfdg/oldschool_cartoon_figure.cfdg +181 -0
  323. data/lib/image_paradise/cfdg/open_shapes.cfdg +240 -0
  324. data/lib/image_paradise/cfdg/orange_blossom.cfdg +57 -0
  325. data/lib/image_paradise/cfdg/orange_guts.cfdg +43 -0
  326. data/lib/image_paradise/cfdg/orange_monster.cfdg +42 -0
  327. data/lib/image_paradise/cfdg/organic.cfdg +30 -0
  328. data/lib/image_paradise/cfdg/ouo_happy_smiley.cfdg +45 -0
  329. data/lib/image_paradise/cfdg/output.png +0 -0
  330. data/lib/image_paradise/cfdg/pacman.cfdg +18 -0
  331. data/lib/image_paradise/cfdg/palmen.cfdg +162 -0
  332. data/lib/image_paradise/cfdg/pandoras_box.cfdg +53 -0
  333. data/lib/image_paradise/cfdg/papillon_butterfly.cfdg +28 -0
  334. data/lib/image_paradise/cfdg/patchwork.cfdg +32 -0
  335. data/lib/image_paradise/cfdg/pattern_grass.cfdg +110 -0
  336. data/lib/image_paradise/cfdg/peau_de_grenouille.cfdg +16 -0
  337. data/lib/image_paradise/cfdg/penrose_tiling.cfdg +102 -0
  338. data/lib/image_paradise/cfdg/pentagon.cfdg +68 -0
  339. data/lib/image_paradise/cfdg/pentagons.cfdg +25 -0
  340. data/lib/image_paradise/cfdg/perspective_tsunami.cfdg +20 -0
  341. data/lib/image_paradise/cfdg/phi_cloud.cfdg +23 -0
  342. data/lib/image_paradise/cfdg/picnic_birds_eye_view.cfdg +132 -0
  343. data/lib/image_paradise/cfdg/ping_pong.cfdg +29 -0
  344. data/lib/image_paradise/cfdg/pink_blossom.cfdg +58 -0
  345. data/lib/image_paradise/cfdg/piupole.cfdg +77 -0
  346. data/lib/image_paradise/cfdg/plotting.cfdg +61 -0
  347. data/lib/image_paradise/cfdg/point_onto_root.cfdg +64 -0
  348. data/lib/image_paradise/cfdg/primitive_reptile_pattern.cfdg +96 -0
  349. data/lib/image_paradise/cfdg/psycho_knot.cfdg +20 -0
  350. data/lib/image_paradise/cfdg/pyramide.cfdg +67 -0
  351. data/lib/image_paradise/cfdg/pythagoras_puzzle.cfdg +17 -0
  352. data/lib/image_paradise/cfdg/pythagorean_tree.cfdg +70 -0
  353. data/lib/image_paradise/cfdg/qimica.cfdg +64 -0
  354. data/lib/image_paradise/cfdg/quad_green_satellite.cfdg +53 -0
  355. data/lib/image_paradise/cfdg/quadcity.cfdg +24 -0
  356. data/lib/image_paradise/cfdg/quiet_wood_town.cfdg +195 -0
  357. data/lib/image_paradise/cfdg/r180.cfdg +26 -0
  358. data/lib/image_paradise/cfdg/r45.cfdg +26 -0
  359. data/lib/image_paradise/cfdg/r_square.cfdg +36 -0
  360. data/lib/image_paradise/cfdg/rads.cfdg +33 -0
  361. data/lib/image_paradise/cfdg/rainbow_black_hole.cfdg +9 -0
  362. data/lib/image_paradise/cfdg/rainbow_sun.cfdg +9 -0
  363. data/lib/image_paradise/cfdg/random_handwriting.cfdg +50 -0
  364. data/lib/image_paradise/cfdg/random_tile_shapes_jens_revisited.cfdg +146 -0
  365. data/lib/image_paradise/cfdg/rays_attack.cfdg +29 -0
  366. data/lib/image_paradise/cfdg/razpad.cfdg +20 -0
  367. data/lib/image_paradise/cfdg/rectangular_distortion.cfdg +169 -0
  368. data/lib/image_paradise/cfdg/recurse_path.cfdg +38 -0
  369. data/lib/image_paradise/cfdg/red_flurry.cfdg +64 -0
  370. data/lib/image_paradise/cfdg/red_horse_tail.cfdg +36 -0
  371. data/lib/image_paradise/cfdg/red_yellow_mosaic.cfdg +26 -0
  372. data/lib/image_paradise/cfdg/rendering_tests.cfdg +183 -0
  373. data/lib/image_paradise/cfdg/repeat_floor_tile_pattern.cfdg +153 -0
  374. data/lib/image_paradise/cfdg/repeat_tile.cfdg +160 -0
  375. data/lib/image_paradise/cfdg/retro_disc.cfdg +736 -0
  376. data/lib/image_paradise/cfdg/ring_growth_variation.cfdg +41 -0
  377. data/lib/image_paradise/cfdg/robot_nightlife.cfdg +25 -0
  378. data/lib/image_paradise/cfdg/rolled_firespiral.cfdg +34 -0
  379. data/lib/image_paradise/cfdg/rose.cfdg +44 -0
  380. data/lib/image_paradise/cfdg/round_tree.cfdg +121 -0
  381. data/lib/image_paradise/cfdg/rubiks_cube.cfdg +120 -0
  382. data/lib/image_paradise/cfdg/ruins.cfdg +19 -0
  383. data/lib/image_paradise/cfdg/sails_and_the_sea.cfdg +27 -0
  384. data/lib/image_paradise/cfdg/salt_crystals.cfdg +26 -0
  385. data/lib/image_paradise/cfdg/saturn.cfdg +105 -0
  386. data/lib/image_paradise/cfdg/scary_pot.cfdg +49 -0
  387. data/lib/image_paradise/cfdg/schematic_worm.cfdg +35 -0
  388. data/lib/image_paradise/cfdg/school_script.cfdg +359 -0
  389. data/lib/image_paradise/cfdg/seahorse.cfdg +78 -0
  390. data/lib/image_paradise/cfdg/seasons.cfdg +115 -0
  391. data/lib/image_paradise/cfdg/segmental_veins.cfdg +66 -0
  392. data/lib/image_paradise/cfdg/select_mayhem.cfdg +28 -0
  393. data/lib/image_paradise/cfdg/seven_folded_symmetry.cfdg +7 -0
  394. data/lib/image_paradise/cfdg/several_cats.cfdg +996 -0
  395. data/lib/image_paradise/cfdg/shadow_box.cfdg +49 -0
  396. data/lib/image_paradise/cfdg/shadowrun_google_maps.cfdg +66 -0
  397. data/lib/image_paradise/cfdg/shadowrun_nightline.cfdg +18 -0
  398. data/lib/image_paradise/cfdg/shards.cfdg +70 -0
  399. data/lib/image_paradise/cfdg/sheet_music.cfdg +213 -0
  400. data/lib/image_paradise/cfdg/shy_guy.cfdg +886 -0
  401. data/lib/image_paradise/cfdg/sierpinski1.cfdg +41 -0
  402. data/lib/image_paradise/cfdg/sierpinski2.cfdg +34 -0
  403. data/lib/image_paradise/cfdg/sierpinski_like_red_swirl.cfdg +46 -0
  404. data/lib/image_paradise/cfdg/sierpinsktri.cfdg +9 -0
  405. data/lib/image_paradise/cfdg/silk_flowers.cfdg +68 -0
  406. data/lib/image_paradise/cfdg/silk_scarf.cfdg +18 -0
  407. data/lib/image_paradise/cfdg/simple_cilia.cfdg +88 -0
  408. data/lib/image_paradise/cfdg/simple_circle_and_square.cfdg +7 -0
  409. data/lib/image_paradise/cfdg/simple_coloured_square.cfdg +38 -0
  410. data/lib/image_paradise/cfdg/simple_ferns.cfdg +40 -0
  411. data/lib/image_paradise/cfdg/simple_fish.cfdg +77 -0
  412. data/lib/image_paradise/cfdg/simple_orchid.cfdg +23 -0
  413. data/lib/image_paradise/cfdg/simple_rounded_colour_wheel.cfdg +10 -0
  414. data/lib/image_paradise/cfdg/simple_sheet_music.cfdg +27 -0
  415. data/lib/image_paradise/cfdg/sincos_pattern_2.cfdg +42 -0
  416. data/lib/image_paradise/cfdg/singing_birdy.cfdg +112 -0
  417. data/lib/image_paradise/cfdg/skyscraper.cfdg +85 -0
  418. data/lib/image_paradise/cfdg/small_golden_rectangle.cfdg +12 -0
  419. data/lib/image_paradise/cfdg/smells_like_layered.cfdg +43 -0
  420. data/lib/image_paradise/cfdg/snowflake.cfdg +26 -0
  421. data/lib/image_paradise/cfdg/snowstorm.cfdg +26 -0
  422. data/lib/image_paradise/cfdg/soar_on_wings.cfdg +8 -0
  423. data/lib/image_paradise/cfdg/soft_core.cfdg +26 -0
  424. data/lib/image_paradise/cfdg/soft_touch.cfdg +20 -0
  425. data/lib/image_paradise/cfdg/some_sort_of_tree.cfdg +57 -0
  426. data/lib/image_paradise/cfdg/spade_ball.cfdg +39 -0
  427. data/lib/image_paradise/cfdg/sparks.cfdg +39 -0
  428. data/lib/image_paradise/cfdg/sperm.cfdg +63 -0
  429. data/lib/image_paradise/cfdg/sphinx.cfdg +17 -0
  430. data/lib/image_paradise/cfdg/spiral_clusters.cfdg +29 -0
  431. data/lib/image_paradise/cfdg/spiral_cross.cfdg +27 -0
  432. data/lib/image_paradise/cfdg/spiral_star.cfdg +19 -0
  433. data/lib/image_paradise/cfdg/spiral_sun.cfdg +39 -0
  434. data/lib/image_paradise/cfdg/spirit.cfdg +47 -0
  435. data/lib/image_paradise/cfdg/splatter_tree.cfdg +61 -0
  436. data/lib/image_paradise/cfdg/spliced.cfdg +27 -0
  437. data/lib/image_paradise/cfdg/spring_parade.cfdg +105 -0
  438. data/lib/image_paradise/cfdg/sprinkle_explosion.cfdg +23 -0
  439. data/lib/image_paradise/cfdg/square_limit_one.cfdg +15 -0
  440. data/lib/image_paradise/cfdg/square_rose.cfdg +75 -0
  441. data/lib/image_paradise/cfdg/square_spiral4.cfdg +41 -0
  442. data/lib/image_paradise/cfdg/square_star.cfdg +39 -0
  443. data/lib/image_paradise/cfdg/squiggle.cfdg +54 -0
  444. data/lib/image_paradise/cfdg/stacked_blob.cfdg +27 -0
  445. data/lib/image_paradise/cfdg/star_explosion.cfdg +38 -0
  446. data/lib/image_paradise/cfdg/star_flower.cfdg +72 -0
  447. data/lib/image_paradise/cfdg/star_mosaic_2007.cfdg +51 -0
  448. data/lib/image_paradise/cfdg/starry_pines.cfdg +79 -0
  449. data/lib/image_paradise/cfdg/stars_tentacles.cfdg +28 -0
  450. data/lib/image_paradise/cfdg/starshape.cfdg +57 -0
  451. data/lib/image_paradise/cfdg/strange_antlers.cfdg +49 -0
  452. data/lib/image_paradise/cfdg/strange_carpet.cfdg +13 -0
  453. data/lib/image_paradise/cfdg/sunset_city.cfdg +112 -0
  454. data/lib/image_paradise/cfdg/sweep.cfdg +946 -0
  455. data/lib/image_paradise/cfdg/swimmers_sperms.cfdg +54 -0
  456. data/lib/image_paradise/cfdg/sword.cfdg +24 -0
  457. data/lib/image_paradise/cfdg/tangle.cfdg +25 -0
  458. data/lib/image_paradise/cfdg/tapestry.cfdg +40 -0
  459. data/lib/image_paradise/cfdg/tasty_loops.cfdg +97 -0
  460. data/lib/image_paradise/cfdg/tendril.cfdg +6 -0
  461. data/lib/image_paradise/cfdg/tentacle_tree.cfdg +57 -0
  462. data/lib/image_paradise/cfdg/terraforming.cfdg +87 -0
  463. data/lib/image_paradise/cfdg/test.cfdg +7 -0
  464. data/lib/image_paradise/cfdg/tetris.cfdg +123 -0
  465. data/lib/image_paradise/cfdg/textured_giraffes.cfdg +122 -0
  466. data/lib/image_paradise/cfdg/the_eye.cfdg +16 -0
  467. data/lib/image_paradise/cfdg/the_go_game.cfdg +81 -0
  468. data/lib/image_paradise/cfdg/the_secret.cfdg +52 -0
  469. data/lib/image_paradise/cfdg/the_third_eye.cfdg +42 -0
  470. data/lib/image_paradise/cfdg/thingy.cfdg +13 -0
  471. data/lib/image_paradise/cfdg/thorns.cfdg +26 -0
  472. data/lib/image_paradise/cfdg/too_many_notes.cfdg +155 -0
  473. data/lib/image_paradise/cfdg/top_down_plant_root.cfdg +43 -0
  474. data/lib/image_paradise/cfdg/top_view_tree.cfdg +79 -0
  475. data/lib/image_paradise/cfdg/transparent_heart.cfdg +31 -0
  476. data/lib/image_paradise/cfdg/tree.cfdg +68 -0
  477. data/lib/image_paradise/cfdg/tree_number_5.cfdg +28 -0
  478. data/lib/image_paradise/cfdg/tree_retro.cfdg +46 -0
  479. data/lib/image_paradise/cfdg/tree_spiral.cfdg +52 -0
  480. data/lib/image_paradise/cfdg/treematic.cfdg +42 -0
  481. data/lib/image_paradise/cfdg/tri_arc.cfdg +16 -0
  482. data/lib/image_paradise/cfdg/tri_squares.cfdg +7 -0
  483. data/lib/image_paradise/cfdg/tube_map.cfdg +112 -0
  484. data/lib/image_paradise/cfdg/turing_morphogenesis.cfdg +788 -0
  485. data/lib/image_paradise/cfdg/twisted_hex_grid.cfdg +26 -0
  486. data/lib/image_paradise/cfdg/twisty_triangel.cfdg +79 -0
  487. data/lib/image_paradise/cfdg/twizeeded.cfdg +19 -0
  488. data/lib/image_paradise/cfdg/uncontrolled_fungus.cfdg +36 -0
  489. data/lib/image_paradise/cfdg/underground.cfdg +72 -0
  490. data/lib/image_paradise/cfdg/underwater.cfdg +75 -0
  491. data/lib/image_paradise/cfdg/unicorn_boi.cfdg +20 -0
  492. data/lib/image_paradise/cfdg/unification_sign.cfdg +52 -0
  493. data/lib/image_paradise/cfdg/urban_connections.cfdg +44 -0
  494. data/lib/image_paradise/cfdg/us_flag.cfdg +109 -0
  495. data/lib/image_paradise/cfdg/v_null.cfdg +89 -0
  496. data/lib/image_paradise/cfdg/very_simple_flower.cfdg +45 -0
  497. data/lib/image_paradise/cfdg/very_simple_hexagon.cfdg +16 -0
  498. data/lib/image_paradise/cfdg/very_simple_octagon.cfg +13 -0
  499. data/lib/image_paradise/cfdg/vigorous_vine.cfdg +45 -0
  500. data/lib/image_paradise/cfdg/ville_topview.cfdg +70 -0
  501. data/lib/image_paradise/cfdg/vine.cfdg +176 -0
  502. data/lib/image_paradise/cfdg/vinyl.cfdg +12 -0
  503. data/lib/image_paradise/cfdg/violet_ribbons.cfdg +45 -0
  504. data/lib/image_paradise/cfdg/voronoi_2.cfdg +61 -0
  505. data/lib/image_paradise/cfdg/wald.cfdg +46 -0
  506. data/lib/image_paradise/cfdg/water_ink.cfdg +71 -0
  507. data/lib/image_paradise/cfdg/water_monster.cfdg +33 -0
  508. data/lib/image_paradise/cfdg/web.cfdg +53 -0
  509. data/lib/image_paradise/cfdg/weighting_demo.cfdg +16 -0
  510. data/lib/image_paradise/cfdg/weird_spots.cfdg +15 -0
  511. data/lib/image_paradise/cfdg/welcome.cfdg +109 -0
  512. data/lib/image_paradise/cfdg/where_do_you_want_to_go_today.cfdg +632 -0
  513. data/lib/image_paradise/cfdg/where_is_the_head.cfdg +28 -0
  514. data/lib/image_paradise/cfdg/where_to_go.cfdg +62 -0
  515. data/lib/image_paradise/cfdg/willow.cfdg +39 -0
  516. data/lib/image_paradise/cfdg/witch_poison.cfdg +58 -0
  517. data/lib/image_paradise/cfdg/wooden_floor.cfdg +95 -0
  518. data/lib/image_paradise/cfdg/writhing.cfdg +15 -0
  519. data/lib/image_paradise/cfdg/wrooom_cars.cfdg +124 -0
  520. data/lib/image_paradise/cfdg/xmas_code.cfdg +101 -0
  521. data/lib/image_paradise/cfdg/xmas_tree.cfdg +70 -0
  522. data/lib/image_paradise/cfdg/yellow_cactus.cfdg +52 -0
  523. data/lib/image_paradise/cfdg/yet_another_explosion.cfdg +46 -0
  524. data/lib/image_paradise/cfdg/yin_yang_taijitu_pattern.cfdg +44 -0
  525. data/lib/image_paradise/cfdg/yog.cfdg +27 -0
  526. data/lib/image_paradise/cfdg/yurbanis_m.cfdg +27 -0
  527. data/lib/image_paradise/cfdg/zen_tree.cfdg +79 -0
  528. data/lib/image_paradise/cfdg/ziggy_flowers.cfdg +44 -0
  529. data/lib/image_paradise/cfdg/zodiac.cfdg +43 -0
  530. data/lib/image_paradise/chunky_png/chunky_png.rb +54 -0
  531. data/lib/image_paradise/colours/colours.rb +46 -0
  532. data/lib/image_paradise/confree_generator/confree_generator.rb +791 -0
  533. data/lib/image_paradise/confree_generator/constants.rb +93 -0
  534. data/lib/image_paradise/constants/constants.rb +50 -0
  535. data/lib/image_paradise/constants/image_file_types.rb +26 -0
  536. data/lib/image_paradise/crop/crop.rb +429 -0
  537. data/lib/image_paradise/gm_support.rb +34 -0
  538. data/lib/image_paradise/graphs/accumulator_bar.rb +29 -0
  539. data/lib/image_paradise/graphs/area.rb +64 -0
  540. data/lib/image_paradise/graphs/bar.rb +117 -0
  541. data/lib/image_paradise/graphs/bar_conversion.rb +53 -0
  542. data/lib/image_paradise/graphs/base.rb +1392 -0
  543. data/lib/image_paradise/graphs/bezier.rb +45 -0
  544. data/lib/image_paradise/graphs/bullet.rb +115 -0
  545. data/lib/image_paradise/graphs/deprecated.rb +42 -0
  546. data/lib/image_paradise/graphs/dot.rb +129 -0
  547. data/lib/image_paradise/graphs/line.rb +328 -0
  548. data/lib/image_paradise/graphs/mini/bar.rb +42 -0
  549. data/lib/image_paradise/graphs/mini/legend.rb +109 -0
  550. data/lib/image_paradise/graphs/mini/pie.rb +42 -0
  551. data/lib/image_paradise/graphs/mini/side_bar.rb +41 -0
  552. data/lib/image_paradise/graphs/net.rb +133 -0
  553. data/lib/image_paradise/graphs/photo_bar.rb +106 -0
  554. data/lib/image_paradise/graphs/pie.rb +139 -0
  555. data/lib/image_paradise/graphs/scatter.rb +264 -0
  556. data/lib/image_paradise/graphs/scene.rb +216 -0
  557. data/lib/image_paradise/graphs/side_bar.rb +144 -0
  558. data/lib/image_paradise/graphs/side_stacked_bar.rb +116 -0
  559. data/lib/image_paradise/graphs/spider.rb +163 -0
  560. data/lib/image_paradise/graphs/stacked_area.rb +73 -0
  561. data/lib/image_paradise/graphs/stacked_bar.rb +68 -0
  562. data/lib/image_paradise/graphs/stacked_mixin.rb +30 -0
  563. data/lib/image_paradise/graphs/themes.rb +117 -0
  564. data/lib/image_paradise/graphs.rb +36 -0
  565. data/lib/image_paradise/graphviz/README.md +2 -0
  566. data/lib/image_paradise/graphviz/generate_graphviz_image.rb +276 -0
  567. data/lib/image_paradise/gui/gtk3/cfdg_widget/cfdg_widget.rb +1452 -0
  568. data/lib/image_paradise/gui/gtk3/cfdg_widget/connect_skeleton.rb +46 -0
  569. data/lib/image_paradise/gui/gtk3/image_editor/connect_skeleton.rb +126 -0
  570. data/lib/image_paradise/gui/gtk3/image_editor/image_editor.rb +2003 -0
  571. data/lib/image_paradise/identify.rb +184 -0
  572. data/lib/image_paradise/image_paradise.rb +153 -0
  573. data/lib/image_paradise/image_to_ascii/image_to_ascii.rb +187 -0
  574. data/lib/image_paradise/image_to_pdf/image_to_pdf.rb +99 -0
  575. data/lib/image_paradise/label/README.md +2 -0
  576. data/lib/image_paradise/label/simple_label.rb +206 -0
  577. data/lib/image_paradise/logo/IMGUR_LOGO.png +0 -0
  578. data/lib/image_paradise/project/project.rb +30 -0
  579. data/lib/image_paradise/requires/common_base_requires.rb +17 -0
  580. data/lib/image_paradise/requires/require_colours.rb +9 -0
  581. data/lib/image_paradise/requires/require_gtk_components.rb +8 -0
  582. data/lib/image_paradise/requires/require_image_to_ascii.rb +7 -0
  583. data/lib/image_paradise/requires/require_the_image_paradise_project.rb +42 -0
  584. data/lib/image_paradise/requires/require_toplevel_methods.rb +21 -0
  585. data/lib/image_paradise/rotate/README.md +2 -0
  586. data/lib/image_paradise/rotate/rotate.rb +124 -0
  587. data/lib/image_paradise/shell/interactive.rb +156 -0
  588. data/lib/image_paradise/svg/README.md +5 -0
  589. data/lib/image_paradise/svg/circle.rb +106 -0
  590. data/lib/image_paradise/svg/feature.rb +48 -0
  591. data/lib/image_paradise/svg/rectangle.rb +154 -0
  592. data/lib/image_paradise/svg/svg.rb +102 -0
  593. data/lib/image_paradise/toplevel_methods/add_black_border_to_this_image.rb +94 -0
  594. data/lib/image_paradise/toplevel_methods/create_animated_gif.rb +49 -0
  595. data/lib/image_paradise/toplevel_methods/crop.rb +29 -0
  596. data/lib/image_paradise/toplevel_methods/e.rb +16 -0
  597. data/lib/image_paradise/toplevel_methods/esystem.rb +19 -0
  598. data/lib/image_paradise/toplevel_methods/extract_text_from_this_image.rb +56 -0
  599. data/lib/image_paradise/toplevel_methods/file_related_code.rb +48 -0
  600. data/lib/image_paradise/toplevel_methods/flip_image_left_right.rb +59 -0
  601. data/lib/image_paradise/toplevel_methods/font_related_methods.rb +62 -0
  602. data/lib/image_paradise/toplevel_methods/greyscale_this_image.rb +76 -0
  603. data/lib/image_paradise/toplevel_methods/gui.rb +19 -0
  604. data/lib/image_paradise/toplevel_methods/help.rb +30 -0
  605. data/lib/image_paradise/toplevel_methods/interlace.rb +33 -0
  606. data/lib/image_paradise/toplevel_methods/is_an_image_file.rb +18 -0
  607. data/lib/image_paradise/toplevel_methods/make_this_image_transparent.rb +40 -0
  608. data/lib/image_paradise/toplevel_methods/menu.rb +110 -0
  609. data/lib/image_paradise/toplevel_methods/merge_these_images.rb +49 -0
  610. data/lib/image_paradise/toplevel_methods/mirror_image.rb +28 -0
  611. data/lib/image_paradise/toplevel_methods/misc.rb +1407 -0
  612. data/lib/image_paradise/toplevel_methods/negate.rb +36 -0
  613. data/lib/image_paradise/toplevel_methods/png_to_svg.rb +38 -0
  614. data/lib/image_paradise/toplevel_methods/quality.rb +34 -0
  615. data/lib/image_paradise/toplevel_methods/resized.rb +43 -0
  616. data/lib/image_paradise/toplevel_methods/roebe.rb +323 -0
  617. data/lib/image_paradise/toplevel_methods/thumbnail.rb +54 -0
  618. data/lib/image_paradise/toplevel_methods/to_png.rb +106 -0
  619. data/lib/image_paradise/toplevel_methods/wallpaper.rb +51 -0
  620. data/lib/image_paradise/toplevel_methods/write_this_text.rb +89 -0
  621. data/lib/image_paradise/utility_scripts/black_white.rb +92 -0
  622. data/lib/image_paradise/utility_scripts/create_new_image.rb +110 -0
  623. data/lib/image_paradise/utility_scripts/image_border.rb +226 -0
  624. data/lib/image_paradise/utility_scripts/image_gallery/image_gallery.rb +283 -0
  625. data/lib/image_paradise/utility_scripts/image_manipulations.rb +316 -0
  626. data/lib/image_paradise/utility_scripts/magic_card_border.rb +215 -0
  627. data/lib/image_paradise/utility_scripts/optimizer.rb +452 -0
  628. data/lib/image_paradise/utility_scripts/random_text_to_image.rb +364 -0
  629. data/lib/image_paradise/utility_scripts/text_on_image.rb +311 -0
  630. data/lib/image_paradise/utility_scripts/to_gif.rb +93 -0
  631. data/lib/image_paradise/utility_scripts/to_jpg.rb +82 -0
  632. data/lib/image_paradise/version/version.rb +19 -0
  633. data/lib/image_paradise/www/cfdg.cgi +25 -0
  634. data/lib/image_paradise/www/imagemagick/imagemagick.cgi +266 -0
  635. data/lib/image_paradise/yaml/README.md +2 -0
  636. data/lib/image_paradise/yaml/arc.yml +0 -0
  637. data/lib/image_paradise/yaml/circle.yml +6 -0
  638. data/lib/image_paradise/yaml/rectangle.yml +6 -0
  639. data/lib/image_paradise.rb +5 -0
  640. data/test/16x16_red_square_image_for_testing.png +0 -0
  641. data/test/misc/README.md +3 -0
  642. data/test/misc/testing_filling_up_with_circles.rb +65 -0
  643. data/test/testing_confree_generator.rb +8 -0
  644. data/test/testing_crop.rb +19 -0
  645. data/test/testing_image_magick_commands.rb +39 -0
  646. data/test/testing_image_paradise.rb +49 -0
  647. data/test/testing_the_svg_component.html +261 -0
  648. data/test/testing_the_svg_component.rb +106 -0
  649. metadata +760 -0
data/doc/README.gen ADDED
@@ -0,0 +1,871 @@
1
+ DEFAULT_HEADER
2
+
3
+ <img src="https://i.imgur.com/FqAgAbm.png" style="margin: 0.8em; margin-left: 3em">
4
+
5
+ (This image was partially autogenerated via cfdg. You can re-use
6
+ this image and modify it if you wish to without restrictions.
7
+ For the actual .cfdg code, please have a look at the gallery
8
+ there: https://www.contextfreeart.org/gallery/)
9
+
10
+ ## How to install this project
11
+
12
+ The obvious way is to do this:
13
+
14
+ gem install image_paradise
15
+
16
+ However had, installing into the user directory may be
17
+ more useful, depending on your use case:
18
+
19
+ gem install image_paradise --user-install
20
+
21
+ The latter may be a bit better, as it should be easier to get
22
+ this installed into the home directory.
23
+
24
+ Then you can symlink bin/image_paradise to $PATH or any other
25
+ name as-is. Or just start irb, require 'image_paradise', and
26
+ call whatever class you need there. You could even do so
27
+ for the ruby-gtk3 bindings, if you have these installed,
28
+ and the gtk_paradise gem.
29
+
30
+ Example for this:
31
+
32
+ require 'image_paradise'
33
+ ImageParadise.confree_GUI # Start the gtk-confree GUI.
34
+
35
+ For an explanation of the --user-install option see the
36
+ article here:
37
+
38
+ https://guides.rubygems.org/faqs/#i-installed-gems-with---user-install-and-their-commands-are-not-available
39
+
40
+ ## Flip-flopping an image from left-to-right
41
+
42
+ If you want to flip an image left-to-right, you can use
43
+ the method <b>.flip_image_left_right</b>. The file resides
44
+ at <b>image_paradise/toplevel_methods/flip_image_left_right.rb</b>.
45
+
46
+ Example:
47
+
48
+ require 'image_paradise/toplevel_methods/flip_image_left_right.rb'
49
+ ImageParadise.flip_image_left_right() # Pass the file path to this method.
50
+
51
+ ## Transparent images
52
+
53
+ You can use this API to make an image **transparent**:
54
+
55
+ require 'image_paradise/toplevel_methods/make_this_image_transparent.rb'
56
+ ImageParadise.make_this_image_transparent
57
+ ImageParadise.make_this_image_transparent('foobar.jpg')
58
+
59
+ This will try to make use of ImageMagick's **convert** ability.
60
+
61
+ ## Negating an image
62
+
63
+ You can negate an image, aka the "flipped" colour state, via:
64
+
65
+ require 'image_paradise/toplevel_methods/negate.rb'
66
+ ImageParadise.negate()
67
+ ImageParadise.negate('filename_here.jpg')
68
+
69
+ If you negate such an image again, you will have the original
70
+ image back.
71
+
72
+ ## Merging image files together
73
+
74
+ You can use the toplevel method **ImageParadise.merge_these_images**
75
+ in order to merge several image files together. This depends on the
76
+ binary called **convert**, from ImageMagick. Note that this will
77
+ merge from the left-to-the-right side, and use white background
78
+ by default if an image has to be padded. The biggest image will
79
+ determine the amount that has to be padded here.
80
+
81
+ As first argument simply pass an Array of the files that you wish
82
+ to merge, such as:
83
+
84
+ ImageParadise.merge_these_images(%w( foo.png bar.png bla.png ))
85
+ ImageParadise.merge(%w( foo.png bar.png bla.png )) # <- This also works.
86
+
87
+ ## Greyscaling images
88
+
89
+ You can grayscale images via:
90
+
91
+ ImageParadise.greyscale_this_image()
92
+ ImageParadise.grayscale_this_image()
93
+
94
+ This currently (Jan 2019) depends on the gem called **mini_magick**. In
95
+ the future we may add some more flexibility to this method, but for the
96
+ time being mini_magick is a dependency if you wish to make use of
97
+ these **toplevel methods**.
98
+
99
+ Greyscaling an image may be useful if you wish to use this for
100
+ **optical character recognition**, aka recognising written text
101
+ on it.
102
+
103
+ ## class ImageParadiseImageToAscii
104
+
105
+ This class can convert images to ASCII files, if ImageMagick
106
+ (and the rmagick bindings) are available.
107
+
108
+ To specifically require this class, do this:
109
+
110
+ require 'image_paradise/requires/require_image_to_ascii.rb'
111
+
112
+ Then pass the filename into the class:
113
+
114
+ result = ImageParadise::ImageToAscii['foobar.jpg']
115
+ result = ImageParadise.image_to_ascii('foobar.jpg')
116
+
117
+ or
118
+
119
+ _ = ImageParadise::ImageToAscii.new '/foo/bar.png'
120
+ _.to_ascii # Generate the ascii "image" here specifically, via this method call.
121
+
122
+ or
123
+
124
+ print ImageParadise::ImageToAscii('yo.png').to_ascii(width: 50)
125
+
126
+ +--------------------------------------------------+
127
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
128
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
129
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
130
+ |oooooooooooooooooo===++++====ooooooooooooooooooooo|
131
+ |ooooooooooooo=+:~.~........~~~:+=ooooooooooooooooo|
132
+ |oooooooooo==:~...~~:++++++:~~..~~:+=oooooooooooooo|
133
+ |oooooooo=+:...~++====oooo====+:~..~:+=oooooooooooo|
134
+ |ooooooo=+~..~:++==ooooooooooo=++:~..~+=ooooooooooo|
135
+ |oooooo=+~.~:+=+~.~~~~~~~~:~~~.~:++:~.~+=oooooooooo|
136
+ |ooooo=+~~.+===~................~+==:.~~+=ooooooooo|
137
+ |ooooo=:~~:+=+:~................~~+=+:~.:=ooooooooo|
138
+ |ooooo=~.~+==+~.......XXXXX.......+==+~.:=ooooooooo|
139
+ |ooooo=~~~+==:~.......XXXXX.......:==+~.:=ooooooooo|
140
+ |ooooo=~~~:==+~.......XXXXX......~+==+~.~=ooooooooo|
141
+ |ooooo=:~~~+=++~.................:+=+~~~:=ooooooooo|
142
+ |ooooo=+:..~+==+~~...........~~~+==+~..:+=ooooooooo|
143
+ |ooooooo+:..~:+=o=+:........:+====:~.~:==oooooooooo|
144
+ |oooooooo=+~.~~:+==+~......~+==+:~..~:+oooooooooooo|
145
+ |ooooooooo=+:~..~~:~~.......~:~~..~:+oooooooooooooo|
146
+ |oooooooooooo=+~~..............~:+=oooooooooooooooo|
147
+ |ooooooooooooooo==++:~~~~~~:++==ooooooooooooooooooo|
148
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
149
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
150
+ |oooooooooooooooooooooooooooooooooooooooooooooooooo|
151
+ +--------------------------------------------------+
152
+
153
+ Add colours via the "colour" option
154
+
155
+ require 'image_paradise'
156
+ a = ImageParadise::ImageToAscii.new "http://www.evangogh.org/images/paintings/self-portrait.jpg"
157
+ puts a.to_ascii(color: true)
158
+
159
+ Command Line examples:
160
+
161
+ image_to_ascii ~/Desktop/foo.png # Local file.
162
+ image_to_ascii http://www.google.com/images/foo.png # Remote image.
163
+ image_to_ascii -c -f html ~/foobar.jpg > ~/Desktop/ascii-as-html.html # Output via HTML.
164
+ image_to_ascii -w 50 -c -f html ~/foo/bar.jpg > ~/Desktop/saturdaynight.html # Or smaller.
165
+
166
+ To display help:
167
+
168
+ image_to_ascii -h
169
+
170
+ Usage: image_to_ascii [options] <path_or_url>
171
+ -w, --width WIDTH Width of the finished Ascii Image (Default: 150)
172
+ -f, --format [text/html] output format (Default: text)
173
+ -c, --color Switch to use colored terminal output (Default: false)
174
+ -i, --invert-chars Invert the character map. *Depending on background and image color - this can make the result clearer.*
175
+ -v, --version Show the version of this project
176
+ -h, --help Show this message
177
+
178
+ ## SVG
179
+
180
+ ImageParadise now has a submodule called **Svg**, for svg-related
181
+ objects. Documentation is currently missing for this part. Hopefully
182
+ I will have more time in the future to add the missing
183
+ documentation here. :\
184
+
185
+ ## ImageMagick versus GraphicsMagick
186
+
187
+ GraphicsMagick is a fork of ImageMagick, started in the year 2002.
188
+
189
+ I do not know the real differences between these two projects. For now,
190
+ the **image_paradise** gem will focus on ImageMagick first. Perhaps at
191
+ a later time I may add support for GraphicsMagick, but I want to
192
+ finish the GUI components first, before looking for more flexibility
193
+ after that.
194
+
195
+ ## Create background images and wallpapers
196
+
197
+ To create a white wallpaper, use this API:
198
+
199
+ ImageParadise.white_wallpaper
200
+ ImageParadise.white_wallpaper(width = :default, height = :default)
201
+ ImageParadise.white_wallpaper(1200, 800)
202
+
203
+ This makes use of a more general API called:
204
+
205
+ ImageParadise.wallpaper()
206
+
207
+ The first argument is the colour for that background image. The default
208
+ colour here will be black, hence a black background image.
209
+
210
+ ## cfdg
211
+
212
+ The **image_paradise** gem includes code that allows the user to
213
+ batch-generate images from **.cfdg** files, making use of the
214
+ cfdg binary (**context free design**).
215
+
216
+ You can download **cfdg** from:
217
+
218
+ https://www.contextfreeart.org/downloads.html
219
+
220
+ I typically compile the variant from source directly.
221
+
222
+ My long-term goal in this regard, as far as the **image_paradise**
223
+ gem is concerned, is to **use a commandline variant**, as well as
224
+ a GUI wrapper for this. The GUI will be written in **ruby-gtk3**.
225
+ Perhaps www-bindings via sinatra may also be offered one day, via
226
+ the ImageParadise project - let's see.
227
+
228
+ Additionally, the image_paradise .gem will include many .cfdg
229
+ example files, written by many different people (mostly; I wrote
230
+ a few .cfdg files as well but not many). The filename of all these
231
+ .cfdg files **must** be downcased - I mention this because some
232
+ of the upstream .cfdg files have upcased characters, which annoys
233
+ me. Keep it simple, folks!
234
+
235
+ Some of these files are **+16 years old** and have to be updated
236
+ really, but you know how it is when time is a limited resource. So
237
+ the rules that govern some of these .cfdg files is ... a bit
238
+ outdated.
239
+
240
+ I'll also have to add URLs to some of these ancient .cfdg files,
241
+ author-information and so forth; this is low priority for now,
242
+ though. It's mostly clean up work, which isn't as much fun
243
+ to do. :-)
244
+
245
+ To start the **ruby-gtk3** bindings, depending on the gtk_paradise
246
+ gem, you can try this from the commandline:
247
+
248
+ confree_generator --gui
249
+
250
+ The following image shows how this may look in **December 2021** -
251
+ in the long run I intend to improve this GUI, but for now the
252
+ most important part is to finish the desired functionality. I'd
253
+ love to have a full editor for CFDG one day:
254
+
255
+ <img src="https://i.imgur.com/yNyt0He.png" style="margin: 1em; margin-left: 3em">
256
+
257
+ Todo list for the ruby-gtk3 wrapper:
258
+
259
+ - On middle-mouse scroll-wheel scroll-event, change the number of
260
+ the gtk-entry there, e. g. upwards scrolling means
261
+ larger width, down-scroll means smaller width respectively.
262
+
263
+ Existing features and functionality for the ruby-gtk3 wrapper
264
+ over the cfdg binary:
265
+
266
+ - Show all existing local .cfdg files via a button that can
267
+ be clicked. Upon clicking that button, the file is loaded,
268
+ and then a new image is created from this via cfdg. This
269
+ has been implemented in **March 2021**.
270
+
271
+ - Upload to imgur via an image-event-button (the old
272
+ upload-to-imageshack is no longer available, but perhaps it
273
+ may be re-added in the future)
274
+
275
+ In <b>September 2022</b> the widget was rewritten and looks a bit
276
+ better now:
277
+
278
+ <img src="https://i.imgur.com/9Qv4w5H.png" style="margin: 1em; margin-left: 3em">
279
+
280
+ As for .cfdg files distributed as part of the image_paradise gem,
281
+ I try to adhere to this specification in the long run:
282
+
283
+ - The file name should be noted near the very top of the file.
284
+ - All .cfdg file names must be lowercased at all times, so no
285
+ files called <b>foo_BAR.cfdg</b>.
286
+ - If they were obtained from the www, a hyperlink should
287
+ exist within the file, pointing to that original .cfdg
288
+ file. In this case the author should be mentioned as well,
289
+ and the creation date and addition date added too.
290
+
291
+ ## ImageParadise::Identify
292
+
293
+ If you need meta-data about an image then class ImageParadise::Identify
294
+ may be of help. Internally it is just a wrapper over ImageMagick's
295
+ identify functionality, but the key idea is to provide an OOP query
296
+ to these features (when they seem relevant), and use that abstraction
297
+ for other classes to make use of.
298
+
299
+ This class has to remain flexible, because I intend to keep it as
300
+ a base-class for whenever I need information about an image
301
+ programmatically.
302
+
303
+ ## cfdg cheat sheet
304
+
305
+ I am forgetting specifications used in cfdg, and I can not always
306
+ find them when I want to look them up. So I decided to also add
307
+ a few hints here; mostly for my own use case, but perhaps it may
308
+ also help other folks learn cfdg more quickly.
309
+
310
+ # Transparent background:
311
+ background { a -1 }
312
+
313
+ # Rotate a shape:
314
+ r 5 # rotate by +5 %
315
+
316
+ ## Adding a comment to an image file, via metadata
317
+
318
+ **ImageMagick** allows you to add a comment to an image file.
319
+
320
+ The ImageParadise gem added support for this as well,
321
+ just as a wrapper over Imagemagick.
322
+
323
+ API use:
324
+
325
+ ImageParadise.add_this_comment_to_that_image()
326
+ ImageParadise.add_this_comment_to_that_image('This is the comment')
327
+ ImageParadise.add_this_comment_to_that_image('This is the comment','existing_file.png')
328
+
329
+ ## ImageMagick tricks
330
+
331
+ This subsection just is a little random trick-collection.
332
+
333
+ To decrypt a .pdf document and extract the images, use
334
+ the authenticate command-line option:
335
+
336
+ convert -authenticate password input.pdf output%d.png
337
+
338
+ ## Morphing two images together
339
+
340
+ You can morph two images together via ImageMagick.
341
+
342
+ ImageParadise makes this available via this API:
343
+
344
+ ImageParadise.morph_these_images
345
+ ImageParadise.morph_these_images('foo.png','bar.png')
346
+ ImageParadise.morph_these_images('foo.png','bar.png','output_file.png)
347
+
348
+ Pass in the two images; the third argument may be the filename that
349
+ you wish to use for the output-file.
350
+
351
+ ## Graphical User Interface for the ImageParadise project (GUI)
352
+
353
+ Since as of February 2021 I am slowly working on a set of ruby-gtk3
354
+ code that integrates the functionality detailed above. Note that I
355
+ will only add support in the GUI **if** I also have documented - or
356
+ will document - the commandline behaviour shown above. The reason
357
+ as to why is that I want to sync commandline and GUI, but the
358
+ commandline is the main driver, whereas the GUI is merely a reflection
359
+ of the commandline tools of this project.
360
+
361
+ This should help keep things up-to-date, as more changes come at a
362
+ later time. The GUI bindings will not replace something like GIMP,
363
+ for instance.
364
+
365
+ The gtk-widget here will operate on images via an "image-chain".
366
+ This is simply an array of images that are stored subsequently.
367
+ It's not as elegant as real layers and undo-operations in, say,
368
+ GIMP, but it is easy to implement and work-with. See the **undo**
369
+ button for an example of this.
370
+
371
+ To start the ruby-gtk3 bindings, try:
372
+
373
+ image_paradise --gui
374
+
375
+ image_paradise --gtk # or this variant
376
+ image_paradise --gtk3 # or this variant; this will start the gtk-cfdg widget actually
377
+ image_paradise --gtk-image # or this variant
378
+
379
+ Note that in **February 2022** the ruby-gtk2 bindings of the
380
+ gkt-image widget were removed. Perhaps at a later time they
381
+ may be re-added, but for the time being I focus solely on
382
+ ruby-gtk3 instead.
383
+
384
+ Which features are available?
385
+
386
+ Well, as explained above, only features are made available via
387
+ the GUI that are documented here on this page.
388
+
389
+ So far the following features have been implemented via
390
+ the ruby-gtk3 bindings and ImageMagick (March 2021):
391
+
392
+ - Flip horizontally
393
+ - Greyscale the image
394
+ - Add a coloured border around an image
395
+ - Negate the image (180° colour-flip)
396
+ - Resize the image
397
+ - Apply a **gaussian blur** onto the image
398
+ - Add a roundish-circle as the main center view onto the main image
399
+ - Draw text onto the image (currently limited, only one font; will
400
+ have to add support for more fonts there)
401
+ - Basic shape drawing: drawing a line is possible. Drawing a rectangle
402
+ is possible.
403
+ - Crop the image (currently only via gtk-entries, but one day
404
+ we should be able to overlay a crop-mask to calculate the
405
+ crop area properly)
406
+ - Upon pressing the middle-mouse-button on the gtk-entry displaying
407
+ the colour in use for the border, randomly assign a new
408
+ colour from the available HTML colours
409
+ - Able to create a new image (currently background is white)
410
+
411
+ Todo List:
412
+
413
+ - The drawing lines and rectangle should occur on a new image,
414
+ rather than this creates a new image as it currently does.
415
+ - Show info-box displaying information about the current image,
416
+ ideally on the right-hand side. This should include size, and
417
+ perhaps additional information about the image-type as well,
418
+ alpha value and so forth. This has been partially added; needs
419
+ more information still and be made prettier as well.
420
+ - Provide an "undo" button (can be lazy, aka store incomplete images)
421
+ - Add a file-open button. Probably place it on the right side somewhere.
422
+ - Add colour-gradients.
423
+ - Add filters.
424
+ - Add de-novo creation of images; possibly via a small widget
425
+ that allows us to do so. That could be a separate widget
426
+ that can then be integrated into the parent widget.
427
+
428
+ - Add way to query the x and y position accurately on a mouse-button
429
+ event, for the main image.
430
+ - Add a resizable pane widget to the bottom area of the
431
+ main image so that the user can change the size.
432
+
433
+ - Basic shape drawing: we need to be able to combine it into the
434
+ currently loading image, aka "draw on screen" as-is.
435
+
436
+ - Upon mouse-scroll-wheel press-events on the entry with the
437
+ percentage value, change accordingly up or down, so that the
438
+ user may just use the mouse for changes.
439
+
440
+ - Basic shape drawing: we need to add the remaining functionality
441
+ such as drawing a circle, a line and what not.
442
+
443
+ - Add a direct way for the user to do a resize operation.
444
+ Perhaps a general input-entry that gets highlighted or
445
+ something.
446
+ The idea is to support this:
447
+ convert -resize 42x148 input.jpg output.jpg
448
+
449
+ But to not have the user enter the output name (or perhaps
450
+ still do hmm).
451
+
452
+ - Add a way to specify which lines are to be drawn via a
453
+ script. That way we can use it to automatically draw or
454
+ re-draw specific images as-is. The idea would be that we
455
+ could programmatically generate any image possible, but
456
+ this will probably require changes to the commandline
457
+ version first, before expanding this onto the GUI.
458
+
459
+ ## Blur effects via ImageParadise.blur()
460
+
461
+ You can use the following API for blur-effects:
462
+
463
+ ImageParadise.blur
464
+ ImageParadise.blur('foo.png')
465
+ ImageParadise.blur('foo.png', 5)
466
+ ImageParadise.blur('foo.png', 50)
467
+
468
+ These will modify an image, aka **blur** it. The second argument
469
+ is the radius for the blur operation to use. This functionality
470
+ depends on ImageMagick being installed on the host computer
471
+ system in use.
472
+
473
+ ## Changing the quality of an image
474
+
475
+ Via **ImageMagick** you can use this command to change the quality
476
+ of an image:
477
+
478
+ convert -quality 10% input.jpg output.jpg
479
+
480
+ Via ruby and the image_paradise project, you can use this API:
481
+
482
+ ImageParadise.quality('input.jpg',10,'output.jpg'
483
+
484
+ Be careful when you have .jpg files; from experience I see **a
485
+ lot of deterioration** in regards to quality if you have to do
486
+ many operations again and again. In this case, you may be
487
+ better off converting into .png, then modifying the .png,
488
+ before then converting it back into .jpg again. Note that
489
+ this also causes loss in quality usually, but you have only
490
+ two conversion steps, whereas if you, say, have to do 10
491
+ operations on the .jpg, drawing stuff on the canvas, this
492
+ may lead to worse image quality if you started with a .jpg
493
+ file and keep on working with it.
494
+
495
+ Even a one-time saving to .jpg may impact its quality
496
+ negatively, depending on the chosen quality. As a rule of
497
+ thumb, if I want to maintain some useful quality in a
498
+ given image, I don't go below the 84% quality threshold
499
+ for .jpg files. In the long run, though, I will probably
500
+ switch to a better format when it comes to lossy
501
+ encoding, perhaps WebP - we'll see.
502
+
503
+ ## Rotating an image
504
+
505
+ (Technically this is similar to flip-flop, but I added this functionality
506
+ at a later point, so the flip-flop subsection here shall remain for the
507
+ time being.)
508
+
509
+ The commandline API for rotating an image called **FOOBAR.png**, in
510
+ regards to image_paradise, may go so:
511
+
512
+ imgparadise FOOBAR.png --rotate=33%
513
+ imgparadise foo.png --rotate=90%
514
+ imgparadise *.png --rotate=90%
515
+
516
+ Simply pass the rotation-value that you wish to use into --rotate.
517
+
518
+ Be careful, though - this command will overwrite the image, so **make
519
+ sure to backup your old image** before applying this command.
520
+
521
+ Sometimes you may dislike the background colour used, after having
522
+ applied a rotate-effect. In this case, recall that you can specify
523
+ the background color via **-background red** or another name.
524
+ (This may be integrated into the ruby-gtk3 wrapper, but it is
525
+ currently, in May 2021, not added.)
526
+
527
+ ## The difference between the fill colour and the stroke colour
528
+
529
+ <b>Fill colour</b>:
530
+
531
+ - It fills objects with that colour. So a fill colour of red,
532
+ will paint the object's content, such as a circle in red too.
533
+ You thus get a red circle.
534
+
535
+ <b>Stroke colour</b>:
536
+
537
+ - This colour draws the outline of an object. In other words,
538
+ it will specify a border.
539
+
540
+ ## Table of some ImageMagick commands
541
+
542
+ I did not want to google all the time, so here is just a short
543
+ memo for me which options exist in ImageMagick. This is currently
544
+ very incomplete; in the future I may extend this list.
545
+
546
+ -pointsize 24 # specify the width of the drawling
547
+ -stroke red # use red as the colour for the paint-stroke to be done
548
+ -fill red # this is the fill colour, aka the content of an object
549
+ -strokewidth 3 # set the width, in px, of the paint-stroke action
550
+ -linewidth 5 # the width of the line, when drawing a line
551
+ -font Arbuckle.ttf # use this font; you can specify a local file path too, to a .ttf file
552
+ -annotate 45x0+10+30 # Annotate via 45° angle
553
+
554
+ Because I may re-use the -font option in particular, here is a variant
555
+ that I use:
556
+
557
+ convert -pointsize 24 -font /home/x/src/fonts/Hack-Regular.ttf -stroke red -fill red -annotate 0x0+10+30 testing.com /Depot/NJOY/WaterGirl.png output.png
558
+
559
+ ImageMagick itself supports at the very least **TrueType fonts**,
560
+ **PostScript** and **OPTION1** fonts.
561
+
562
+ ## Borders
563
+
564
+ This subsection explains some general stuff about borders. In this
565
+ context a **border** means an area around an image, such as a
566
+ black border around an image that has a width of 3 pixels (px).
567
+
568
+ You can add some borders to images thanks to **ImageMagick**. The
569
+ **image_paradise** gem supports this as well, to some extent.
570
+
571
+ The toplevel method **ImageParadise.add_black_border_to_this_image()**
572
+ can be used to add a black border to an image. It is a very simple
573
+ method. The first argument to this method is the path to the image
574
+ at hand. The second argument specifies the size of the border,
575
+ in **pixels**. So, if you pass the number **3** as second argument
576
+ then this would mean to draw a border 3 pixel wide around the
577
+ image at hand.
578
+
579
+ Invocation example for the local image file called **foobar.png**
580
+ follows next - adapt this to your own needs as-is:
581
+
582
+ require 'image_paradise/toplevel_methods/add_black_border_to_this_image.rb'
583
+ ImageParadise.add_black_border_to_this_image('foobar.png', 3) # we want the border to have 3 pixels
584
+
585
+ Obviously for this to work, the file must exist locally.
586
+
587
+ It is also possible to add a rounded black border. This can be
588
+ seen in traditional card games, such as **magic the gathering**.
589
+
590
+ If you want to use that, consider making use of the following
591
+ class/file and API:
592
+
593
+ require 'image_paradise/utility_scripts/magic_card_border.rb'
594
+ ImageParadise.:MagicCardBorder.new(ARGV)
595
+ # such as in:
596
+ # ImageParadise.:MagicCardBorder.new('foobar.png')
597
+
598
+ See the --help options for what the class will support.
599
+
600
+ You can alias it to e. g. **magic-rounded** and then
601
+ invoke it via:
602
+
603
+ magic-rounded --size=5
604
+ magic-rounded --size=5 foobar.png
605
+ magic-rounded --size=12 foobar.png
606
+ magic-rounded --size=25 foobar.png
607
+
608
+ The --size parameter determines which size to use, via
609
+ the commandline. I recommend keeping the --size parameter
610
+ fairly small; more than **--size=12** is rarely necessary,
611
+ in my opinion. Better to have a slight black border than
612
+ a huge one - but, either way, this is entirely up to the
613
+ user.
614
+
615
+ ## Some toplevel methods explained
616
+
617
+ The method **ImageParadise.default_colour?** will give back
618
+ the default colour for the project, if it has been assigned.
619
+ I needed this because some image-related operations require
620
+ a colour, and being able to omit this for subsequent use
621
+ can be convenient, aka set the colour once, and then
622
+ continue to work from there.
623
+
624
+ ## API consideration
625
+
626
+ This subsection shows a few syntax examples how I plan to
627
+ rewrite the project in **2022**.
628
+
629
+ Write the text "Hello world" on the image **FOOBAR.png**:
630
+
631
+ textonimage FOOBAR.png --text="Hello world" --colour=darkgreen --font-size=22 --position=3,4
632
+
633
+ This will be passed to class **ImageParadise::TextOnImage**,
634
+ where **ipa** is an alias I use towards
635
+ **bin/image_paradise**. I intend to improve this
636
+ class over the coming weeks.
637
+
638
+ An even simpler variant follows for a closely related
639
+ script, at **bin/img_text**:
640
+
641
+ imgtext what the heck some_file.png --darkblue
642
+ imgtext what the heck some_file.png --tomato # you can pass HTML colours here
643
+
644
+ Why is the example shown above via **imgtext** nice to have?
645
+
646
+ Well - the idea here is that you first think what kind of
647
+ text you want to display on the image. Then, you pass the
648
+ image filename, such as foobar.png. And then you append
649
+ extra commandline flags via -- such as --darkblue.
650
+
651
+ It may be hard to explain why this is useful, but just give
652
+ it a try on some existing image, and play around a bit with
653
+ it. Further options to customise this even more may be
654
+ added in the future.
655
+
656
+ ## Which fonts are available for ImageMagick?
657
+
658
+ The answer to this question depends on your computer system.
659
+
660
+ If you are, however had, like me and often forget then
661
+ the following list will contain some font names that
662
+ **may** be available on your linux system too. On Windows
663
+ I do not know whether these are available or not, but
664
+ since Linux is my main operating system I focus primarily
665
+ on Linux.
666
+
667
+ The following list is **not** complete - it just gives a
668
+ few helpful pointers to available names that **may** be
669
+ usable by you.
670
+
671
+ Here we go:
672
+
673
+ AvantGarde, Bookman, Courier, Helvetica, NewCenturySchlbk,
674
+ Palatino, Symbol, Times, Bitstream-Charter, Century-Schoolbook,
675
+ Chandas, Courier, DejaVu-Sans, DejaVu-Serif, Garuda, Hack-Regular,
676
+ Kedage-Normal, Kinnari, Liberation-Mono, Liberation-Sans,
677
+ Liberation-Serif, Loma, Luxi-Mono, Luxi-Sans, Luxi-Serif,
678
+ Mallige-Normal, Nimbus-Mono-L, Nimbus-Roman-No9-L,
679
+ Nimbus-Sans-L, NimbusMonoPS-Regular, NimbusSans-Bold,
680
+ Norasi-Bold, Noto-Mono, Noto-Serif-Bold, Oxygen-Mono,
681
+ Terminus-Regular, Umpush, URW-Gothic-L-Book, Utopia.
682
+
683
+ ## Embedding the filename into an image file
684
+
685
+ You can embed the filename (or any other text) into images
686
+ via **imagemagick**. In <b>April 2022</b>, I had a use
687
+ case where I needed to put down the name of the image
688
+ file into the image itself.
689
+
690
+ The syntax from the commandline looks as follows:
691
+
692
+ convert name_of_the_image_file_goes_here.jpg -font Luxi-Mono -pointsize 32 -draw "gravity northwest fill white text 0,15 'Filename' " output.jpg
693
+ convert TANA* -font Luxi-Mono -pointsize 32 -draw "gravity northwest fill white text 0,15 'Filename' " output.jpg
694
+
695
+ I wanted to automate this, though, so the following API
696
+ was added to the ImageParadise gem:
697
+
698
+ ImageParadise.embed_the_filename_into_this_image()
699
+ ImageParadise.embed_the_filename_into_this_image('name_of_the_image_file_goes_here.jpg')
700
+
701
+ This is not very customizable though as I just use it
702
+ for hardcoded values mostly. You may have to adjust it
703
+ to your own use case; at the least the method exists,
704
+ so you can modify it as-is. The second argument is a
705
+ Hash which allows for some modifications.
706
+
707
+ For instance, a larger text size can be done via:
708
+
709
+ ImageParadise.embed_the_filename_into_this_image('foobar.jpg', { font_size: 50 })
710
+
711
+ To combine this with a different colour use:
712
+
713
+ ImageParadise.embed_the_filename_into_this_image('foobar.jpg', { font_size: 50, colour_to_use: :tomato }) # You can use the HTML colours here.
714
+
715
+ Note that you can also pass a directory as the first
716
+ argument. So, rather than pass 'foobar.jpg', you
717
+ could pass '/foo/bar/' and the method will gather all
718
+ .gif, .jpg and .png files there, then work on these
719
+ one after the other. This allows us to batch-process
720
+ whole directories containing images. Don't forget
721
+ to keep a backup of these images **before** calling
722
+ this method, though!
723
+
724
+ Usage example:
725
+
726
+ ImageParadise.embed_the_filename_into_this_image('/foo/bar/')
727
+
728
+ ## Determining whether a given file is an animated image
729
+
730
+ The following functionality depends on ImageMagick.
731
+
732
+ To determine whether an image is animated you can use the following
733
+ API:
734
+
735
+ ImageParadise.is_this_image_animated?('/foobar.gif') # => true
736
+ ImageParadise.is_this_image_animated?("TANAKA.jpg") # => false
737
+
738
+ ## Determining whether a given file is an image file or whether it is not
739
+
740
+ You can use the following API to determine whether the given file is an
741
+ image file or whether it is not.
742
+
743
+ ImageParadise.is_an_image_file?()
744
+ ImageParadise.is_an_image?()
745
+
746
+ Both variants work fine. The second is a bit shorter, so let's look at a
747
+ specific example:
748
+
749
+ ImageParadise.is_an_image?('/tmp/cat.png')
750
+ ImageParadise.is_an_image?('/tmp/dog.gif')
751
+ ImageParadise.is_an_image?('/tmp/deer.bmp')
752
+
753
+ This will return true if it is an image, and false otherwise. Presently
754
+ (in 2022) this works via a constant where the file types are registered,
755
+ e. g. ".png" or ".jpg" all are files. In the future another method may
756
+ be added that uses either "file" to identify the file at hand, or another
757
+ variant by probing the content to determine whether this is really a file
758
+ or not. But currently no such API exists. If it will be added then it
759
+ will probably have another name, so for the time being
760
+ <b>ImageParadise.is_an_image?()</b> should suffice.
761
+
762
+ ## Support for chunky_png and examples using chunky_png
763
+
764
+ ChunkyPNG is a ruby-only library that helps the user create
765
+ .png files or read from existing .png files. It is super-convenient
766
+ to use, in many ways even easier to use than ImageMagick. On the
767
+ other hand, a lot of the functionality that ChunkPNG offers can
768
+ be used via ImageMagick. So perhaps ImageMagick is better.
769
+
770
+ Still - as ChunkyPNG exists, I decided to add support to it within
771
+ the namespace called <b>ImageParadise::ChunkyPNG</b>. This may
772
+ be a bit hackish, and support will not be complete, but just more
773
+ of an example what can be done via ChunkyPNG.
774
+
775
+ This subsection will list some examples.
776
+
777
+ To combine two .png files, and overlay one onto the other,
778
+ use:
779
+
780
+ ImageParadise::ChunkyPNG.overlay('Leeann_Tweeden.png','Cute_Biker.png', :center)
781
+
782
+ ## Support via Pango
783
+
784
+ ImageMagick knows how to use Pango.
785
+
786
+ Consider the following commandline examples:
787
+
788
+ convert -size 600x100 -gravity center -pointsize 48 pango:"The <span foreground='blue'>blue</span> word." output.png
789
+ convert -size 400x200 -gravity center -background khaki -pointsize 30 pango:"<i>A</i> &#x229B; <i>B</i> &#x21D2; <i>C</i>" chars.png
790
+ convert -size 400x200 -gravity northeast -background khaki -pointsize 30 pango:"<span foreground='green' size=\"55555\">A</span><span foreground='green' size=\"30000\">A</span><span size=\"30000\">B</span>C" chars.png
791
+
792
+ ## Resizing an image
793
+
794
+ Images (in 2D) typically have a width and a height setting, such
795
+ as 400px width and 300 px height. This is typically denoted like
796
+ this: 400x300.
797
+
798
+ Naturally you may want to resize an image eventually, for instance,
799
+ by showing it on a webpage. Size often matters here, due to the
800
+ data volume passed to the recipient.
801
+
802
+ ImageMagick allows you to resize an image like this, via the
803
+ commandline:
804
+
805
+ convert -resize 40% foobar.jpg output.jpg
806
+
807
+ This worked if you then use identify to check the width and
808
+ height:
809
+
810
+ identify foobar.jpg
811
+
812
+ Result: foobar.jpg JPEG 280x499 280x499+0+0 8-bit sRGB 32644B 0.000u 0:00.000
813
+
814
+ identify output.jpg
815
+
816
+ Result output.jpg JPEG 112x200 112x200+0+0 8-bit sRGB 8141B 0.000u 0:00.000
817
+
818
+ So, if you multiply 280.0 * 0.4 you get 112.0, which is precisely the width
819
+ value that the file <b>output.jpg</b> has.
820
+
821
+ I wanted an API in ruby that would allow me to do the same:
822
+
823
+ shrink foobar.jpg 40%
824
+
825
+ on the commandline. However had, I realised that I may want to omit
826
+ the <b>trailing %</b> specifically, or even omit the last part
827
+ altogether, thus only using the following commandline variant:
828
+
829
+ shrink foobar.jpg # the first argument is the locally existing file
830
+
831
+ In that case, <b>shrink</b> will shrink the image down to 75%, thus,
832
+ width and height will be multiplied by a factor of 0.25 to obtain the
833
+ new width and height (rounded down, always, to get integer pixel
834
+ values).
835
+
836
+ If you want to do this from within ruby, you can, after requiring
837
+ the image_paradise gem, use any of the following:
838
+
839
+ ImageParadise.resize_by_percent('foobar.jpg')
840
+ ImageParadise.resize_by_percentage('foobar.jpg')
841
+ ImageParadise.resize_percent('foobar.jpg')
842
+ ImageParadise.percent('foobar.jpg', 20)
843
+ ImageParadise.percent('foobar.jpg', '30')
844
+ ImageParadise.percent('foobar.jpg', '40%')
845
+
846
+ Use whatever variant you prefer here. The first one is the official name;
847
+ I think it is the best to remember. <b>ImageParadise.percent()</b>
848
+ exists mostly in the event that you quickly want to use it
849
+ from within <b>irb</b>.
850
+
851
+ The executable that bundles this functionality into a standalone
852
+ file can be found at <b>bin/resize_by_percent</b>.
853
+
854
+ ## Query the width and the height of an image
855
+
856
+ You can use the following method to determine (return) the
857
+ width of an image (in n px, aka n pixels):
858
+
859
+ ImageParadise.width_of_this_image?
860
+ ImageParadise.width_of_this_image?('foobar.png')
861
+ ImageParadise.width_of_this_image? "red_six_sided_die.png"
862
+
863
+ A similar method exists for the height of an image:
864
+
865
+ ImageParadise.height_of_this_image?
866
+ ImageParadise.height_of_this_image?('foobar.png')
867
+ ImageParadise.height_of_this_image? "red_six_sided_die.png"
868
+
869
+ USE_THE_MIT_LICENCE
870
+
871
+ ADD_CONTACT_INFORMATION