Various little fixes (#118)

* Add missing override qualifier

* Mostly shadowing, virtual destructor and other little things
This commit is contained in:
Gawaboumga
2017-02-19 23:15:13 +01:00
committed by Jérôme Leclercq
parent ee9712fdcd
commit c2e4ccaf72
38 changed files with 94 additions and 92 deletions

View File

@@ -129,7 +129,7 @@ namespace Nz
if (s_useAnisotropicFilter)
{
for (const std::pair<UInt32, GLuint>& pair : s_samplers)
for (const std::pair<const UInt32, GLuint>& pair : s_samplers)
{
if (((pair.first >> 5) & 0xFF) == 0)
glSamplerParameterf(pair.second, GL_TEXTURE_MAX_ANISOTROPY_EXT, static_cast<float>(anisotropyLevel));
@@ -149,7 +149,7 @@ namespace Nz
s_defaultFilterMode = filterMode;
for (const std::pair<UInt32, GLuint>& pair : s_samplers)
for (const std::pair<const UInt32, GLuint>& pair : s_samplers)
{
if (((pair.first >> 1) & 0x3) == SamplerFilter_Default)
{
@@ -204,7 +204,7 @@ namespace Nz
s_defaultWrapMode = wrapMode;
GLenum wrapEnum = OpenGL::SamplerWrapMode[wrapMode];
for (const std::pair<UInt32, GLuint>& pair : s_samplers)
for (const std::pair<const UInt32, GLuint>& pair : s_samplers)
{
if (((pair.first >> 3) & 0x3) == SamplerWrap_Default)
{
@@ -380,7 +380,7 @@ namespace Nz
if (!s_samplers.empty())
{
Context::EnsureContext();
for (const std::pair<UInt32, GLuint>& pair : s_samplers)
for (const std::pair<const UInt32, GLuint>& pair : s_samplers)
OpenGL::DeleteSampler(pair.second);
s_samplers.clear();