[nostalgia/core/sdl] Remove SDL implementation's bgTextures

This commit is contained in:
Gary Talent 2021-03-24 00:47:53 -05:00
parent 85e7374446
commit 084cee44fa
2 changed files with 1 additions and 11 deletions

View File

@ -17,7 +17,6 @@ namespace nostalgia::core {
struct SdlImplData {
SDL_Window *window = nullptr;
SDL_GLContext renderer = nullptr;
std::array<SDL_Texture*, 4> bgTextures{};
};
}

View File

@ -6,17 +6,13 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#include "nostalgia/common/point.hpp"
#include <array>
#ifdef NOST_FPS_PRINT
#include <iostream>
#endif
#include <iostream>
#include <SDL.h>
#include <ox/claw/read.hpp>
#include <nostalgia/common/point.hpp>
#include <nostalgia/core/gfx.hpp>
#include <nostalgia/core/userland/gfx.hpp>
@ -49,11 +45,6 @@ ox::Error initGfx(Context *ctx) {
ox::Error shutdownGfx(Context *ctx) {
oxReturnError(renderer::shutdown(ctx));
auto id = ctx->windowerData<SdlImplData>();
for (auto tex : id->bgTextures) {
if (tex) {
SDL_DestroyTexture(tex);
}
}
SDL_GL_DeleteContext(id->renderer);
SDL_DestroyWindow(id->window);
ctx->setWindowerData(nullptr);