Created
July 15, 2017 20:58
-
-
Save ambuc/a901bf18fb034a5078a46f7cfe0738b5 to your computer and use it in GitHub Desktop.
Successive Rows of Horizontal, Straight Lines from Top to Bottom, and Vertical, Straight Lines from Left to Right, 1972
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Codec.Picture( PixelRGBA8( .. ), writePng ) | |
import Graphics.Rasterific | |
import Graphics.Rasterific.Texture | |
import Graphics.Rasterific.Transformations | |
import Data.List | |
refl = transform $ applyTransformation | |
Transformation { _transformA = 0.0, _transformC = 1.0, _transformE = 0.0, | |
_transformB = 1.0, _transformD = 0.0, _transformF = 0.0 | |
} | |
main = writePng "yourimage.png" | |
$ renderDrawing 750 750 (PixelRGBA8 255 255 255 255) | |
$ withTexture (uniformTexture (PixelRGBA8 0 0 0 255)) | |
$ stroke 1 JoinRound (CapRound, CapRound) | |
$ transform (applyTransformation $ translate (V2 47.5 47.5)) | |
$ (\xs -> xs ++ map refl xs) $ map (\(x,_) -> line (V2 0 x) (V2 655 x)) | |
$ filter snd $ zip [0,5..] | |
$ concatMap (\x -> take 12 $ drop x $ replicate 12 True ++ repeat False) | |
[10,9..0] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Output:
Inspired by:
More:
http://www.visible.org/site/cornish/slide_lectures/sol_le_witt/
http://vjeranski.tumblr.com/post/112892688148/sol-lewitt-successive-rows-of-horizontal-straight