1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-06-25 22:09:35 +00:00
GLideN64/src/TextureFilterHandler.h
Sergey Lipskiy e284f432d1 Do not shutdown TextureFilterHandler on RomClosed() API command.
This avoids hires cache reload on savestates load.

Minor code cleanup (GLideNHQ code is a mess atm).
2017-11-22 14:35:31 +07:00

26 lines
666 B
C++

#ifndef TEXTUREFILTERHANDLER_H
#define TEXTUREFILTERHANDLER_H
#include "Types.h"
class TextureFilterHandler
{
public:
TextureFilterHandler() : m_inited(0), m_options(0) {}
// It's not safe to call shutdown() in destructor, because texture filter has its own static objects, which can be destroyed first.
~TextureFilterHandler() { shutdown(); }
void init();
void shutdown();
void dumpcache();
bool isInited() const { return m_inited != 0; }
bool optionsChanged() const { return _getConfigOptions() != m_options; }
private:
u32 _getConfigOptions() const;
u32 m_inited;
u32 m_options;
};
extern TextureFilterHandler TFH;
#endif // TEXTUREFILTERHANDLER_H