Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Lighning-dumping implemented

  • Loading branch information...
commit 913138daafd446289057e56ca88ee27c7b8bb96b 1 parent 022b072
@Phosfor Phosfor authored
Showing with 6 additions and 2 deletions.
  1. +1 −1  samples/pong-cpp/main.cpp
  2. +5 −1 src/Managers/Entities/Light.cpp
View
2  samples/pong-cpp/main.cpp
@@ -34,7 +34,7 @@ class GameState : public State
public:
void init() {
MakeCamera("MainCamera")->loadFromFile("Entities/MainCamera.info")->dump();
- MakeLight("DirectionalLight");
+ MakeLight("DirectionalLight")->dump();
MakeObject("ErrorObject")->loadFromFile("Entities/ErrorObject.info")->dump();
MakeObject("TestLight")->loadFromFile("Entities/Light.info")->dump()->setPosition(vec3(0, 50, 0));
View
6 src/Managers/Entities/Light.cpp
@@ -43,7 +43,11 @@ Light *Light::loadFromFile(const string &filePath)
Light *Light::dump()
{
defaultDump();
- // TODO: typeDump light
+ LOG_NOFORMAT("\t ---Type settings---\n");
+ LOG_NOFORMAT(FORMAT("\t%1%: %2%\n", "Diffuse" % mLight->getDiffuseColour()));
+ LOG_NOFORMAT(FORMAT("\t%1%: %2%\n", "Specular" % mLight->getSpecularColour()));
+ LOG_NOFORMAT(FORMAT("\t%1%: %2%\n", "Radius" % mLight->getAttenuationRange()));
+ LOG_NOFORMAT(FORMAT("\t%1%: %2%\n", "Power" % mLight->getPowerScale()));
return this;
}
Please sign in to comment.
Something went wrong with that request. Please try again.