#include "phongmodule.h" #include "lights.h" PhongModule::PhongModule(Lights* myDirLights, Lights* myPointLights, Shader* phongShader) : BasicModule(phongShader), dirLights(myDirLights), pointLights(myPointLights) { nbDirLightsLocation = shader->getLocation("nbDirLights"); dirLightsLocation = shader->getLocation("dirLights"); nbPointLightsLocation = shader->getLocation("nbPointLights"); pointLightsLocation = shader->getLocation("pointLights"); } void PhongModule::bindModule() { dirLights->bind(dirLightsLocation, nbDirLightsLocation, shader); pointLights->bind(pointLightsLocation, nbPointLightsLocation, shader); }