Inspiration
We were inspired by modern and abstract artwork, which uses color theory to define the meaning of the paintings rather than the conventional tangible objects.
We were also inspired to work with analogous colors from this Adobe Color Wheel website: https://color.adobe.com/create/color-wheel
What it does
The art generator creates a beautiful piece of art by placing randomized shapes to fill the entire screen. You can choose from 3 preset palettes - vintage, pastel, and sunset - or choose a random palette, which will select a random color and calculate a handful of analogous colors to be used alongside it. You can also choose how many shapes you would like to be drawn and the scaling factor for each shape.
If you like your creation, you can save it to your computer as a png image by clicking anywhere on the screen!
How we built it
This was built with the Python language using the Tkinter and turtle libraries.
- Tkinter for user input
- Turtle for drawing the shapes
Challenges we ran into
We realized that using the normal RGB color values would make finding analogous colors very difficult (we would have had to implement polar coordinate math). To overcome this, we learned how to use HSV colors instead. I spent an hour trying to convert a .ps file to a .png image for the image saving functionality. (if anyone has the same issue, save yourself the pain and use Wand: https://docs.wand-py.org/en/0.4.5/guide/write.html#save-to-file)
Accomplishments that we're proud of
The random color palette effectively generates good looking palettes based on analogous colors. I really liked how we were able to use color theory so well, especially since the theme of this hackathon was "art". Using the HSV color system allowed us to precisely rotate 15 degrees around the color circle to select the next analogous color and calculate the perfect color palette around any color.
I was very proud to be able to figure out how to finally convert a .ps file to a .png image and allow the user to save it anywhere on their computer.
What we learned
- How to use Tkinter for user input and turtle for creating art.
- The HVS color system and its benefits over the classical RGB system
- Basic color theory and how to create nice looking color palettes with analogous colors
- How to convert a .ps file into a .png image (yes I'm bringing that up again, it was traumatic)
What's next for Abstract Art Generator
Some ideas for the future:
- Add a color wheel or some other form of color picking system for more customization
- Add options to use tertiary and complementary color palettes instead of just analogous
- Move the entire project over to Flask so that we can deploy it to the web
Built With
- python
- tkinter
- turtle

Log in or sign up for Devpost to join the conversation.