mirror of
https://github.com/bsnes-emu/bsnes.git
synced 2025-08-31 11:11:59 +02:00
Update to v094r01 release.
byuu says: Changelog: - port: various compilation fixes for OS X [kode54] - nall: added programpath() function to return path to process binary [todo: need to have ethos use this function] - ruby: XAudio2 will select default game sound device instead of first sound device - ruby: DirectInput device IDs are no longer ambiguous when VID+PID are identical - ruby: OpenGL won't try and terminate if it hasn't been initialized - gb: D-pad up+down/left+right not masked in SGB mode - sfc: rewrote ICD2 video rendering to output in real-time, work with cycle-based Game Boy renderer - sfc: rewrote Bus::reduce(), reduces game loading time by about 500ms - ethos: store save states in {game}/higan/* instead of {game}/bsnes/* - loki: added target-loki/ (blank stub for now) - Makefile: purge out/* on make clean
This commit is contained in:
@@ -15,13 +15,12 @@ namespace ruby {
|
||||
namespace ruby {
|
||||
|
||||
struct pVideoCGL : OpenGL {
|
||||
RubyVideoCGL* view;
|
||||
RubyVideoCGL* view = nullptr;
|
||||
|
||||
struct {
|
||||
NSView* handle;
|
||||
|
||||
bool synchronize;
|
||||
unsigned filter;
|
||||
NSView* handle = nullptr;
|
||||
bool synchronize = false;
|
||||
unsigned filter = 0;
|
||||
string shader;
|
||||
} settings;
|
||||
|
||||
@@ -157,14 +156,6 @@ struct pVideoCGL : OpenGL {
|
||||
}
|
||||
}
|
||||
|
||||
pVideoCGL() {
|
||||
view = nil;
|
||||
|
||||
settings.handle = nil;
|
||||
settings.synchronize = false;
|
||||
settings.filter = 0;
|
||||
}
|
||||
|
||||
~pVideoCGL() {
|
||||
term();
|
||||
}
|
||||
|
@@ -200,11 +200,13 @@ bool OpenGL::init() {
|
||||
glrLinkProgram(program);
|
||||
|
||||
shader(nullptr);
|
||||
return true;
|
||||
return initialized = true;
|
||||
}
|
||||
|
||||
void OpenGL::term() {
|
||||
if(initialized == false) return;
|
||||
shader(nullptr); //release shader resources (eg frame[] history)
|
||||
OpenGLSurface::release();
|
||||
if(buffer) { delete[] buffer; buffer = nullptr; }
|
||||
initialized = false;
|
||||
}
|
||||
|
@@ -79,6 +79,7 @@ struct OpenGL : OpenGLProgram {
|
||||
Setting(const string& name, const string& value) : name(name), value(value) {}
|
||||
};
|
||||
set<Setting> settings;
|
||||
bool initialized = false;
|
||||
|
||||
void shader(const char* pathname);
|
||||
void allocateHistory(unsigned size);
|
||||
|
Reference in New Issue
Block a user