door in place
This commit is contained in:
parent
cc0c23c175
commit
b85518d1f2
36
models2/room/longerWall_d.obj
Normal file
36
models2/room/longerWall_d.obj
Normal file
@ -0,0 +1,36 @@
|
||||
# Blender 3.4.1
|
||||
# www.blender.org
|
||||
mtllib longetWall_d.mtl
|
||||
o Plane
|
||||
v -2.500000 0.000000 0.000000
|
||||
v 2.500000 0.000000 0.000000
|
||||
v -2.500000 2.600000 0.000000
|
||||
v 2.500000 2.600000 0.000000
|
||||
v -1.022748 2.600000 0.000000
|
||||
v -1.022748 0.000000 0.000000
|
||||
v -2.364466 2.600000 0.000000
|
||||
v -2.364466 0.000000 0.000000
|
||||
v -2.500000 2.386472 0.000000
|
||||
v 2.500000 2.386472 0.000000
|
||||
v -1.022748 2.386472 0.000000
|
||||
v -2.364466 2.386472 0.000000
|
||||
vn -0.0000 -0.0000 1.0000
|
||||
vt 0.000000 0.000000
|
||||
vt 1.000000 0.000000
|
||||
vt 0.000000 1.000000
|
||||
vt 1.000000 1.000000
|
||||
vt 0.295450 1.000000
|
||||
vt 0.295450 0.000000
|
||||
vt 0.027107 1.000000
|
||||
vt 0.027107 0.000000
|
||||
vt 0.000000 0.917874
|
||||
vt 1.000000 0.917874
|
||||
vt 0.295450 0.917874
|
||||
vt 0.027107 0.917874
|
||||
s 0
|
||||
usemtl Material.001
|
||||
f 11/11/1 10/10/1 4/4/1 5/5/1
|
||||
f 12/12/1 11/11/1 5/5/1 7/7/1
|
||||
f 9/9/1 12/12/1 7/7/1 3/3/1
|
||||
f 1/1/1 8/8/1 12/12/1 9/9/1
|
||||
f 6/6/1 2/2/1 10/10/1 11/11/1
|
12
models2/room/longetWall_d.mtl
Normal file
12
models2/room/longetWall_d.mtl
Normal file
@ -0,0 +1,12 @@
|
||||
# Blender 3.4.1 MTL File: 'None'
|
||||
# www.blender.org
|
||||
|
||||
newmtl Material.001
|
||||
Ns 250.000000
|
||||
Ka 1.000000 1.000000 1.000000
|
||||
Ks 0.500000 0.500000 0.500000
|
||||
Ke 0.000000 0.000000 0.000000
|
||||
Ni 1.450000
|
||||
d 1.000000
|
||||
illum 2
|
||||
map_Kd longerWall.png
|
@ -43,6 +43,7 @@ namespace models {
|
||||
Core::RenderContext carpet;
|
||||
Core::RenderContext roof;
|
||||
Core::RenderContext longerWall;
|
||||
Core::RenderContext longerWall_d;
|
||||
Core::RenderContext smallerWall;
|
||||
Core::RenderContext smallerWall_ww;
|
||||
}
|
||||
@ -342,11 +343,13 @@ void renderScene(GLFWwindow* window)
|
||||
textures::longerWallTexture,
|
||||
0,
|
||||
0);
|
||||
drawObjectPBR(models::longerWall, glm::mat4() * glm::translate(glm::vec3(0,0,2)),
|
||||
glm::mat4 model = glm::mat4() * glm::translate(glm::vec3(0, 0, 2));
|
||||
model = glm::rotate(model, glm::radians(180.0f), glm::vec3(0, 1, 0));
|
||||
drawObjectPBR(models::longerWall_d, model,
|
||||
textures::longerWallTexture,
|
||||
0,
|
||||
0);
|
||||
glm::mat4 model = glm::mat4() * glm::translate(glm::vec3(2.5, 0, 0));
|
||||
model = glm::mat4() * glm::translate(glm::vec3(2.5, 0, 0));
|
||||
model = glm::rotate(model, glm::radians(90.0f), glm::vec3(0, 1, 0));
|
||||
drawObjectPBR(models::smallerWall, model,
|
||||
textures::longerWallTexture,
|
||||
@ -387,11 +390,13 @@ void renderScene(GLFWwindow* window)
|
||||
// 0.3f,
|
||||
// 0.0f
|
||||
//);
|
||||
//drawObjectPBR(models::door, glm::mat4(),
|
||||
// textures::doorTexture,
|
||||
// 0.4f,
|
||||
// 0.0f
|
||||
//);
|
||||
model = glm::mat4(1.0f) * glm::translate(glm::vec3(1.7f, 1.15f, 2.0f));
|
||||
model = glm::rotate(model, glm::radians(90.0f), glm::vec3(0.0, 1.0, 0.0)) * glm::scale(glm::vec3(1.0f, 1.1f, 1.3f));
|
||||
drawObjectPBR(models::door, model,
|
||||
textures::doorTexture,
|
||||
0.4f,
|
||||
0.0f
|
||||
);
|
||||
//drawObjectPBR(models::desk, glm::mat4(),
|
||||
// textures::deskTexture,
|
||||
// 0.4f,
|
||||
@ -609,7 +614,7 @@ void init(GLFWwindow* window)
|
||||
loadModelToContext("./models2/room/longerWall.obj", models::longerWall);
|
||||
loadModelToContext("./models2/room/smallerWall.obj", models::smallerWall);
|
||||
loadModelToContext("./models2/room/smallerWall_ww.obj", models::smallerWall_ww);
|
||||
|
||||
loadModelToContext("./models2/room/longerWall_d.obj", models::longerWall_d);
|
||||
|
||||
textures::floorTexture = Core::LoadTexture("./models2/room/wood.png");
|
||||
textures::flashlightTexture = Core::LoadTexture("./models/FlashlightTexture.png");
|
||||
|
Loading…
Reference in New Issue
Block a user