Skip to content
Snippets Groups Projects
Commit 01a371b4 authored by Philip Trettner's avatar Philip Trettner
Browse files
parents 6a3d6bd6 18551d6c
No related branches found
No related tags found
No related merge requests found
#pragma once
#include <glm/common.hpp>
#include <glm/geometric.hpp>
#include <glm/vec2.hpp>
#include <glm/vec3.hpp>
#include <glm/geometric.hpp>
#include <glm/common.hpp>
#include <glow/common/shared.hh>
#include <glow/objects/VertexArray.hh>
#include <glow/objects/ArrayBuffer.hh>
#include <glow/objects/ElementArrayBuffer.hh>
#include <glow/objects/VertexArray.hh>
namespace glow
{
......@@ -107,17 +107,17 @@ public:
auto baseIndex = vi;
vertices[vi++] = gen(mix(minCoord, maxCoord, (mid - left - top) * .5f + .5f), n, left, {0, 0});
vertices[vi++] = gen(mix(minCoord, maxCoord, (mid - left + top) * .5f + .5f), n, left, {0, 1});
vertices[vi++] = gen(mix(minCoord, maxCoord, (mid + left - top) * .5f + .5f), n, left, {1, 0});
vertices[vi++] = gen(mix(minCoord, maxCoord, (mid + left + top) * .5f + .5f), n, left, {1, 1});
vertices[vi++] = gen(mix(minCoord, maxCoord, (mid - left + top) * .5f + .5f), n, left, {0, 1});
indices[ii++] = baseIndex + 0;
indices[ii++] = baseIndex + 3;
indices[ii++] = baseIndex + 1;
indices[ii++] = baseIndex + 2;
indices[ii++] = baseIndex + 1;
indices[ii++] = baseIndex + 3;
indices[ii++] = baseIndex + 2;
indices[ii++] = baseIndex + 1;
}
}
......
......@@ -635,3 +635,8 @@ int GlfwApp::run(int argc, char *argv[])
return 0;
}
GlfwApp::~GlfwApp()
{
// empty
}
......@@ -246,6 +246,9 @@ protected:
public:
/// Initializes GLFW and GLOW, and runs until window is closed
int run(int argc, char* argv[]);
public:
virtual ~GlfwApp(); // virtual dtor
};
}
}
......@@ -61,6 +61,9 @@ glow::SharedTextureCubeMap glow::material::IBL::createEnvMapGGX(const glow::Shar
}
}
// we manually calculated all mipmaps
tex->setMipmapsGenerated(true);
return tex;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment