Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/phuang1024/fractalstudio
Cuda accelerated realtime fractal rendering.
https://github.com/phuang1024/fractalstudio
Last synced: about 2 months ago
JSON representation
Cuda accelerated realtime fractal rendering.
- Host: GitHub
- URL: https://github.com/phuang1024/fractalstudio
- Owner: phuang1024
- License: gpl-3.0
- Created: 2021-10-17T21:35:02.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2024-03-09T04:05:05.000Z (10 months ago)
- Last Synced: 2024-03-09T21:36:14.581Z (10 months ago)
- Language: Python
- Homepage:
- Size: 7.9 MB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# FractalStudio
![](https://github.com/phuang1024/FractalStudio/blob/master/gallery/ViewerBuddhabrot.jpg?raw=true)
Cuda accelerated fractal rendering.
[Gallery](https://github.com/phuang1024/FractalStudio/tree/master/gallery)
## Viewer
The viewer is an interactive GUI fractal renderer.
The viewer uses PyTorch cuda vector code to render fractals efficiently with
only python.```bash
cd ./viewerpython main.py viewer --alg mandelbrot
python main.py viewer --alg buddhabrot
python main.py viewer --alg nebulabrot
```## Renderer
This uses native C and Cuda code to render fractals. It is designed to export
high quality images, but also includes a live viewer for the mandelbrot.This is faster than the `viewer`, but is harder to use.
This is the first version of this project, which can still be found on the `old`
branch.### `render/mandelbrot/`
Realtime visualization of the mandelbrot set.
```bash
cd ./render/mandelbrot# If you have a CUDA gpu
make cuda
# or use cpu
make cpu# generate image
python main.py image --width 4096 --height 4096# use pygame interactively
python main.py live --width 1280 --height 720# change kernels
python main.py --kernel cpu
```**Options** to `main.py`:
- `mode`: `image` or `live`.
- `--kernel`: `cpu` or `cuda` to set computing kernel. GPU is usually faster.
- `--width`: Width of viewing window or generated image.
- `--height`: Height
- `--max-iters`: Max iters to simulate function. More iters is slower but more accurate.### `render/buddhabrot/`
Render the [buddhabrot](https://en.wikipedia.org/wiki/Buddhabrot) or nebulabrot.
```bash
cd ./render/buddhabrotmake cpu
# generate buddhabrot
# Args are [iters] [samples]
./a.out 1000 10000000
python convert.py out.img buddhabrot.png# generate nebulabrot
# calls a.out, convert.py, nebula.py many times and compiles the final image.
./nebula.sh
```