Skip to content

Commit

Permalink
Merge pull request #15 from serhii-rieznik/dev
Browse files Browse the repository at this point in the history
dev -> main
  • Loading branch information
serhii-rieznik authored Sep 26, 2023
2 parents 1fee671 + 0a5a824 commit 8487705
Show file tree
Hide file tree
Showing 260 changed files with 713,114 additions and 854,530 deletions.
8 changes: 5 additions & 3 deletions .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ Language: Cpp
# BasedOnStyle: Google
AccessModifierOffset: -1
AlignAfterOpenBracket: DontAlign
AlignConsecutiveMacros: false
AlignConsecutiveBitFields: true
AlignConsecutiveMacros: true
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: Left
Expand Down Expand Up @@ -77,7 +78,7 @@ IncludeCategories:
Priority: 3
IncludeIsMainRegex: '([-_](test|unittest))?$'
IndentCaseLabels: true
IndentPPDirectives: None
IndentPPDirectives: AfterHash
IndentWidth: 2
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
Expand All @@ -100,6 +101,7 @@ PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Left
PPIndentWidth: 1
RawStringFormats:
- Language: Cpp
Delimiters:
Expand Down Expand Up @@ -232,7 +234,7 @@ IncludeCategories:
Priority: 3
IncludeIsMainRegex: '([-_](test|unittest))?$'
IndentCaseLabels: true
IndentPPDirectives: None
IndentPPDirectives: AfterHash
IndentWidth: 2
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ bin/options.json
*.ptx
*.fatbin
bin/ui.ini
bin/raytracer

5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ if (MSVC)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /MP")
endif()

if (APPLE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-deprecated")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-deprecated")
endif()

set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake")
add_definitions(-D_CRT_SECURE_NO_WARNINGS)

Expand Down
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ Physically-based ray-tracer.
- directional emitter with finite angluar size
- collimated area lights (lasers)
* Spectral representation of material's properties (colors, index of refractions, etc)
* Subsurface scattering which could be applied to any material containing diffuse layer (diffuse, plastic, velvet)
* Thin-film rendering over most of materials (including conductor materials)
* Subsurface scattering:
- random walk;
- Christensen-Burley approximation;
- could be applied to any material containing diffuse layer (diffuse, plastic, velvet)
* Thin-film rendering over all materials (including conductors)
* Normal mapping
* Atmosphere integrator;

Expand Down
Binary file added bin/assets/cb-candle/cb-candle.blend
Binary file not shown.
11 changes: 11 additions & 0 deletions bin/assets/cb-candle/cb-candle.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"geometry" : "cb-candle.obj",
"materials" : "cb-candle.materials",
"camera" : {
"viewport" : [1080.0, 1080.0],
"origin" : [0.0, 1.0, 5.15],
"target" : [0.0, 1.0, 0.0],
"up" : [0.0, 1.0, 0.0],
"fov" : 26.99
}
}
51 changes: 51 additions & 0 deletions bin/assets/cb-candle/cb-candle.materials
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Blender 3.6.2 MTL File: 'cb-candle.blend1'
# www.blender.org

newmtl et::env
color nblackbody 20000.0 scale 2.0

newmtl et::medium
id wax
absorption 1 2.5 5
scattering 4 3 2

newmtl candle
material class diffuse
int_medium wax
subsurface class exact

newmtl diamond
material class dielectric
int_ior diamond

newmtl ceiling
material class diffuse
Kd 1 1 1

newmtl floor
material class diffuse
Kd 1 1 1
map_Kd ../textures/checkers_grayscale.png

newmtl frontWall
material class diffuse
Kd 1 1 1
map_Kd ../textures/checkers_grayscale.png

newmtl leftWall
material class diffuse
Kd 0.25 0.25 1.0

newmtl rightWall
material class diffuse
Kd 0.25 1 0.25

newmtl fire
material class translucent
Kd 1 1 1
Ks 1 1 1
Kt 1 1 1
emitter blackbody 2000.0 scale 1.0
Ke 1 1 1

newmtl wire
Loading

0 comments on commit 8487705

Please sign in to comment.