Mint yourself free CryptoPunks in the Black & White (Pencil Drawing) Sketch pixel art series.
Here's the experiment - let's turn 24x24 pixelated CryptoPunks into black & white sketch art.
How?
- Let's use a white background.
- Let's check if the left neighbouring (x-1) pixel is of a different color - if yes, draw a black vertical line.
- Let's check if the top neighbouring (y-1) pixel is of a different color - if yes, draw a black horizontal line.
- Repeat for all pixels.
Let's try alien punk #3100. Let's mint a fresh 24x24 copy.
require 'cryptopunks'
punks = Punks::Image::Composite.read( './punks.png' )
punk = punks[ 3100 ]
punk.save( './punk-3100.png' )
And let's try four sketch variants:
- Sketch Zoom - 4 pixels, Line (Brush) - 1 pixel (the default)
- Sketch Zoom - 4 pixels, Line (Brush) - 4 pixels
- Sketch Zoom - 8 pixels, Line (Brush) - 2 pixels
- Sketch Zoom - 12 pixels, Line (Brush) - 3 pixels
punk_sketch = punk.sketch( 4 )
punk_sketch.save( './punk-3100_sketch4x.png' )
punk_sketch = punk.sketch( 4, line: 4 )
punk_sketch.save( './punk-3100_sketch4x4.png' )
punk_sketch = punk.sketch( 8, line: 2 )
punk_sketch.save( './punk-3100_sketch8x2.png' )
punk_sketch = punk.sketch( 12, line: 3 )
punk_sketch.save( './punk-3100_sketch12x3.png' )
And Voila!
Let's try another batch of punks. Let's mint a fresh copy of zombie #3393, blondie #172 and beanie #2964.
ids = [3393, 172, 2964]
ids.each do |id|
name = '%04d' % id
punk = punks[id]
punk.save( "./punk-#{name}.png" )
end
And let's try four sketch variants:
- Sketch Zoom - 4 pixels, Line (Brush) - 1 pixel (the default)
- Sketch Zoom - 4 pixels, Line (Brush) - 4 pixels
- Sketch Zoom - 8 pixels, Line (Brush) - 2 pixels
- Sketch Zoom - 12 pixels, Line (Brush) - 3 pixels
Let's add inside the loop:
ids.each do |id|
# ... see above
punk_sketch = punk.sketch( 4 )
punk_sketch.save( "./punk-#{name}_sketch4x.png" )
punk_sketch = punk.sketch( 4, line: 4 )
punk_sketch.save( "./punk-#{name}_sketch4x4.png" )
punk_sketch = punk.sketch( 8, line: 2 )
punk_sketch.save( "./punk-#{name}_sketch8x2.png" )
punk_sketch = punk.sketch( 12, line: 3 )
punk_sketch.save( "./punk-#{name}_sketch12x3.png" )
end
And Voila!
Really not too bad for a first rough quick & dirty sketch experiment.
Ideas for future improvements:
- Use rounded corners for sketch lines?
- Use sketch lines off by 1 for for a neon "glowing" light effect?
- Your ideas here? Please, tell.
Post them on the CryptoPunksDev reddit. Thanks.