Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
ProjectiveTextureMapping
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
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
WooHyungChoi
ProjectiveTextureMapping
Commits
604720f4
Commit
604720f4
authored
5 years ago
by
Woohyung Choi
Browse files
Options
Downloads
Patches
Plain Diff
씬 정리
parent
65a9c3f6
Branches
master
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
LearnOpenGL/Source.cpp
+9
-6
9 additions, 6 deletions
LearnOpenGL/Source.cpp
with
9 additions
and
6 deletions
LearnOpenGL/Source.cpp
+
9
−
6
View file @
604720f4
...
@@ -75,7 +75,9 @@ int main()
...
@@ -75,7 +75,9 @@ int main()
auto
defaultMaterial
=
new
Material
(
lightmap
,
orange
,
transparent
);
auto
defaultMaterial
=
new
Material
(
lightmap
,
orange
,
transparent
);
auto
cubeMaterial
=
new
Material
(
lightmap
,
container_diffuse
,
container_specular
);
auto
cubeMaterial
=
new
Material
(
lightmap
,
container_diffuse
,
container_specular
);
auto
planeMaterial
=
new
Material
(
lightmap
,
magenta
,
transparent
);
auto
planeMaterial
=
new
Material
(
lightmap
,
magenta
,
transparent
);
auto
projectorMaterial
=
new
Material
(
projector_shader
,
wall_tex
,
wall
);
auto
projectorMaterial
=
new
Material
(
projector_shader
,
wall_tex
,
wall
);
auto
projectorplaneMaterial
=
new
Material
(
projector_shader
,
magenta
,
wall
);
auto
teapot
=
make_render_object
(
make_mesh
(
"teapot.obj"
));
auto
teapot
=
make_render_object
(
make_mesh
(
"teapot.obj"
));
{
{
...
@@ -112,10 +114,11 @@ int main()
...
@@ -112,10 +114,11 @@ int main()
auto
plane
=
make_render_object
(
make_mesh
(
"plane.obj"
));
auto
plane
=
make_render_object
(
make_mesh
(
"plane.obj"
));
{
{
auto
transform
=
plane
->
get_transform
();
auto
transform
=
plane
->
get_transform
();
transform
->
set_scale
(
glm
::
vec3
(
10
,
10
,
1
));
transform
->
set_translate
(
glm
::
vec3
(
0.0f
,
0.0f
,
-
60.0f
));
transform
->
set_scale
(
glm
::
vec3
(
40
,
40
,
1
));
}
}
{
{
plane
->
set_material
(
planeMaterial
);
plane
->
set_material
(
projector
planeMaterial
);
}
}
auto
cube3
=
make_render_object
(
cube
);
auto
cube3
=
make_render_object
(
cube
);
...
@@ -151,11 +154,11 @@ int main()
...
@@ -151,11 +154,11 @@ int main()
{
{
teapot
->
projective_render
(
camera
);
teapot
->
projective_render
(
camera
);
cube1
->
projective_
render
(
camera
);
cube1
->
render
(
camera
);
cube2
->
projective_
render
(
camera
);
cube2
->
render
(
camera
);
cube3
->
projective_
render
(
camera
);
cube3
->
render
(
camera
);
plane
->
projective_render
(
camera
);
plane
->
projective_render
(
camera
);
cube4
->
projective_
render
(
camera
);
cube4
->
render
(
camera
);
}
}
glfwSwapBuffers
(
window
);
glfwSwapBuffers
(
window
);
...
...
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