An open API service indexing awesome lists of open source software.

https://github.com/marfullsen/draw-a-circle

Just drawing a circle with Python and Pillow library.
https://github.com/marfullsen/draw-a-circle

Last synced: over 1 year ago
JSON representation

Just drawing a circle with Python and Pillow library.

Awesome Lists containing this project

README

          

# Draw a circle
[![Python3](https://img.shields.io/badge/Python-3.7-green.svg)](https://www.python.org/)
[![Pillow](https://img.shields.io/badge/Pillow-8.0.0-blue.svg)](https://pypi.org/project/Pillow/)

[![Screenshot](./screenshot-01.png)](https://github.com/Marfullsen/)

## Desc
Just drawing a simple circle with Python using [PIL](https://pypi.org/project/Pillow/) library, the docs are [here](https://pillow.readthedocs.io/en/stable/).
Also provides function to draw multiple circles.

## Install Dependencies & Usage
1. Install `git`.
2. Clone, enter the directory.
```
git clone https://github.com/Marfullsen/draw-a-circle.git
cd draw-a-circle
```
3. Install dependencies.
```
pip install Pillow
```
or
```
python3 -m pip install Pillow
```
or´
```
sudo apt-get install python-pil
```
or
```
sudo pip install pillow
```
or
```
sudo easy_install pillow
```
4. Open with Python3
```
python draw_a_circle.py
```
5. Enjoy!
PD: the image canvas is always 200 X 200
## Examples

[![Screenshot](./screenshot-02.png)](https://github.com/Marfullsen/)

[![Screenshot](./screenshot-03.png)](https://github.com/Marfullsen/)

## Credit
I just transcoded [this](https://stackoverflow.com/a/58629898) answer on StackOverflow written with Java.