Skip to content

Commit

Permalink
Update legal text and requirements.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinjycui committed Apr 21, 2023
1 parent 4a5c97c commit 6bf52e5
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 25 deletions.
39 changes: 30 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ A simple image/video to Desmos graph converter run locally. Rotoscopes images us
![](github/figures.png)

## Setup
#### This guide won't work out of the box on Windows. The easiest way to do this on Windows is to [download WSL](https://www.microsoft.com/store/productId/9N6SVWS3RX71) to run all the commands below. You can find it produces under the `\\wsl$\Ubuntu-20.04\home` path on your PC.
#### This guide won't work out of the box on Windows. The easiest way to do this on Windows is to [install WSL](https://learn.microsoft.com/en-us/windows/wsl/install) to run all the commands below. You can find it produces under the `\\wsl$\Ubuntu-20.04\home` path on your PC.
Install dependencies
```sh
sudo apt update
Expand All @@ -20,9 +20,10 @@ cd DesmosBezierRenderer

Install requirements
```sh
python3 -m venv env
python -m venv env
. env/bin/activate
pip3 install -r requirements.txt
pip install wheel
pip install -r requirements.txt
```
Replace the images in the `frames` directory with your own and name each image `frame%d.png` where `%d` represents the frame-number starting from 1. To render just a single image, add a single image named `frame1.png` in the directory. Works best with 360p to 480p resolution (may have to lower the resolution further with more complex frames).
```sh
Expand Down Expand Up @@ -57,21 +58,36 @@ backend.py -f <source> -e <extension> -c <colour> -b -d -l -g --static --block=<
You can use the optimisational options to change the number of expressions the backend will send to the frontend per call (too much will cause a memory error, too little could kill the backend with too many requests). Note that a "block" refers to what is passed from the backend to the frontend per HTTP request. These only really matter if you are rendering a video.
Use `python3 backend.py -h` to see the above help message. Run without any command-line arguments to create a rendering with the same settings as seen in [this video](https://www.youtube.com/watch?v=BQvBq3K50u8).
Use `python backend.py -h` to see the above help message. Run without any command-line arguments to create a rendering with the same settings as seen in [this video](https://www.youtube.com/watch?v=BQvBq3K50u8).
#### Running the command
Run backend (This may take a while depending on the size and complexity of the frames). It should eventually show that the server is running on `localhost:5000`.
```sh
python3 backend.py
python backend.py
```
The following is an example of the output
```sh
$ python3 backend.py
Desmos Bezier Renderer
$ python backend.py
_____
| __ \
| | | | ___ ___ _ __ ___ ___ ___
| | | |/ _ \/ __| '_ ` _ \ / _ \/ __|
| |__| | __/\__ \ | | | | | (_) \__ \
|_____/ \___||___/_| |_| |_|\___/|___/
BEZIER RENDERER
Junferno 2021
https://github.com/kevinjycui/DesmosBezierRenderer
= COPYRIGHT =
©Copyright Junferno 2021-2023. This program is licensed under the [GNU General Public License](https://github.com/kevinjycui/DesmosBezierRenderer/blob/master/LICENSE). Please provide proper credit to the author (Junferno) in any public media that uses this software.
= EULA =
By using Desmos Bezier Renderer, you agree to comply to the [Desmos Terms of Service](https://www.desmos.com/terms). The Software and related documentation are provided “AS IS” and without any warranty of any kind. Desmos Bezier Renderer is not responsible for any User application or modification that constitutes a breach in terms. User acknowledges and agrees that the use of the Software is at the User's sole risk. Desmos Bezier Renderer is in no way, shape, or form endorsed by or associated with Desmos, Inc. The developer kindly asks Users to not use Desmos Bezier Renderer to enter into Desmos Math Art competitions, for the purpose of maintaining fairness and integrity.
Agree (y/n)? y
-----------------------------
Processing 513 frames... Please wait for processing to finish before running on frontend
Expand All @@ -92,6 +108,11 @@ Alternatively, you can load `quick.html` for a **quicker rendering** with **more
![](github/final.png)
## Attribution
## Copyright
©Copyright Junferno 2021. This program is licensed under the GNU General Public License. Please provide proper credit to the author (Junferno) in any public media that uses this software.
©Copyright Junferno 2021-2023. This program is licensed under the [GNU General Public License](https://github.com/kevinjycui/DesmosBezierRenderer/blob/master/LICENSE). Please provide proper credit to the author (Junferno) in any public media that uses this software.
## EULA
```
By using Desmos Bezier Renderer, you agree to comply to the [Desmos Terms of Service](https://www.desmos.com/terms). The Software and related documentation are provided “AS IS” and without any warranty of any kind. Desmos Bezier Renderer is not responsible for any User application or modification that constitutes a breach in terms. User acknowledges and agrees that the use of the Software is at the User's sole risk. Desmos Bezier Renderer is in no way, shape, or form endorsed by or associated with Desmos, Inc. The developer kindly asks Users to not use Desmos Bezier Renderer to enter into Desmos Math Art competitions, for the purpose of maintaining fairness and integrity.
```
24 changes: 23 additions & 1 deletion backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,32 @@ def init():
sys.exit(2)

with multiprocessing.Pool(processes = multiprocessing.cpu_count()) as pool:
print('Desmos Bezier Renderer')
print(''' _____
| __ \
| | | | ___ ___ _ __ ___ ___ ___
| | | |/ _ \/ __| '_ ` _ \ / _ \/ __|
| |__| | __/\__ \ | | | | | (_) \__ \\
|_____/ \___||___/_| |_| |_|\___/|___/
''')
print(' BEZIER RENDERER')
print('Junferno 2021')
print('https://github.com/kevinjycui/DesmosBezierRenderer')

print('''
= COPYRIGHT =
©Copyright Junferno 2021-2023. This program is licensed under the [GNU General Public License](https://github.com/kevinjycui/DesmosBezierRenderer/blob/master/LICENSE). Please provide proper credit to the author (Junferno) in any public media that uses this software.
= EULA =
By using Desmos Bezier Renderer, you agree to comply to the [Desmos Terms of Service](https://www.desmos.com/terms). The Software and related documentation are provided “AS IS” and without any warranty of any kind. Desmos Bezier Renderer is not responsible for any User application or modification that constitutes a breach in terms. User acknowledges and agrees that the use of the Software is at the User's sole risk. Desmos Bezier Renderer is in no way, shape, or form endorsed by or associated with Desmos, Inc. The developer kindly asks Users to not use Desmos Bezier Renderer to enter into Desmos Math Art competitions, for the purpose of maintaining fairness and integrity.
''')

eula = ''

while eula != 'y':
eula = input(' Agree (y/n)? ')
if eula == 'n':
quit()

print('-----------------------------')

print('Processing %d frames... Please wait for processing to finish before running on frontend\n' % len(os.listdir(FRAME_DIR)))
Expand Down
20 changes: 5 additions & 15 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
click==7.1.2
cycler==0.10.0
Flask==1.1.2
Flask-Cors==3.0.10
itsdangerous==1.1.0
Jinja2==2.11.3
kiwisolver==1.3.1
MarkupSafe==1.1.1
matplotlib==3.4.1
Flask==2.1.0
Flask_Cors==3.0.10
numpy==1.23.0
opencv-python==4.5.1.48
Pillow==9.0.1
pyparsing==2.4.7
opencv_contrib_python==4.6.0.66
opencv_python_headless==4.6.0.66
Pillow==9.5.0
pypotrace==0.3
python-dateutil==2.8.1
six==1.15.0
Werkzeug==1.0.1

0 comments on commit 6bf52e5

Please sign in to comment.