https://github.com/ubpa/raytracinginoneweekend
rewrite Ray Tracing in a Weekend
https://github.com/ubpa/raytracinginoneweekend
Last synced: about 1 year ago
JSON representation
rewrite Ray Tracing in a Weekend
- Host: GitHub
- URL: https://github.com/ubpa/raytracinginoneweekend
- Owner: Ubpa
- License: mit
- Created: 2019-06-03T15:32:52.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-06-13T14:14:36.000Z (about 7 years ago)
- Last Synced: 2025-03-24T20:38:14.814Z (over 1 year ago)
- Language: C++
- Size: 301 KB
- Stars: 17
- Watchers: 4
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Ray Tracing in One Weekend

## 简介
本项目是对 [Ray Tracing in One Weekend](http://www.realtimerendering.com/raytracing/Ray%20Tracing%20in%20a%20Weekend.pdf) 的重构。
笔记为 [notes](notes.md)
因为 GitHub 不支持公式,推荐用 [Typora](https://www.typora.io/) 查看 md 文件。
程序生成的图片格式为 PPM,可用[格式工厂](http://www.pcfreetime.com/formatfactory/CN/index.html)将其转换为 PNG 格式后再查看。
## 环境
### Windows
- VS 2017
- [CMake](https://cmake.org/) 3.1 以上
### Linux
- C++11
- [CMake](https://cmake.org/) 3.1 以上
## 安装
### Windows
搭建工程
```bash
mkdir build
cd build
cmake ..
start RayTracingInOneWeekend.sln
```
或者直接运行 `setup.bat`
打开 VS 后
在解决方案中,右键 `CMakePredefinedTargets/INSTALL`,点击“生成”,各种 exe 就会安装在 `bin/` 中了。
### Linux
```shell
mkdir build
cd build
cmake ..
make
make install
```
这样所有的程序都在 `bin/` 中,执行这些程序,输出结果在 `data/` 中