https://github.com/xyproto/realtimeraytracing
Realtime raytracing on the CPU, using OpenMP, SDL2 and C++, on the CPU
https://github.com/xyproto/realtimeraytracing
c-plus-plus cmake joypad lowres openmp raytracer raytracing sdl2
Last synced: 5 months ago
JSON representation
Realtime raytracing on the CPU, using OpenMP, SDL2 and C++, on the CPU
- Host: GitHub
- URL: https://github.com/xyproto/realtimeraytracing
- Owner: xyproto
- License: mit
- Created: 2020-12-13T14:20:13.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2025-01-18T20:57:50.000Z (9 months ago)
- Last Synced: 2025-01-29T06:44:17.226Z (9 months ago)
- Topics: c-plus-plus, cmake, joypad, lowres, openmp, raytracer, raytracing, sdl2
- Language: C++
- Homepage:
- Size: 141 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Realtime Raytracing
An experiment with C++, SDL2 and OpenMP-based realtime raytracing on the CPU.
* Move a sphere using either the arrow keys or `w`, `a`, `s`, `d`.
* Switch to the next sphere with `space` or `tab`.
* Toggle fullscreen with `f` or `f11`.
* Quit with `q` or `esc`.
* You can also move the current sphere with a joystick, then press a key to select the next one.## Requirements
* SDL2 (`sdl2` and optionally `sdl2_image`, `sdl2_mixer`, `sdl2_ttf`, `sdl2_net` and `sdl2_sound`)
* OpenMP (`libomp`)
* CMake (`cmake`)
* GNU Make (`make`)## Screenshot

## Building
make
## Running
make run
Tested on Arch Linux and macOS.
The spheres can be moved around with a joystick / joypad.
Written with the [Orbiton](https://github.com/xyproto/orbiton) editor.
## General info
* Version: 0.1.0
* Author: Alexander F. Rødseth <xyproto@archlinux.org>
* License: MIT