This is lovely. When I see this, I don't think 'patterns', rather, 'hatches'.
Makes me wonder what the state of modern SVG is w.r.t. real-world units - something like this really makes SVG look useful for for technical drawing, but pixels are not the best unit to draw to...
An initial config object would probably be ideal, and then you could have the chaining to supplement those values. You could have the initial method take in the config and use the values in that in place of the defaults. So
Aren’t these textures already reusable? The constructed texture object (the result of textures.lines(), e.g.) can be called on as many selections as you like to reuse it.
I feel it’s a matter of taste, but one practical reason I prefer chaining to configuration objects is that you get a runtime error when you misspell a property, rather than it being silently ignored.
This is pretty cool. I made a really basic example, but in doing it, I could imagine playing around with having the colors or orientation change with the data as well. And it might make for cool transitions too. That obviously get way too complicated pretty quickly, but it'd be fun to see what you could come up with that might work.
Comments (61) 30 threads
Makes me wonder what the state of modern SVG is w.r.t. real-world units - something like this really makes SVG look useful for for technical drawing, but pixels are not the best unit to draw to...
I feel it’s a matter of taste, but one practical reason I prefer chaining to configuration objects is that you get a runtime error when you misspell a property, rather than it being silently ignored.
Also, use of the "new" keyword is contentious. You can hardly pretend that it is best practice.
I encountered the same issue in my project : 2 levels of polygon-distinguishment. Made a set of 1 bit seamless textures.
http://glowinggreenhand.blogspot.com/2014/01/i-made-bunch-of...
https://modeanalytics.com/benn/reports/a4515d9b9024
All comments shown.
Couldn't load more comments. Check your connection and try again.