mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-05-12 12:13:51 +00:00
Revert "Project modernization (#630)"
This code was not tested and breaks in Release builds, reverting to restore
functionality of the nightly. All in-game menus do not work and generating
a world crashes.
This reverts commit a9be52c41a.
This commit is contained in:
parent
a9be52c41a
commit
087b7e7abf
1373 changed files with 19449 additions and 19903 deletions
|
|
@ -7,7 +7,7 @@
|
|||
#include "TextureManager.h"
|
||||
#include "..\Minecraft.World\StringHelpers.h"
|
||||
|
||||
TextureManager *TextureManager::instance = nullptr;
|
||||
TextureManager *TextureManager::instance = NULL;
|
||||
|
||||
void TextureManager::createInstance()
|
||||
{
|
||||
|
|
@ -36,7 +36,7 @@ Texture *TextureManager::getTexture(const wstring &name)
|
|||
return idToTextureMap.find(stringToIDMap.find(name)->second)->second;
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void TextureManager::registerName(const wstring &name, Texture *texture)
|
||||
|
|
@ -136,7 +136,7 @@ vector<Texture *> *TextureManager::createTextures(const wstring &filename, bool
|
|||
for (int i = 0; i < frameCount; i++)
|
||||
{
|
||||
BufferedImage *subImage = image->getSubimage(0, frameHeight * i, frameWidth, frameHeight);
|
||||
Texture *texture = createTexture(texName, mode, frameWidth, frameHeight, clamp, format, minFilter, magFilter, mipmap || image->getData(1) != nullptr, subImage);
|
||||
Texture *texture = createTexture(texName, mode, frameWidth, frameHeight, clamp, format, minFilter, magFilter, mipmap || image->getData(1) != NULL, subImage);
|
||||
delete subImage;
|
||||
result->push_back(texture);
|
||||
}
|
||||
|
|
@ -146,7 +146,7 @@ vector<Texture *> *TextureManager::createTextures(const wstring &filename, bool
|
|||
// TODO: Remove this hack -- fix proper rotation support (needed for 'off-aspect textures')
|
||||
if (width == height)
|
||||
{
|
||||
result->push_back(createTexture(texName, mode, width, height, clamp, format, minFilter, magFilter, mipmap || image->getData(1) != nullptr, image));
|
||||
result->push_back(createTexture(texName, mode, width, height, clamp, format, minFilter, magFilter, mipmap || image->getData(1) != NULL, image));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -191,6 +191,6 @@ Texture *TextureManager::createTexture(const wstring &name, int mode, int width,
|
|||
Texture *TextureManager::createTexture(const wstring &name, int mode, int width, int height, int format, bool mipmap)
|
||||
{
|
||||
// 4J Stu - Don't clamp as it causes issues with how we signal non-mipmmapped textures to the pixel shader
|
||||
//return createTexture(name, mode, width, height, Texture::WM_CLAMP, format, Texture::TFLT_NEAREST, Texture::TFLT_NEAREST, mipmap, nullptr);
|
||||
return createTexture(name, mode, width, height, Texture::WM_WRAP, format, Texture::TFLT_NEAREST, Texture::TFLT_NEAREST, mipmap, nullptr);
|
||||
//return createTexture(name, mode, width, height, Texture::WM_CLAMP, format, Texture::TFLT_NEAREST, Texture::TFLT_NEAREST, mipmap, NULL);
|
||||
return createTexture(name, mode, width, height, Texture::WM_WRAP, format, Texture::TFLT_NEAREST, Texture::TFLT_NEAREST, mipmap, NULL);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue