nouns 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 05742baba4782338899527821c1ec706a34cae1f2258a08799fe048050820b73
4
+ data.tar.gz: b7439f154eaf59998771fccdda5bc2ff95cfe3eb979c2e1fcdcb4c194bbc28ad
5
+ SHA512:
6
+ metadata.gz: 11b91d8b8e9519df6d0a0e4632f90e08e581c8893f1ba5df57d0f23cdb2f8e66ba556e3e29314ad8894d2ba969d15bfc5b56720f4ca251d1fb59725cd7371f29
7
+ data.tar.gz: dc020161eb68670069ca5f75f17b53dadb59f5afbd916b7c431d12ae0691e73c6d6c0fc886345dabdd44765841496ef328352d97328ece0d04702e9706a636a5
data/CHANGELOG.md ADDED
@@ -0,0 +1,3 @@
1
+ ### 0.0.1 / 2021-05-20
2
+
3
+ * Everything is new. First release
data/Manifest.txt ADDED
@@ -0,0 +1,8 @@
1
+ CHANGELOG.md
2
+ Manifest.txt
3
+ README.md
4
+ Rakefile
5
+ config/spritesheet.csv
6
+ config/spritesheet.png
7
+ lib/nouns.rb
8
+ lib/nouns/version.rb
data/README.md ADDED
@@ -0,0 +1,161 @@
1
+ # Nouns (Pixel Avatars)
2
+
3
+ nouns - generate your own 32×32 pixel avatar images (off chain) from text attributes (via built-in spritesheet); incl. 2x/4x/8x zoom for bigger sizes and more
4
+
5
+
6
+
7
+ * home :: [github.com/pixelartexchange/pixelart](https://github.com/pixelartexchange/pixelart)
8
+ * bugs :: [github.com/pixelartexchange/pixelart/issues](https://github.com/pixelartexchange/pixelart/issues)
9
+ * gem :: [rubygems.org/gems/nouns](https://rubygems.org/gems/nouns)
10
+ * rdoc :: [rubydoc.info/gems/nouns](http://rubydoc.info/gems/nouns)
11
+
12
+
13
+
14
+
15
+ ## Usage
16
+
17
+ Let's generate some super-rare never-before-seen
18
+ nouns (pixel avatars).
19
+
20
+ Note: For best merging / composing (of the attributes)
21
+ use the order 1) Body, 2) (Body) Accessory, 3) Head and 4) Glasses:
22
+
23
+ ```ruby
24
+ require 'nouns'
25
+
26
+ #####
27
+ # Noun No. 1
28
+ noun = Noun::Image.generate( 'Body Grayscale 1',
29
+ 'Checker Bigwalk Rainbow',
30
+ 'Head Beer',
31
+ 'Glasses Square Fullblack' )
32
+ noun.save( "noun1.png")
33
+ noun.zoom(4).save( "noun1@4x.png" )
34
+
35
+ ## let's add a background
36
+ noun = Noun::Image.generate( 'Body Grayscale 1',
37
+ 'Checker Bigwalk Rainbow',
38
+ 'Head Beer',
39
+ 'Glasses Square Fullblack',
40
+ background: '#638596' )
41
+ noun.save( "noun1b.png")
42
+ noun.zoom(4).save( "noun1b@4x.png" )
43
+ ```
44
+
45
+ Voila!
46
+
47
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun1.png)
48
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun1b.png)
49
+
50
+ In 4x:
51
+
52
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun1@4x.png)
53
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun1b@4x.png)
54
+
55
+
56
+
57
+ ```ruby
58
+ ###
59
+ # Noun No. 2
60
+ noun = Noun::Image.generate( 'Body Red',
61
+ 'Txt LOL',
62
+ 'Head Weed',
63
+ 'Glasses Square Black RGB' )
64
+ noun.save( "noun2.png")
65
+ noun.zoom(4).save( "noun2@4x.png" )
66
+
67
+
68
+ ###
69
+ # Noun No. 3
70
+ noun = Noun::Image.generate( 'Body Gold',
71
+ 'Chain Logo',
72
+ 'Head Ape',
73
+ 'Glasses Square Teal' )
74
+ noun.save( "noun3.png")
75
+ noun.zoom(4).save( "noun3@4x.png" )
76
+
77
+
78
+ ###
79
+ # Noun No. 4
80
+ noun = Noun::Image.generate( 'Body Green',
81
+ 'Dollar Bling',
82
+ 'Head Bear',
83
+ 'Glasses Square Blue' )
84
+ noun.save( "noun4.png")
85
+ noun.zoom(4).save( "noun4@4x.png" )
86
+
87
+
88
+ ###
89
+ # Noun No. 5
90
+ noun = Noun::Image.generate( 'Body Gradient Pride',
91
+ 'Bling Love',
92
+ 'Head Bubblegum',
93
+ 'Glasses Square Yellow Saturated' )
94
+ noun.save( "noun5.png")
95
+ noun.zoom(4).save( "noun5@4x.png" )
96
+ ```
97
+
98
+ Voila!
99
+
100
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun2.png)
101
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun3.png)
102
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun4.png)
103
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun5.png)
104
+
105
+ In 4x:
106
+
107
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun2@4x.png)
108
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun3@4x.png)
109
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun4@4x.png)
110
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/noun5@4x.png)
111
+
112
+
113
+ And so on.
114
+
115
+ ### Bonus - Look-Up Attributes (Via Built-In Spritesheet)
116
+
117
+
118
+ Let's look-up some attributes:
119
+
120
+ ```ruby
121
+ body_gold = Noun::Sheet.find_by( name: 'Body Gold' )
122
+ txt_pi = Noun::Sheet.find_by( name: 'Txt Pi' )
123
+ head_weed = Noun::Sheet.find_by( name: 'Head Weed' )
124
+ glasses_square_black_rgb = Noun::Sheet.find_by( name: 'Glasses Square Black RGB' )
125
+
126
+ body_gold.save( "body_gold.png" )
127
+ txt_pi.save( "txt_pi.png" )
128
+ head_weed.save( "head_weed.png" )
129
+ glasses_square_black_rgb.save( "glasses_square_black_rgb.png" )
130
+
131
+ body_gold.zoom( 4 ).save( "body_gold@4x.png" )
132
+ txt_pi.zoom( 4 ).save( "txt_pi@4x.png" )
133
+ head_weed.zoom( 4 ).save( "head_weed@4x.png" )
134
+ glasses_square_black_rgb.zoom( 4 ).save( "glasses_square_black_rgb@4x.png" )
135
+ ```
136
+
137
+
138
+
139
+ Voila!
140
+
141
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/body_gold.png)
142
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/txt_pi.png)
143
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/head_weed.png)
144
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/glasses_square_black_rgb.png)
145
+
146
+ In 4x:
147
+
148
+
149
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/body_gold@4x.png)
150
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/txt_pi@4x.png)
151
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/head_weed@4x.png)
152
+ ![](https://github.com/pixelartexchange/pixelart/raw/master/nouns/i/glasses_square_black_rgb@4x.png)
153
+
154
+ And so on.
155
+
156
+
157
+
158
+
159
+ ## Questions? Comments?
160
+
161
+ Post them on the [CryptoPunksDev reddit](https://old.reddit.com/r/CryptoPunksDev). Thanks.
data/Rakefile ADDED
@@ -0,0 +1,38 @@
1
+ require 'hoe'
2
+ require './lib/nouns/version.rb'
3
+
4
+ ###
5
+ # hack/ quick fix for broken intuit_values - overwrite with dummy
6
+ class Hoe
7
+ def intuit_values( input ); end
8
+ end
9
+
10
+
11
+
12
+ Hoe.spec 'nouns' do
13
+
14
+ self.version = Nouns::VERSION
15
+
16
+ self.summary = "nouns - generate your own 32×32 pixel avatar images (off chain) from text attributes (via built-in spritesheet); incl. 2x/4x/8x zoom for bigger sizes and more"
17
+ self.description = summary
18
+
19
+ self.urls = { home: 'https://github.com/pixelartexchange/pixelart' }
20
+
21
+ self.author = 'Gerald Bauer'
22
+ self.email = 'wwwmake@googlegroups.com'
23
+
24
+ # switch extension to .markdown for gihub formatting
25
+ self.readme_file = 'README.md'
26
+ self.history_file = 'CHANGELOG.md'
27
+
28
+ self.extra_deps = [
29
+ ['pixelart', '>= 1.3.1'],
30
+ ]
31
+
32
+ self.licenses = ['Public Domain']
33
+
34
+ self.spec_extras = {
35
+ required_ruby_version: '>= 2.3'
36
+ }
37
+
38
+ end
@@ -0,0 +1,418 @@
1
+ id, name, type, more_names
2
+ 0, head-aardvark, ?,
3
+ 1, head-abstract, ?,
4
+ 2, head-ape, ?,
5
+ 3, head-bag, ?,
6
+ 4, head-bagpipe, ?,
7
+ 5, head-banana, ?,
8
+ 6, head-bank, ?,
9
+ 7, head-baseball-gameball, ?,
10
+ 8, head-basketball, ?,
11
+ 9, head-bat, ?,
12
+ 10, head-bear, ?,
13
+ 11, head-beer, ?,
14
+ 12, head-beet, ?,
15
+ 13, head-bell, ?,
16
+ 14, head-bigfoot-yeti, ?,
17
+ 15, head-bigfoot, ?,
18
+ 16, head-blackhole, ?,
19
+ 17, head-blueberry, ?,
20
+ 18, head-bomb, ?,
21
+ 19, head-bonsai, ?,
22
+ 20, head-boombox, ?,
23
+ 21, head-boot, ?,
24
+ 22, head-box, ?,
25
+ 23, head-boxingglove, ?,
26
+ 24, head-brain, ?,
27
+ 25, head-bubble-speech, ?,
28
+ 26, head-bubblegum, ?,
29
+ 27, head-burger-dollarmenu, ?,
30
+ 28, head-cake, ?,
31
+ 29, head-calculator, ?,
32
+ 30, head-calendar, ?,
33
+ 31, head-camcorder, ?,
34
+ 32, head-cannedham, ?,
35
+ 33, head-car, ?,
36
+ 34, head-cash-register, ?,
37
+ 35, head-cassettetape, ?,
38
+ 36, head-cat, ?,
39
+ 37, head-cd, ?,
40
+ 38, head-chain, ?,
41
+ 39, head-chainsaw, ?,
42
+ 40, head-chameleon, ?,
43
+ 41, head-chart-bars, ?,
44
+ 42, head-cheese, ?,
45
+ 43, head-chefhat, ?,
46
+ 44, head-cherry, ?,
47
+ 45, head-chicken, ?,
48
+ 46, head-chilli, ?,
49
+ 47, head-chipboard, ?,
50
+ 48, head-chips, ?,
51
+ 49, head-chocolate, ?,
52
+ 50, head-cloud, ?,
53
+ 51, head-clover, ?,
54
+ 52, head-clutch, ?,
55
+ 53, head-coffeebean, ?,
56
+ 54, head-cone, ?,
57
+ 55, head-console-handheld, ?,
58
+ 56, head-cookie, ?,
59
+ 57, head-cordlessphone, ?,
60
+ 58, head-cottonball, ?,
61
+ 59, head-cow, ?,
62
+ 60, head-crab, ?,
63
+ 61, head-crane, ?,
64
+ 62, head-croc-hat, ?,
65
+ 63, head-crown, ?,
66
+ 64, head-crt-bsod, ?,
67
+ 65, head-crystalball, ?,
68
+ 66, head-diamond-blue, ?,
69
+ 67, head-diamond-red, ?,
70
+ 68, head-dictionary, ?,
71
+ 69, head-dino, ?,
72
+ 70, head-dna, ?,
73
+ 71, head-dog, ?,
74
+ 72, head-doughnut, ?,
75
+ 73, head-drill, ?,
76
+ 74, head-duck, ?,
77
+ 75, head-ducky, ?,
78
+ 76, head-earth, ?,
79
+ 77, head-egg, ?,
80
+ 78, head-faberge, ?,
81
+ 79, head-factory-dark, ?,
82
+ 80, head-fan, ?,
83
+ 81, head-fence, ?,
84
+ 82, head-film-35mm, ?,
85
+ 83, head-film-strip, ?,
86
+ 84, head-fir, ?,
87
+ 85, head-firehydrant, ?,
88
+ 86, head-flamingo, ?,
89
+ 87, head-flower, ?,
90
+ 88, head-fox, ?,
91
+ 89, head-frog, ?,
92
+ 90, head-garlic, ?,
93
+ 91, head-gavel, ?,
94
+ 92, head-ghost-b, ?,
95
+ 93, head-glasses-big, ?,
96
+ 94, head-gnome, ?,
97
+ 95, head-goat, ?,
98
+ 96, head-goldcoin, ?,
99
+ 97, head-goldfish, ?,
100
+ 98, head-grouper, ?,
101
+ 99, head-hair, ?,
102
+ 100, head-hardhat, ?,
103
+ 101, head-heart, ?,
104
+ 102, head-helicopter, ?,
105
+ 103, head-highheel, ?,
106
+ 104, head-hockeypuck, ?,
107
+ 105, head-horse-deepfried, ?,
108
+ 106, head-hotdog, ?,
109
+ 107, head-house, ?,
110
+ 108, head-icepop-b, ?,
111
+ 109, head-igloo, ?,
112
+ 110, head-island, ?,
113
+ 111, head-jellyfish, ?,
114
+ 112, head-jupiter, ?,
115
+ 113, head-kangaroo, ?,
116
+ 114, head-ketchup, ?,
117
+ 115, head-laptop, ?,
118
+ 116, head-lightning-bolt, ?,
119
+ 117, head-lint, ?,
120
+ 118, head-lips, ?,
121
+ 119, head-lipstick2, ?,
122
+ 120, head-lock, ?,
123
+ 121, head-macaroni, ?,
124
+ 122, head-mailbox, ?,
125
+ 123, head-maze, ?,
126
+ 124, head-microwave, ?,
127
+ 125, head-milk, ?,
128
+ 126, head-mirror, ?,
129
+ 127, head-mixer, ?,
130
+ 128, head-moon, ?,
131
+ 129, head-moose, ?,
132
+ 130, head-mosquito, ?,
133
+ 131, head-mountain-snowcap, ?,
134
+ 132, head-mouse, ?,
135
+ 133, head-mug, ?,
136
+ 134, head-mushroom, ?,
137
+ 135, head-mustard, ?,
138
+ 136, head-nigiri, ?,
139
+ 137, head-noodles, ?,
140
+ 138, head-onion, ?,
141
+ 139, head-orangutan, ?,
142
+ 140, head-orca, ?,
143
+ 141, head-otter, ?,
144
+ 142, head-outlet, ?,
145
+ 143, head-owl, ?,
146
+ 144, head-oyster, ?,
147
+ 145, head-paintbrush, ?,
148
+ 146, head-panda, ?,
149
+ 147, head-paperclip, ?,
150
+ 148, head-peanut, ?,
151
+ 149, head-pencil-tip, ?,
152
+ 150, head-peyote, ?,
153
+ 151, head-piano, ?,
154
+ 152, head-pickle, ?,
155
+ 153, head-pie, ?,
156
+ 154, head-piggybank, ?,
157
+ 155, head-pill, ?,
158
+ 156, head-pillow, ?,
159
+ 157, head-pineapple, ?,
160
+ 158, head-pipe, ?,
161
+ 159, head-pirateship, ?,
162
+ 160, head-pizza, ?,
163
+ 161, head-plane, ?,
164
+ 162, head-pop, ?,
165
+ 163, head-porkbao, ?,
166
+ 164, head-potato, ?,
167
+ 165, head-pufferfish, ?,
168
+ 166, head-pumpkin, ?,
169
+ 167, head-pyramid, ?,
170
+ 168, head-queencrown, ?,
171
+ 169, head-rabbit, ?,
172
+ 170, head-rainbow, ?,
173
+ 171, head-rangefinder, ?,
174
+ 172, head-raven, ?,
175
+ 173, head-retainer, ?,
176
+ 174, head-rgb, ?,
177
+ 175, head-ring, ?,
178
+ 176, head-road, ?,
179
+ 177, head-robot, ?,
180
+ 178, head-rock, ?,
181
+ 179, head-rosebud, ?,
182
+ 180, head-ruler-triangular, ?,
183
+ 181, head-saguaro, ?,
184
+ 182, head-sailboat, ?,
185
+ 183, head-sandwich, ?,
186
+ 184, head-saturn, ?,
187
+ 185, head-saw, ?,
188
+ 186, head-scorpion, ?,
189
+ 187, head-shark, ?,
190
+ 188, head-shower, ?,
191
+ 189, head-skateboard, ?,
192
+ 190, head-skeleton-hat, ?,
193
+ 191, head-skilift, ?,
194
+ 192, head-smile, ?,
195
+ 193, head-snowglobe, ?,
196
+ 194, head-snowmobile, ?,
197
+ 195, head-spaghetti, ?,
198
+ 196, head-sponge, ?,
199
+ 197, head-squid, ?,
200
+ 198, head-stapler, ?,
201
+ 199, head-star-sparkles, ?,
202
+ 200, head-steak, ?,
203
+ 201, head-sunset, ?,
204
+ 202, head-taco-classic, ?,
205
+ 203, head-taxi, ?,
206
+ 204, head-thumbsup, ?,
207
+ 205, head-toaster, ?,
208
+ 206, head-toiletpaper-full, ?,
209
+ 207, head-tooth, ?,
210
+ 208, head-toothbrush-fresh, ?,
211
+ 209, head-tornado, ?,
212
+ 210, head-trashcan, ?,
213
+ 211, head-turing, ?,
214
+ 212, head-ufo, ?,
215
+ 213, head-undead, ?,
216
+ 214, head-unicorn, ?,
217
+ 215, head-vent, ?,
218
+ 216, head-void, ?,
219
+ 217, head-volcano, ?,
220
+ 218, head-volleyball, ?,
221
+ 219, head-wall, ?,
222
+ 220, head-wallet, ?,
223
+ 221, head-wallsafe, ?,
224
+ 222, head-washingmachine, ?,
225
+ 223, head-watch, ?,
226
+ 224, head-watermelon, ?,
227
+ 225, head-wave, ?,
228
+ 226, head-weed, ?,
229
+ 227, head-weight, ?,
230
+ 228, head-werewolf, ?,
231
+ 229, head-whale-alive, ?,
232
+ 230, head-whale, ?,
233
+ 231, head-wine, ?,
234
+ 232, head-wizardhat, ?,
235
+ 233, head-zebra, ?,
236
+ 234, glasses-hip-rose, ?,
237
+ 235, glasses-square-black-eyes-red, ?,
238
+ 236, glasses-square-black-rgb, ?,
239
+ 237, glasses-square-black, ?,
240
+ 238, glasses-square-blue-med-saturated, ?,
241
+ 239, glasses-square-blue, ?,
242
+ 240, glasses-square-frog-green, ?,
243
+ 241, glasses-square-fullblack, ?,
244
+ 242, glasses-square-green-blue-multi, ?,
245
+ 243, glasses-square-grey-light, ?,
246
+ 244, glasses-square-guava, ?,
247
+ 245, glasses-square-honey, ?,
248
+ 246, glasses-square-magenta, ?,
249
+ 247, glasses-square-orange, ?,
250
+ 248, glasses-square-pink-purple-multi, ?,
251
+ 249, glasses-square-red, ?,
252
+ 250, glasses-square-smoke, ?,
253
+ 251, glasses-square-teal, ?,
254
+ 252, glasses-square-watermelon, ?,
255
+ 253, glasses-square-yellow-orange-multi, ?,
256
+ 254, glasses-square-yellow-saturated, ?,
257
+ 255, Body Bege Bsod, ?, Body Bege | Bege | Bege Bsod
258
+ 256, Body Bege Crt, ?, Bege Crt
259
+ 257, Body Blue Sky, ?, Blue Sky
260
+ 258, Body Blue Grey, ?, Blue Grey
261
+ 259, Body Cold, ?, Body Ice Cold | Ice Cold | Cold
262
+ 260, Body Computer Blue, ?, Computer Blue
263
+ 261, Body Dark Brown, ?, Dark Brown
264
+ 262, Body Dark Pink, ?, Dark Pink
265
+ 263, Body Fog Grey, ?, Fog Grey
266
+ 264, Body Gold, ?, Gold
267
+ 265, Body Grayscale 1, ?, Grayscale 1
268
+ 266, Body Grayscale 7, ?, Grayscale 7
269
+ 267, Body Grayscale 8, ?, Grayscale 8
270
+ 268, Body Grayscale 9, ?, Grayscale 9
271
+ 269, Body Green, ?, Green
272
+ 270, Body Gunk, ?, Gunk
273
+ 271, Body Hot Brown, ?, Hot Brown
274
+ 272, Body Magenta, ?, Magenta
275
+ 273, Body Orange Yellow, ?, Orange Yellow
276
+ 274, Body Orange, ?, Orange
277
+ 275, Body Peachy A, ?, Peachy A
278
+ 276, Body Peachy B, ?, Peachy B
279
+ 277, Body Purple, ?, Purple
280
+ 278, Body Red, ?, Red
281
+ 279, Body Red Pinkish, ?, Red Pinkish
282
+ 280, Body Rust, ?, Rust
283
+ 281, Body Slime Green, ?, Slime Green
284
+ 282, Body Teal Light, ?, Teal Light
285
+ 283, Body Teal, ?, Teal
286
+ 284, Body Yellow, ?, Yellow
287
+ 285, Body Gradient Checker Disco, ?, Gradient Checker Disco
288
+ 286, Body Gradient Dawn, ?, Gradient Dawn
289
+ 287, Body Gradient Dusk, ?, Gradient Dusk
290
+ 288, Body Gradient Glacier, ?, Gradient Glacier
291
+ 289, Body Gradient Ice, ?, Gradient Ice
292
+ 290, Body Gradient Pride, ?, Gradient Pride
293
+ 291, Body Gradient Red Pink, ?, Gradient Red Pink
294
+ 292, Body Gradient Sunset, ?, Gradient Sunset
295
+ 293, oldshirt, ?,
296
+ 294, decay-gray-dark, ?,
297
+ 295, decay-pride, ?,
298
+ 296, checker-bigwalk-blue-prime, ?,
299
+ 297, checker-bigwalk-greylight, ?,
300
+ 298, checker-bigwalk-rainbow, ?,
301
+ 299, checker-rgb, ?,
302
+ 300, checker-spaced-black, ?,
303
+ 301, checker-spaced-white, ?,
304
+ 302, checker-vibrant, ?,
305
+ 303, checkers-big-green, ?,
306
+ 304, checkers-big-red-cold, ?,
307
+ 305, checkers-black, ?,
308
+ 306, checkers-blue, ?,
309
+ 307, checkers-magenta-80, ?,
310
+ 308, stripes-and-checks, ?,
311
+ 309, stripes-big-red, ?,
312
+ 310, stripes-blit, ?,
313
+ 311, stripes-blue-med, ?,
314
+ 312, stripes-brown, ?,
315
+ 313, stripes-olive, ?,
316
+ 314, stripes-red-cold, ?,
317
+ 315, woolweave-bicolor, ?,
318
+ 316, woolweave-dirt, ?,
319
+ 317, lines-45-greens, ?,
320
+ 318, lines-45-rose, ?,
321
+ 319, 1n, ?,
322
+ 320, aardvark, ?,
323
+ 321, axe, ?,
324
+ 322, belly-chameleon, ?,
325
+ 323, bird-flying, ?,
326
+ 324, bird-side, ?,
327
+ 325, bling-anchor, ?,
328
+ 326, bling-anvil, ?,
329
+ 327, bling-arrow, ?,
330
+ 328, bling-cheese, ?,
331
+ 329, bling-gold-ingot, ?,
332
+ 330, bling-love, ?,
333
+ 331, bling-mask, ?,
334
+ 332, bling-rings, ?,
335
+ 333, bling-scissors, ?,
336
+ 334, bling-sparkles, ?,
337
+ 335, carrot, ?,
338
+ 336, chain-logo, ?,
339
+ 337, chicken, ?,
340
+ 338, cloud, ?,
341
+ 339, clover, ?,
342
+ 340, collar-sunset, ?,
343
+ 341, cow, ?,
344
+ 342, dinosaur, ?,
345
+ 343, dollar-bling, ?,
346
+ 344, dragon, ?,
347
+ 345, ducky, ?,
348
+ 346, eth, ?,
349
+ 347, eye, ?,
350
+ 348, flash, ?,
351
+ 349, fries, ?,
352
+ 350, glasses-logo-sun, ?,
353
+ 351, glasses-logo, ?,
354
+ 352, glasses, ?,
355
+ 353, grid-simple-bege, ?,
356
+ 354, heart, ?,
357
+ 355, hoodiestrings-uneven, ?,
358
+ 356, id, ?,
359
+ 357, infinity, ?,
360
+ 358, insignia, ?,
361
+ 359, leaf, ?,
362
+ 360, lightbulb, ?,
363
+ 361, lp, ?,
364
+ 362, marsface, ?,
365
+ 363, matrix-white, ?,
366
+ 364, moon-block, ?,
367
+ 365, pizza-bling, ?,
368
+ 366, pocket-pencil, ?,
369
+ 367, rain, ?,
370
+ 368, rainbow-steps, ?,
371
+ 369, rgb, ?,
372
+ 370, robot, ?,
373
+ 371, safety-vest, ?,
374
+ 372, scarf-clown, ?,
375
+ 373, secret-x, ?,
376
+ 374, shirt-black, ?,
377
+ 375, shrimp, ?,
378
+ 376, slimesplat, ?,
379
+ 377, small-bling, ?,
380
+ 378, snowflake, ?,
381
+ 379, stains-blood, ?,
382
+ 380, stains-zombie, ?,
383
+ 381, sunset, ?,
384
+ 382, taxi-checkers, ?,
385
+ 383, tee-yo, ?,
386
+ 384, text-yolo, ?,
387
+ 385, think, ?,
388
+ 386, tie-black-on-white, ?,
389
+ 387, tie-dye, ?,
390
+ 388, tie-purple-on-white, ?,
391
+ 389, tie-red, ?,
392
+ 390, txt-a2+b2, ?,
393
+ 391, txt-cc, ?,
394
+ 392, txt-cc2, ?,
395
+ 393, txt-copy, ?,
396
+ 394, txt-dao-black, ?,
397
+ 395, txt-doom, ?,
398
+ 396, txt-dope-text, ?,
399
+ 397, txt-foo-black, ?,
400
+ 398, txt-ico, ?,
401
+ 399, txt-io, ?,
402
+ 400, txt-lmao, ?,
403
+ 401, txt-lol, ?,
404
+ 402, txt-mint, ?,
405
+ 403, txt-nil-grey-dark, ?,
406
+ 404, txt-noun-f0f, ?,
407
+ 405, txt-noun-green, ?,
408
+ 406, txt-noun-multicolor, ?,
409
+ 407, txt-noun, ?,
410
+ 408, txt-pi, ?,
411
+ 409, txt-pop, ?,
412
+ 410, txt-rofl, ?,
413
+ 411, txt-we, ?,
414
+ 412, txt-yay, ?,
415
+ 413, wall, ?,
416
+ 414, wave, ?,
417
+ 415, wet-money, ?,
418
+ 416, yingyang, ?,
Binary file
@@ -0,0 +1,23 @@
1
+
2
+
3
+ module Nouns
4
+
5
+ MAJOR = 0
6
+ MINOR = 1
7
+ PATCH = 0
8
+ VERSION = [MAJOR,MINOR,PATCH].join('.')
9
+
10
+ def self.version
11
+ VERSION
12
+ end
13
+
14
+ def self.banner
15
+ "nouns/#{VERSION} on Ruby #{RUBY_VERSION} (#{RUBY_RELEASE_DATE}) [#{RUBY_PLATFORM}] in (#{root})"
16
+ end
17
+
18
+ def self.root
19
+ File.expand_path( File.dirname(File.dirname(File.dirname(__FILE__))) )
20
+ end
21
+
22
+ end # module Nouns
23
+
data/lib/nouns.rb ADDED
@@ -0,0 +1,65 @@
1
+ ## 3rd party
2
+ require 'pixelart/base'
3
+
4
+
5
+
6
+ ## our own code
7
+ require 'nouns/version' # note: let version always go first
8
+
9
+
10
+ ## forward define superclass for image
11
+ module Nouns
12
+ class Image < Pixelart::Image; end
13
+ end
14
+
15
+
16
+ ###
17
+ ## add convenience pre-configurated generatored with build-in spritesheet (see config)
18
+
19
+ module Nouns
20
+
21
+ def self.generator
22
+ @generator ||= Pixelart::Generator.new( "#{root}/config/spritesheet.png",
23
+ "#{root}/config/spritesheet.csv",
24
+ width: 32,
25
+ height: 32 )
26
+ end
27
+
28
+
29
+ class Image
30
+ def self.generate( *values, background: nil )
31
+ img = Nouns.generator.generate( *values, background: background )
32
+ ## note: unwrap inner image before passing on to c'tor (requires ChunkyPNG image for now)
33
+ new( 32, 32, img.image )
34
+ end # method Image.generate
35
+ end # class Image
36
+
37
+
38
+ class Spritesheet
39
+ ## note: for now class used for "namespace" only
40
+ def self.find_by( name: ) ## return archetype/attribute image by name
41
+ # note: pass along name as q (query string)
42
+ Nouns.generator.find( name )
43
+ end
44
+ end # class Spritesheet
45
+ ## add convenience (alternate spelling) alias - why? why not?
46
+ SpriteSheet = Spritesheet
47
+ Sheet = Spritesheet
48
+ Sprite = Spritesheet
49
+ end # module Nouns
50
+
51
+
52
+ ### add some convenience shortcuts
53
+ ## add singular too -why? why not?
54
+ Noun = Nouns
55
+
56
+
57
+
58
+
59
+ ###
60
+ # note: for convenience auto include Pixelart namespace!!! - why? why not?
61
+ include Pixelart
62
+
63
+
64
+
65
+ puts Nouns.banner # say hello
metadata ADDED
@@ -0,0 +1,107 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: nouns
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Gerald Bauer
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2022-05-20 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: pixelart
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 1.3.1
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: 1.3.1
27
+ - !ruby/object:Gem::Dependency
28
+ name: rdoc
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '4.0'
34
+ - - "<"
35
+ - !ruby/object:Gem::Version
36
+ version: '7'
37
+ type: :development
38
+ prerelease: false
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: '4.0'
44
+ - - "<"
45
+ - !ruby/object:Gem::Version
46
+ version: '7'
47
+ - !ruby/object:Gem::Dependency
48
+ name: hoe
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '3.23'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - "~>"
59
+ - !ruby/object:Gem::Version
60
+ version: '3.23'
61
+ description: nouns - generate your own 32×32 pixel avatar images (off chain) from
62
+ text attributes (via built-in spritesheet); incl. 2x/4x/8x zoom for bigger sizes
63
+ and more
64
+ email: wwwmake@googlegroups.com
65
+ executables: []
66
+ extensions: []
67
+ extra_rdoc_files:
68
+ - CHANGELOG.md
69
+ - Manifest.txt
70
+ - README.md
71
+ files:
72
+ - CHANGELOG.md
73
+ - Manifest.txt
74
+ - README.md
75
+ - Rakefile
76
+ - config/spritesheet.csv
77
+ - config/spritesheet.png
78
+ - lib/nouns.rb
79
+ - lib/nouns/version.rb
80
+ homepage: https://github.com/pixelartexchange/pixelart
81
+ licenses:
82
+ - Public Domain
83
+ metadata: {}
84
+ post_install_message:
85
+ rdoc_options:
86
+ - "--main"
87
+ - README.md
88
+ require_paths:
89
+ - lib
90
+ required_ruby_version: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - ">="
93
+ - !ruby/object:Gem::Version
94
+ version: '2.3'
95
+ required_rubygems_version: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - ">="
98
+ - !ruby/object:Gem::Version
99
+ version: '0'
100
+ requirements: []
101
+ rubygems_version: 3.3.7
102
+ signing_key:
103
+ specification_version: 4
104
+ summary: nouns - generate your own 32×32 pixel avatar images (off chain) from text
105
+ attributes (via built-in spritesheet); incl. 2x/4x/8x zoom for bigger sizes and
106
+ more
107
+ test_files: []