Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Classical Ray Tracing
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
yumcyawiz
June 03, 2018
Programming
770
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Classical Ray Tracing
yumcyawiz
June 03, 2018
More Decks by yumcyawiz
See All by yumcyawiz
rtcamp 10 (vk-illuminati)
yumcyawiz
1
560
ReSTIRの数理と実装 (rtcamp10)
yumcyawiz
1
2k
fredholm(rtcamp9)
yumcyawiz
0
180
フォトンマッピングをパス空間から考える
yumcyawiz
0
560
fredholm
yumcyawiz
0
360
Introduction to volume rendering
yumcyawiz
0
2.8k
OSK#p-ray2020年度講義: 古典的レイトレーサーの実装
yumcyawiz
0
310
Ray Tracing: Overview
yumcyawiz
7
1.4k
GLSLでパストレーシングしてコーネルボックスを出す
yumcyawiz
0
640
Other Decks in Programming
See All in Programming
C#の現在地 進化の歴史と、AI時代の.NET Everywhere
neuecc
5
4.3k
JRuby: Past, Present, and Future
headius
0
210
Webの地図
yosuke_furukawa
PRO
6
4.9k
UPDATE をやめる — EF Core でマスタをバージョン管理する
panda728
PRO
0
970
速習iPhone Duo対応
yuukiw00w
2
870
【高い買い物LT会】初任給で話題の国産フィジカルAIを買った話
akagami
PRO
0
170
スマート反転とウェブアクセシビリティ
camiha
0
220
IBM Bob Dojo #1 仕様駆動開発入門
oniak3ibm
PRO
0
310
20260914 AIエージェント時代のPlatform Engineering LLM基盤とプロダクトの責務境界線
kanfab1
7
2.3k
App Intentsのビルドプロセスを支える技術
kntkymt
0
470
setup-vp GitLab対応の裏側
naokihaba
0
140
Everything will be SERVERLESS — 信じて運用した10年の経験値 / Everything Will be Serverless — Lessons Learned from 10 Years of Operational Experience
seike460
PRO
1
560
Featured
See All Featured
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.6k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Context Engineering - Making Every Token Count
addyosmani
9
1.2k
A Soul's Torment
seathinner
8
3.7k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2.2k
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
600
Product Roadmaps are Hard
iamctodd
55
13k
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Code Reviewing Like a Champion
maltzj
528
40k
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Transcript
RAY TRACING 古典的レイトレーサーからはじめるレイトレーシング
古典的レイトレーシング(CLASSICAL RAY TRACING) • コンピューターグラフィクス黎明期に流行ったもの
古典的レイトレーシング(CLASSICAL RAY TRACING) • コンピューターグラフィクス黎明期に流行ったもの • 物理的に正しくはないが、陰影計算ができる
None
CG感半端ないけどちゃんと影ついてる
古典的レイトレーシング(CLASSICAL RAY TRACING) • コンピューターグラフィクス黎明期に流行ったもの • 物理的に正しくはないが、陰影計算ができる • はじめてのレイトレに最適
古典的レイトレーシング(CLASSICAL RAY TRACING) • コンピューターグラフィクス黎明期に流行ったもの • 物理的に正しくはないが、陰影計算ができる • はじめてのレイトレに最適 これからみんなに作ってもらいます
CLASSICAL RAY TRACER構造図
VEC3クラス • 3次元ベクトルを表すクラス • 四則演算、内積、外積なども定義されている Ԧ +
RAYクラス • Rayを表す Ԧ Ԧ Ԧ + Ԧ
HITクラス • 衝突情報を格納するクラス • 衝突距離、衝突位置、法線などの情報を持つ Sphere Ray
IMAGEクラス • 画像データを格納し、PPM画像として出力する機能を持つ • 指定した画素に色を書き込む機能を持つ
(, ) 画像の座標系(10*8の場合) (0, 0) (10, 8) 10 8
CAMERAクラス • 画素 , に対応するRayを返す機能を持つ (, ) Ray
ピンホールカメラ ピンホール カメラセンサー
SHAPEクラス • 物体の形を表すクラス • 与えられたRayとの衝突計算を行う Sphere Ray
MATERIALクラス • 物体の材質を表すクラス • Diffuse(マットな面), Mirror(鏡面), Glass(ガラス)の3つを用意する • 受け取ったRayを反射させる機能を持つ Sphere
Ray
PRIMITIVEクラス • ShapeとMaterialをデータとして持つクラス • シーンの中の物体はすべてPrimitiveで記述される
ACCELクラス • 物体集合を管理するクラス • すべての物体と衝突計算を行う機能を持つ
ray = cam->getRay(i, j) accel->intersect(ray, hit) hitの中身によって画素に色を書き 込む Ray Tracingの流れ