Set switch between day and light
This commit is contained in:
parent
73839b05d9
commit
11398507e3
@ -105,10 +105,11 @@ void TGameMap::LoadMap()
|
||||
Land->SetTexture(std::string("landscapes/out.bmp"));
|
||||
Land->Scale(0.005f);
|
||||
|
||||
StaticModelArr.resize(3);
|
||||
StaticModelArr.resize(4);
|
||||
StaticModelArr[0].LoadModel("bt_box_yellow.lm1");
|
||||
StaticModelArr[1].LoadModel("bt_box_red.lm1");
|
||||
StaticModelArr[2].LoadModel("bt_box_blue.lm1");
|
||||
StaticModelArr[3].LoadModel("bt_box_yellow.lm1");
|
||||
|
||||
StaticModelArr[0].ScaleModel(2.0);
|
||||
StaticModelArr[0].RotateModel(mat3(vec4(0.0, sin(pi/6), 0.0, cos(pi/6))));
|
||||
@ -122,11 +123,14 @@ void TGameMap::LoadMap()
|
||||
StaticModelArr[2].ScaleModel(2.0);
|
||||
StaticModelArr[2].MoveModel(vec3(-1.5f, 0.23f, 7.8f));
|
||||
|
||||
StaticModelArr[3].ScaleModel(2.0);
|
||||
StaticModelArr[3].MoveModel(vec3(0.f, 0.4f, 0.f));
|
||||
|
||||
|
||||
StaticModelArr[0].UpdateVBO();
|
||||
StaticModelArr[1].UpdateVBO();
|
||||
StaticModelArr[2].UpdateVBO();
|
||||
StaticModelArr[3].UpdateVBO();
|
||||
|
||||
//StaticModelArr[0].SetShaderTranslateVector(vec3(-1.0f, 0.23f, 6.3f));
|
||||
PlayerChar = new TLiteModel;
|
||||
@ -147,6 +151,7 @@ void TGameMap::LoadMap()
|
||||
|
||||
MapChar.SetPos(vec3(0.0f, 0.0f, 10.0f));
|
||||
|
||||
day = false;
|
||||
|
||||
}
|
||||
|
||||
@ -187,11 +192,17 @@ TSimpleLandClass* TGameMap::GetLand()
|
||||
|
||||
void TGameMap::DrawVBO()
|
||||
{
|
||||
|
||||
|
||||
Land->DrawVBO();
|
||||
|
||||
Renderer->PushShader("Directlight3");
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight3");
|
||||
}
|
||||
for (TLiteModelArr::iterator i = StaticModelArr.begin(); i != StaticModelArr.end(); ++i)
|
||||
{
|
||||
//i->DrawImmediate();
|
||||
@ -212,6 +223,15 @@ cardinal timeForSeq = 0;
|
||||
void TGameMap::Update(cardinal timer)
|
||||
{
|
||||
|
||||
vec4 quat = vec4(0, sin(timer / 2000.f), 0, cos(timer / 2000.f));
|
||||
|
||||
mat3 rotate(quat);
|
||||
|
||||
StaticModelArr[3].RotateModel(rotate);
|
||||
StaticModelArr[3].UpdateVBO();
|
||||
|
||||
|
||||
/*
|
||||
MapChar.Update(timer);
|
||||
|
||||
|
||||
@ -241,7 +261,7 @@ void TGameMap::Update(cardinal timer)
|
||||
//GirlText->ApplySequence("girl.an1", animSeq);
|
||||
//GirlText->UpdateVBO();
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
|
||||
|
||||
|
@ -62,5 +62,6 @@ public:
|
||||
TAnimModel* AnimModel;
|
||||
TAnimModel* GirlText;
|
||||
int animSeq;
|
||||
bool day;
|
||||
|
||||
};
|
238
Template/log.txt
238
Template/log.txt
@ -1,169 +1,169 @@
|
||||
2024-Jun-10 22:16:13: Log started
|
||||
2024-Jun-10 22:16:13: OpenGL Window created
|
||||
2024-Jun-10 22:16:13: Script manager ready
|
||||
2024-Jun-10 22:16:13: Render::OpenGL glVersion = 4.6.0 - Build 31.0.101.4887
|
||||
2024-Jun-10 22:16:13: Render::OpenGL glVersion above 2.0 ok
|
||||
2024-Jun-10 22:16:13: Render::OpenGL GL_ARB_framebuffer_object supported ok
|
||||
2024-Jun-10 22:16:13: Render::OpenGL GL_ARB_uniform_buffer_object supported ok
|
||||
2024-Jun-10 22:16:13: Prepare to add shader GUI
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Log started
|
||||
2024-Jun-10 22:47:04: OpenGL Window created
|
||||
2024-Jun-10 22:47:04: Script manager ready
|
||||
2024-Jun-10 22:47:04: Render::OpenGL glVersion = 4.6.0 - Build 31.0.101.4887
|
||||
2024-Jun-10 22:47:04: Render::OpenGL glVersion above 2.0 ok
|
||||
2024-Jun-10 22:47:04: Render::OpenGL GL_ARB_framebuffer_object supported ok
|
||||
2024-Jun-10 22:47:04: Render::OpenGL GL_ARB_uniform_buffer_object supported ok
|
||||
2024-Jun-10 22:47:04: Prepare to add shader GUI
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 3
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: GUI
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Parallax
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 3
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: GUI
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Parallax
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
WARNING: 0:27: 'assign' : implicit type conversion allowed from GLSL 1.20
|
||||
WARNING: 0:27: 'assign' : implicit type conversion allowed from GLSL 1.20
|
||||
WARNING: 0:27: 'assign' : implicit type conversion allowed
|
||||
2024-Jun-10 22:16:13: Shader program is - 6
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Parallax
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Directlight
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 6
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Parallax
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Directlight
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 9
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Directlight
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Directlight2
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 9
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Directlight
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Directlight2
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 12
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Directlight2
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Directlight3
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 12
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Directlight2
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Directlight3
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 15
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Directlight3
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Env
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 15
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Directlight3
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Env
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 18
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Env
|
||||
2024-Jun-10 22:16:13: Prepare to add shader EnvReverse
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 18
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Env
|
||||
2024-Jun-10 22:47:04: Prepare to add shader EnvReverse
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 21
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: EnvReverse
|
||||
2024-Jun-10 22:16:13: Prepare to add shader EnvReverseNight
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 21
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: EnvReverse
|
||||
2024-Jun-10 22:47:04: Prepare to add shader EnvReverseNight
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 24
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: EnvReverseNight
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Water
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 24
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: EnvReverseNight
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Water
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
WARNING: 0:29: 'assign' : implicit type conversion allowed from GLSL 1.20
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 27
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Water
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Frame
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 27
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Water
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Frame
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 30
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Frame
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Lightview
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:5: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 30
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Frame
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Lightview
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:5: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 33
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Lightview
|
||||
2024-Jun-10 22:16:13: Prepare to add shader Simple3D
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: Shader program is - 33
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Lightview
|
||||
2024-Jun-10 22:47:04: Prepare to add shader Simple3D
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader WARNING: 0:1: '' : #version directive missing
|
||||
|
||||
|
||||
2024-Jun-10 22:16:13: Shader program is - 36
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:16:13: ResourceManager::ShaderManager shader loaded: Simple3D
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture added: bt_box_yellow.bmp with id = 1
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture added: bt_box_norm.bmp32 with id = 2
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/bt_box_yellow.lm1
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture added: bt_box_red000.bmp with id = 3
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture reference added: bt_box_norm.bmp32
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/bt_box_red.lm1
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture added: bt_box_blue00.bmp with id = 4
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture reference added: bt_box_norm.bmp32
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/bt_box_blue.lm1
|
||||
2024-Jun-10 22:16:13: ResourceManager::TexList Texture added: bt_cone.bmp with id = 5
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/bt_cone.lm1
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/girl.lm1
|
||||
2024-Jun-10 22:16:13: Lite model added successfully: models/bonemodel.lm1
|
||||
2024-Jun-10 22:16:14: ResourceManager::TexList Texture added: out.bmp with id = 6
|
||||
2024-Jun-10 22:16:15: FrameManager:: frame buffer added: Skybox
|
||||
2024-Jun-10 22:16:15: ResourceManager::TexList Texture added: normalmap.bmp with id = 8
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posx.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negx.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posy.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negy.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posz.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negz.bmp
|
||||
2024-Jun-10 22:16:15: ResourceManager::TexList texture added succesfuly: posx.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_rt.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_lf.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_dn.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_up.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_bk.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_ft.bmp
|
||||
2024-Jun-10 22:16:15: ResourceManager::TexList texture added succesfuly: yavin_rt.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_rt.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_lf.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_up.bmp
|
||||
2024-Jun-10 22:16:15: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_dn.bmp
|
||||
2024-Jun-10 22:16:16: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_bk.bmp
|
||||
2024-Jun-10 22:16:16: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_ft.bmp
|
||||
2024-Jun-10 22:16:16: ResourceManager::TexList texture added succesfuly: space_rt.bmp
|
||||
2024-Jun-10 22:16:16: FrameManager:: frame buffer added: ScreenBlur
|
||||
2024-Jun-10 22:16:16: FrameManager:: frame buffer added: ShadowBufferGlobal
|
||||
2024-Jun-10 22:16:16: FrameManager:: frame buffer added: ShadowBufferLocal
|
||||
2024-Jun-10 22:47:04: Shader program is - 36
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager::Shader
|
||||
2024-Jun-10 22:47:04: ResourceManager::ShaderManager shader loaded: Simple3D
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture added: bt_box_yellow.bmp with id = 1
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture added: bt_box_norm.bmp32 with id = 2
|
||||
2024-Jun-10 22:47:04: Lite model added successfully: models/bt_box_yellow.lm1
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture added: bt_box_red000.bmp with id = 3
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture reference added: bt_box_norm.bmp32
|
||||
2024-Jun-10 22:47:04: Lite model added successfully: models/bt_box_red.lm1
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture added: bt_box_blue00.bmp with id = 4
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture reference added: bt_box_norm.bmp32
|
||||
2024-Jun-10 22:47:04: Lite model added successfully: models/bt_box_blue.lm1
|
||||
2024-Jun-10 22:47:04: ResourceManager::TexList Texture added: bt_cone.bmp with id = 5
|
||||
2024-Jun-10 22:47:04: Lite model added successfully: models/bt_cone.lm1
|
||||
2024-Jun-10 22:47:04: Lite model added successfully: models/girl.lm1
|
||||
2024-Jun-10 22:47:05: Lite model added successfully: models/bonemodel.lm1
|
||||
2024-Jun-10 22:47:06: ResourceManager::TexList Texture added: out.bmp with id = 6
|
||||
2024-Jun-10 22:47:06: FrameManager:: frame buffer added: Skybox
|
||||
2024-Jun-10 22:47:06: ResourceManager::TexList Texture added: normalmap.bmp with id = 8
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posx.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negx.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posy.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negy.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/posz.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/negz.bmp
|
||||
2024-Jun-10 22:47:07: ResourceManager::TexList texture added succesfuly: posx.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_rt.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_lf.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_dn.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_up.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_bk.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/yavin_ft.bmp
|
||||
2024-Jun-10 22:47:07: ResourceManager::TexList texture added succesfuly: yavin_rt.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_rt.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_lf.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_up.bmp
|
||||
2024-Jun-10 22:47:07: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_dn.bmp
|
||||
2024-Jun-10 22:47:08: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_bk.bmp
|
||||
2024-Jun-10 22:47:08: Going to add texture: C:\Work\OldProjects\ho3\resources\../resources/sky/space_ft.bmp
|
||||
2024-Jun-10 22:47:08: ResourceManager::TexList texture added succesfuly: space_rt.bmp
|
||||
2024-Jun-10 22:47:08: FrameManager:: frame buffer added: ScreenBlur
|
||||
2024-Jun-10 22:47:08: FrameManager:: frame buffer added: ShadowBufferGlobal
|
||||
2024-Jun-10 22:47:08: FrameManager:: frame buffer added: ShadowBufferLocal
|
||||
|
@ -14,9 +14,15 @@ void TMyApplication::DrawToCubemap()
|
||||
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",0);
|
||||
Renderer->SetGlPosXView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlPosXView(true, true);
|
||||
GameMap.DrawVBO();
|
||||
Renderer->PopShader();
|
||||
@ -26,9 +32,15 @@ void TMyApplication::DrawToCubemap()
|
||||
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",1);
|
||||
Renderer->SetGlNegXView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlNegXView(true, true);
|
||||
//glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
|
||||
//glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT);
|
||||
@ -37,9 +49,15 @@ void TMyApplication::DrawToCubemap()
|
||||
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",2);
|
||||
Renderer->SetGlPosYView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlPosYView(true, true);
|
||||
GameMap.DrawVBO();
|
||||
//glClearColor(0.0f, 1.0f, 0.0f, 1.0f);
|
||||
@ -47,9 +65,15 @@ void TMyApplication::DrawToCubemap()
|
||||
Renderer->PopShader();
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",3);
|
||||
Renderer->SetGlNegYView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlNegYView(true, true);
|
||||
//glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
|
||||
//glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT);
|
||||
@ -57,9 +81,15 @@ void TMyApplication::DrawToCubemap()
|
||||
Renderer->PopShader();
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",4);
|
||||
Renderer->SetGlPosZView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlPosZView(true, true);
|
||||
GameMap.DrawVBO();
|
||||
//glClearColor(0.0f, 0.0f, 1.0f, 1.0f);
|
||||
@ -68,9 +98,15 @@ void TMyApplication::DrawToCubemap()
|
||||
|
||||
Renderer->SwitchToCubemapBuffer("Skybox",5);
|
||||
Renderer->SetGlNegZView(false, true);
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGlNegZView(true, true);
|
||||
//glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
|
||||
//glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT);
|
||||
@ -99,9 +135,15 @@ void TMyApplication::DrawToShadowMap()
|
||||
void TMyApplication::DrawSceneWithoutWater()
|
||||
{
|
||||
Renderer->SetGLCamAngleView();
|
||||
//DrawCubemapDay();
|
||||
DrawCubemapNight();
|
||||
Renderer->PushShader("Directlight2");
|
||||
DrawCubemap();
|
||||
if (day)
|
||||
{
|
||||
Renderer->PushShader("Directlight");
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->PushShader("Directlight2");
|
||||
}
|
||||
Renderer->SetGLCamView();
|
||||
GameMap.DrawVBO();
|
||||
Renderer->PopShader();
|
||||
@ -135,6 +177,18 @@ void TMyApplication::DrawWaterSurface()
|
||||
}
|
||||
|
||||
void TMyApplication::DrawCubemap()
|
||||
{
|
||||
if (day)
|
||||
{
|
||||
DrawCubemapDay();
|
||||
}
|
||||
else
|
||||
{
|
||||
DrawCubemapNight();
|
||||
}
|
||||
}
|
||||
|
||||
void TMyApplication::DrawCubemapFixed()
|
||||
{
|
||||
Renderer->PushShader("Env");
|
||||
//Renderer->SetGLCamAngleView();
|
||||
@ -462,6 +516,9 @@ void TMyApplication::InnerInit()
|
||||
frameVertexDataStruct.TexCoordData.push_back({ 0.0, 1.0 });
|
||||
frameVertexDataStruct.RefreshVBO();
|
||||
|
||||
day = false;
|
||||
GameMap.day = day;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -479,7 +536,14 @@ void TMyApplication::InnerDraw()
|
||||
glClearColor(0.2f, 0.55f, 1.0f, 1.0f);
|
||||
glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT);
|
||||
|
||||
if (day)
|
||||
{
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
Renderer->SetLightPos(lightPos);
|
||||
}
|
||||
Renderer->PushShader("Directlight");
|
||||
//DrawCubemapDay();
|
||||
|
||||
@ -570,6 +634,8 @@ void TMyApplication::InnerUpdate(cardinal timer)
|
||||
{
|
||||
WaterTimer += 0.001f * timer;
|
||||
|
||||
lightPos = vec3(sin(WaterTimer) * 4.f-2, 5, 0);
|
||||
|
||||
GameMap.Update(timer);
|
||||
|
||||
}
|
||||
|
@ -28,6 +28,10 @@ class TMyApplication : public SE::TApplication
|
||||
|
||||
int view = 0;
|
||||
|
||||
vec3 lightPos;
|
||||
|
||||
bool day = false;
|
||||
|
||||
float WaterTimer;
|
||||
|
||||
void DrawSceneWithoutWater();
|
||||
@ -38,6 +42,7 @@ class TMyApplication : public SE::TApplication
|
||||
|
||||
void DrawWaterSurface();
|
||||
|
||||
void DrawCubemapFixed();
|
||||
void DrawCubemap();
|
||||
void DrawCubemapDay();
|
||||
void DrawCubemapNight();
|
||||
|
Loading…
Reference in New Issue
Block a user