removed dependency from directory

This commit is contained in:
devZoGok
2021-10-18 19:08:10 +03:00
parent 3d666aa3a1
commit 9e6b5a995a
12 changed files with 82 additions and 23 deletions
+10 -2
View File
@@ -7,7 +7,7 @@ namespace vb01{
Material::Material(Type type){
this->type=type;
string basePath="/home/dominykas/c++/vb01/",shaderName;
string basePath="../../vb01/",shaderName;
switch(type){
case MATERIAL_2D:
shaderName="texture.";
@@ -28,7 +28,15 @@ namespace vb01{
shader=new Shader(basePath+shaderName+"vert",basePath+shaderName+"frag");
}
Material::~Material(){}
Material::~Material(){
delete shader;
for(Texture *t : diffuseMapTextures)
delete t;
for(Texture *t : normalMapTextures)
delete t;
for(Texture *t : specularMapTextures)
delete t;
}
void Material::update(){
shader->use();