Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CppRaytracer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yoel
CppRaytracer
Commits
8203eaec
Commit
8203eaec
authored
2 years ago
by
Yoel
Browse files
Options
Downloads
Patches
Plain Diff
refactor
parent
e3306d1b
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
RayTracer/Main.cpp
+5
-5
5 additions, 5 deletions
RayTracer/Main.cpp
with
5 additions
and
5 deletions
RayTracer/Main.cpp
+
5
−
5
View file @
8203eaec
...
...
@@ -35,7 +35,7 @@ using namespace shapes;
using
namespace
std
;
int
main
()
{
if
(
tru
e
)
{
if
(
fals
e
)
{
cout
<<
"Start"
<<
endl
;
// Image img = Image (100, 100);
...
...
@@ -77,7 +77,7 @@ int main() {
// group.add(ShapeSingleGroup(translate(Vec3(4, 0, -2)), green_sphere));
std
::
vector
<
std
::
shared_ptr
<
Light
>>
lights
=
{
skysphere
};
auto
sc
=
std
::
make_shared
<
Scene
>
(
Scene
(
group
,
lights
,
obs
,
8
));
auto
sc
=
std
::
make_shared
<
Scene
>
(
Scene
(
group
,
lights
,
obs
,
8
,
4
));
size_t
n
=
1
;
...
...
@@ -101,11 +101,11 @@ int main() {
}
else
{
std
::
ifstream
is
(
"Extended_Cube.obj"
);
TriangleMesh
mesh
(
is
,
nullptr
);
cout
<<
"triangles: "
<<
mesh
.
triangles
.
size
()
<<
endl
;
cout
<<
"leaves: "
<<
mesh
.
leaves
.
size
()
<<
endl
;
cout
<<
"hierarchy: "
<<
mesh
.
hierarchy
.
size
()
<<
endl
;
for
(
auto
hier
:
mesh
.
hierarchy
)
{
cout
<<
"{"
<<
hier
.
left
<<
" "
<<
hier
.
right
<<
" "
for
(
int
i
=
0
;
i
<
mesh
.
hierarchy
.
size
();
i
++
)
{
auto
hier
=
mesh
.
hierarchy
[
i
];
cout
<<
i
<<
". {"
<<
hier
.
left
<<
" "
<<
hier
.
right
<<
" "
<<
hier
.
leaves_i
<<
" "
<<
hier
.
leaves_size
<<
"}"
<<
endl
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment