mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
opengl as requirement (nw)
This commit is contained in:
parent
c16d050d54
commit
e1ace73626
@ -38,7 +38,7 @@ if _OPTIONS["with-bundled-lua"] then
|
||||
}
|
||||
end
|
||||
|
||||
if (_OPTIONS["targetos"] == "windows") then
|
||||
if (_OPTIONS["targetos"] == "windows" and _OPTIONS["osd"] ~= "osdmini" ) then
|
||||
defines {
|
||||
"UI_WINDOWS",
|
||||
}
|
||||
|
@ -77,28 +77,18 @@ function osdmodulesbuild()
|
||||
}
|
||||
end
|
||||
|
||||
if _OPTIONS["NO_OPENGL"]=="1" then
|
||||
files {
|
||||
MAME_DIR .. "src/osd/modules/render/drawogl.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.h",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.h",
|
||||
MAME_DIR .. "src/osd/modules/opengl/osd_opengl.h",
|
||||
}
|
||||
if _OPTIONS["USE_DISPATCH_GL"]=="1" then
|
||||
defines {
|
||||
"USE_OPENGL=0",
|
||||
"USE_DISPATCH_GL=1",
|
||||
}
|
||||
else
|
||||
files {
|
||||
MAME_DIR .. "src/osd/modules/render/drawogl.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.cpp",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_mgr.h",
|
||||
MAME_DIR .. "src/osd/modules/opengl/gl_shader_tool.h",
|
||||
MAME_DIR .. "src/osd/modules/opengl/osd_opengl.h",
|
||||
MAME_DIR .. "src/osd/modules/opengl/SDL1211_opengl.h",
|
||||
}
|
||||
defines {
|
||||
"USE_OPENGL=1",
|
||||
}
|
||||
if _OPTIONS["USE_DISPATCH_GL"]=="1" then
|
||||
defines {
|
||||
"USE_DISPATCH_GL=1",
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
if USE_BGFX == 1 then
|
||||
@ -257,21 +247,19 @@ end
|
||||
|
||||
function osdmodulestargetconf()
|
||||
|
||||
if _OPTIONS["NO_OPENGL"]~="1" then
|
||||
if _OPTIONS["targetos"]=="macosx" then
|
||||
if _OPTIONS["targetos"]=="macosx" then
|
||||
links {
|
||||
"OpenGL.framework",
|
||||
}
|
||||
elseif _OPTIONS["USE_DISPATCH_GL"]~="1" then
|
||||
if _OPTIONS["targetos"]=="windows" then
|
||||
links {
|
||||
"OpenGL.framework",
|
||||
"opengl32",
|
||||
}
|
||||
else
|
||||
links {
|
||||
"GL",
|
||||
}
|
||||
elseif _OPTIONS["USE_DISPATCH_GL"]~="1" then
|
||||
if _OPTIONS["targetos"]=="windows" then
|
||||
links {
|
||||
"opengl32",
|
||||
}
|
||||
else
|
||||
links {
|
||||
"GL",
|
||||
}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@ -348,23 +336,6 @@ newoption {
|
||||
description = "Disable network access",
|
||||
}
|
||||
|
||||
newoption {
|
||||
trigger = "NO_OPENGL",
|
||||
description = "Disable use of OpenGL",
|
||||
allowed = {
|
||||
{ "0", "Enable OpenGL" },
|
||||
{ "1", "Disable OpenGL" },
|
||||
},
|
||||
}
|
||||
|
||||
if not _OPTIONS["NO_OPENGL"] then
|
||||
if _OPTIONS["targetos"]=="os2" then
|
||||
_OPTIONS["NO_OPENGL"] = "1"
|
||||
else
|
||||
_OPTIONS["NO_OPENGL"] = "0"
|
||||
end
|
||||
end
|
||||
|
||||
newoption {
|
||||
trigger = "USE_DISPATCH_GL",
|
||||
description = "Use GL-dispatching",
|
||||
|
@ -6,7 +6,6 @@ defines {
|
||||
"USE_QTDEBUG=0",
|
||||
"USE_SDL",
|
||||
"SDLMAME_NOASM=1",
|
||||
"USE_OPENGL=0",
|
||||
"NO_USE_MIDI=1",
|
||||
"USE_XAUDIO2=0",
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ if SDL_NETWORK~="" and not _OPTIONS["DONT_USE_NETWORK"] then
|
||||
}
|
||||
end
|
||||
|
||||
if _OPTIONS["NO_OPENGL"]~="1" and _OPTIONS["USE_DISPATCH_GL"]~="1" and _OPTIONS["MESA_INSTALL_ROOT"] then
|
||||
if _OPTIONS["USE_DISPATCH_GL"]~="1" and _OPTIONS["MESA_INSTALL_ROOT"] then
|
||||
includedirs {
|
||||
path.join(_OPTIONS["MESA_INSTALL_ROOT"],"include"),
|
||||
}
|
||||
|
@ -86,7 +86,6 @@ const options_entry osd_options::s_option_entries[] =
|
||||
{ OSDOPTION_FILTER ";glfilter;flt", "1", OPTION_BOOLEAN, "enable bilinear filtering on screen output" },
|
||||
{ OSDOPTION_PRESCALE, "1", OPTION_INTEGER, "scale screen rendering by this amount in software" },
|
||||
|
||||
#if USE_OPENGL
|
||||
{ NULL, NULL, OPTION_HEADER, "OpenGL-SPECIFIC OPTIONS" },
|
||||
{ OSDOPTION_GL_FORCEPOW2TEXTURE, "0", OPTION_BOOLEAN, "force power of two textures (default no)" },
|
||||
{ OSDOPTION_GL_NOTEXTURERECT, "0", OPTION_BOOLEAN, "don't use OpenGL GL_ARB_texture_rectangle (default on)" },
|
||||
@ -114,7 +113,6 @@ const options_entry osd_options::s_option_entries[] =
|
||||
{ OSDOPTION_SHADER_SCREEN "7", OSDOPTVAL_NONE, OPTION_STRING, "custom OpenGL GLSL shader screen bitmap 7" },
|
||||
{ OSDOPTION_SHADER_SCREEN "8", OSDOPTVAL_NONE, OPTION_STRING, "custom OpenGL GLSL shader screen bitmap 8" },
|
||||
{ OSDOPTION_SHADER_SCREEN "9", OSDOPTVAL_NONE, OPTION_STRING, "custom OpenGL GLSL shader screen bitmap 9" },
|
||||
#endif
|
||||
|
||||
{ NULL, NULL, OPTION_HEADER, "OSD SOUND OPTIONS" },
|
||||
{ OSDOPTION_SOUND, OSDOPTVAL_AUTO, OPTION_STRING, "sound output method: " },
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -12,15 +12,17 @@
|
||||
#ifndef _OSD_OPENGL_H
|
||||
#define _OSD_OPENGL_H
|
||||
|
||||
#if USE_OPENGL
|
||||
|
||||
/* equivalent to #include <GL/gl.h>
|
||||
* #include <GL/glext.h>
|
||||
*/
|
||||
#ifdef OSD_WINDOWS
|
||||
#ifdef _MSC_VER
|
||||
#include <windows.h>
|
||||
#include "SDL1211_opengl.h"
|
||||
#include "GL/GL.h"
|
||||
#include "bgfx/3rdparty/khronos/gl/glext.h "
|
||||
#ifndef USE_DISPATCH_GL
|
||||
#include "bgfx/3rdparty/khronos/wgl/wglext.h"
|
||||
#endif
|
||||
#else
|
||||
#include "GL/gl.h"
|
||||
#include "GL/glext.h"
|
||||
@ -107,8 +109,6 @@
|
||||
|
||||
#endif /* USE_DISPATCH_GL */
|
||||
|
||||
#endif /* USE_OPENGL */
|
||||
|
||||
#endif /* _OSD_OPENGL_H */
|
||||
|
||||
#else /* MANGLE */
|
||||
|
@ -546,12 +546,8 @@ int drawsdl2_init(running_machine &machine, osd_draw_callbacks *callbacks)
|
||||
|
||||
osd_printf_verbose("Using SDL native texturing driver (SDL 2.0+)\n");
|
||||
|
||||
#if USE_OPENGL
|
||||
// Load the GL library now - else MT will fail
|
||||
const char *stemp = downcast<sdl_options &>(machine.options()).gl_lib();
|
||||
#else
|
||||
const char *stemp = NULL;
|
||||
#endif
|
||||
if (stemp != NULL && strcmp(stemp, OSDOPTVAL_AUTO) == 0)
|
||||
stemp = NULL;
|
||||
|
||||
|
@ -122,9 +122,7 @@ public:
|
||||
const char *video_driver() const { return value(SDLOPTION_VIDEODRIVER); }
|
||||
const char *render_driver() const { return value(SDLOPTION_RENDERDRIVER); }
|
||||
const char *audio_driver() const { return value(SDLOPTION_AUDIODRIVER); }
|
||||
#if USE_OPENGL
|
||||
const char *gl_lib() const { return value(SDLOPTION_GL_LIB); }
|
||||
#endif
|
||||
|
||||
private:
|
||||
static const options_entry s_option_entries[];
|
||||
|
@ -164,9 +164,7 @@ const options_entry sdl_options::s_option_entries[] =
|
||||
{ SDLOPTION_VIDEODRIVER ";vd", OSDOPTVAL_AUTO, OPTION_STRING, "sdl video driver to use ('x11', 'directfb', ... or 'auto' for SDL default" },
|
||||
{ SDLOPTION_RENDERDRIVER ";rd", OSDOPTVAL_AUTO, OPTION_STRING, "sdl render driver to use ('software', 'opengl', 'directfb' ... or 'auto' for SDL default" },
|
||||
{ SDLOPTION_AUDIODRIVER ";ad", OSDOPTVAL_AUTO, OPTION_STRING, "sdl audio driver to use ('alsa', 'arts', ... or 'auto' for SDL default" },
|
||||
#if USE_OPENGL
|
||||
{ SDLOPTION_GL_LIB, SDLOPTVAL_GLLIB, OPTION_STRING, "alternative libGL.so to use; 'auto' for system default" },
|
||||
#endif
|
||||
|
||||
// End of list
|
||||
{ NULL }
|
||||
@ -345,7 +343,6 @@ static void defines_verbose(void)
|
||||
osd_printf_verbose("\n");
|
||||
osd_printf_verbose("SDL/OpenGL defines: ");
|
||||
osd_printf_verbose("SDL_COMPILEDVERSION=%d ", SDL_COMPILEDVERSION);
|
||||
MACRO_VERBOSE(USE_OPENGL);
|
||||
MACRO_VERBOSE(USE_DISPATCH_GL);
|
||||
osd_printf_verbose("\n");
|
||||
osd_printf_verbose("Compiler defines A: ");
|
||||
@ -487,7 +484,6 @@ void sdl_osd_interface::init(running_machine &machine)
|
||||
/* Set the SDL environment variable for drivers wanting to load the
|
||||
* lib at startup.
|
||||
*/
|
||||
#if USE_OPENGL
|
||||
/* FIXME: move lib loading code from drawogl.c here */
|
||||
|
||||
stemp = options().gl_lib();
|
||||
@ -496,7 +492,6 @@ void sdl_osd_interface::init(running_machine &machine)
|
||||
osd_setenv("SDL_VIDEO_GL_DRIVER", stemp, 1);
|
||||
osd_printf_verbose("Setting SDL_VIDEO_GL_DRIVER = '%s' ...\n", stemp);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* get number of processors */
|
||||
stemp = options().numprocessors();
|
||||
|
@ -313,14 +313,12 @@ static void check_osd_inputs(running_machine &machine)
|
||||
machine.ui().popup_time(1, "Keepaspect %s", video_config.keepaspect? "enabled":"disabled");
|
||||
}
|
||||
|
||||
#if (USE_OPENGL)
|
||||
//FIXME: on a per window basis
|
||||
if (machine.ui_input().pressed(IPT_OSD_5))
|
||||
{
|
||||
video_config.filter = !video_config.filter;
|
||||
machine.ui().popup_time(1, "Filter %s", video_config.filter? "enabled":"disabled");
|
||||
}
|
||||
#endif
|
||||
//FIXME: on a per window basis
|
||||
if (machine.ui_input().pressed(IPT_OSD_5))
|
||||
{
|
||||
video_config.filter = !video_config.filter;
|
||||
machine.ui().popup_time(1, "Filter %s", video_config.filter? "enabled":"disabled");
|
||||
}
|
||||
|
||||
if (machine.ui_input().pressed(IPT_OSD_6))
|
||||
window->modify_prescale(-1);
|
||||
@ -377,7 +375,7 @@ void sdl_osd_interface::extract_video_config()
|
||||
if (options().seconds_to_run() == 0)
|
||||
osd_printf_warning("Warning: -video none doesn't make much sense without -seconds_to_run\n");
|
||||
}
|
||||
else if (USE_OPENGL && (strcmp(stemp, SDLOPTVAL_OPENGL) == 0))
|
||||
else if (strcmp(stemp, SDLOPTVAL_OPENGL) == 0)
|
||||
video_config.mode = VIDEO_MODE_OPENGL;
|
||||
else if ((strcmp(stemp, SDLOPTVAL_SDL2ACCEL) == 0))
|
||||
{
|
||||
@ -411,64 +409,62 @@ void sdl_osd_interface::extract_video_config()
|
||||
osd_printf_warning("Invalid prescale option, reverting to '1'\n");
|
||||
video_config.prescale = 1;
|
||||
}
|
||||
#if (USE_OPENGL)
|
||||
// default to working video please
|
||||
video_config.forcepow2texture = options().gl_force_pow2_texture();
|
||||
video_config.allowtexturerect = !(options().gl_no_texture_rect());
|
||||
video_config.vbo = options().gl_vbo();
|
||||
video_config.pbo = options().gl_pbo();
|
||||
video_config.glsl = options().gl_glsl();
|
||||
if ( video_config.glsl )
|
||||
// default to working video please
|
||||
video_config.forcepow2texture = options().gl_force_pow2_texture();
|
||||
video_config.allowtexturerect = !(options().gl_no_texture_rect());
|
||||
video_config.vbo = options().gl_vbo();
|
||||
video_config.pbo = options().gl_pbo();
|
||||
video_config.glsl = options().gl_glsl();
|
||||
if ( video_config.glsl )
|
||||
{
|
||||
int i;
|
||||
|
||||
video_config.glsl_filter = options().glsl_filter();
|
||||
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
int i;
|
||||
|
||||
video_config.glsl_filter = options().glsl_filter();
|
||||
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_mame(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_mamebm[i], stemp);
|
||||
video_config.glsl_shader_mamebm_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_screen(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_scrn[i], stemp);
|
||||
video_config.glsl_shader_scrn_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
int i;
|
||||
video_config.glsl_filter = 0;
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
stemp = options().shader_mame(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_mamebm[i], stemp);
|
||||
video_config.glsl_shader_mamebm_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* USE_OPENGL */
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_screen(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_scrn[i], stemp);
|
||||
video_config.glsl_shader_scrn_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
int i;
|
||||
video_config.glsl_filter = 0;
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
// misc options: sanity check values
|
||||
|
||||
// global options: sanity check values
|
||||
|
@ -223,13 +223,11 @@ bool sdl_osd_interface::window_init()
|
||||
}
|
||||
|
||||
// initialize the drawers
|
||||
#if USE_OPENGL
|
||||
if (video_config.mode == VIDEO_MODE_OPENGL)
|
||||
{
|
||||
if (drawogl_init(machine(), &draw))
|
||||
video_config.mode = VIDEO_MODE_SOFT;
|
||||
}
|
||||
#endif
|
||||
if (video_config.mode == VIDEO_MODE_SDL2ACCEL)
|
||||
{
|
||||
if (drawsdl2_init(machine(), &draw))
|
||||
|
@ -387,10 +387,8 @@ void windows_osd_interface::extract_video_config()
|
||||
if (options().seconds_to_run() == 0)
|
||||
osd_printf_warning("Warning: -video none doesn't make much sense without -seconds_to_run\n");
|
||||
}
|
||||
#if (USE_OPENGL)
|
||||
else if (strcmp(stemp, "opengl") == 0)
|
||||
video_config.mode = VIDEO_MODE_OPENGL;
|
||||
#endif
|
||||
else
|
||||
{
|
||||
osd_printf_warning("Invalid video value %s; reverting to gdi\n", stemp);
|
||||
@ -409,64 +407,62 @@ void windows_osd_interface::extract_video_config()
|
||||
osd_printf_warning("Invalid prescale option, reverting to '1'\n");
|
||||
video_config.prescale = 1;
|
||||
}
|
||||
#if (USE_OPENGL)
|
||||
// default to working video please
|
||||
video_config.forcepow2texture = options().gl_force_pow2_texture();
|
||||
video_config.allowtexturerect = !(options().gl_no_texture_rect());
|
||||
video_config.vbo = options().gl_vbo();
|
||||
video_config.pbo = options().gl_pbo();
|
||||
video_config.glsl = options().gl_glsl();
|
||||
if ( video_config.glsl )
|
||||
// default to working video please
|
||||
video_config.forcepow2texture = options().gl_force_pow2_texture();
|
||||
video_config.allowtexturerect = !(options().gl_no_texture_rect());
|
||||
video_config.vbo = options().gl_vbo();
|
||||
video_config.pbo = options().gl_pbo();
|
||||
video_config.glsl = options().gl_glsl();
|
||||
if ( video_config.glsl )
|
||||
{
|
||||
int i;
|
||||
|
||||
video_config.glsl_filter = options().glsl_filter();
|
||||
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
int i;
|
||||
|
||||
video_config.glsl_filter = options().glsl_filter();
|
||||
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_mame(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_mamebm[i], stemp);
|
||||
video_config.glsl_shader_mamebm_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_screen(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_scrn[i], stemp);
|
||||
video_config.glsl_shader_scrn_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
int i;
|
||||
video_config.glsl_filter = 0;
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
stemp = options().shader_mame(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_mamebm[i], stemp);
|
||||
video_config.glsl_shader_mamebm_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* USE_OPENGL */
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
stemp = options().shader_screen(i);
|
||||
if (stemp && strcmp(stemp, OSDOPTVAL_NONE) != 0 && strlen(stemp)>0)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = (char *) malloc(strlen(stemp)+1);
|
||||
strcpy(video_config.glsl_shader_scrn[i], stemp);
|
||||
video_config.glsl_shader_scrn_num++;
|
||||
} else {
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
int i;
|
||||
video_config.glsl_filter = 0;
|
||||
video_config.glsl_shader_mamebm_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_mamebm[i] = NULL;
|
||||
}
|
||||
video_config.glsl_shader_scrn_num=0;
|
||||
for(i=0; i<GLSL_SHADER_MAX; i++)
|
||||
{
|
||||
video_config.glsl_shader_scrn[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
@ -25,9 +25,7 @@ enum {
|
||||
#if defined (USE_BGFX)
|
||||
VIDEO_MODE_BGFX,
|
||||
#endif
|
||||
#if (USE_OPENGL)
|
||||
VIDEO_MODE_OPENGL,
|
||||
#endif
|
||||
VIDEO_MODE_D3D
|
||||
};
|
||||
|
||||
|
@ -41,9 +41,7 @@ extern int drawd3d_init(running_machine &machine, osd_draw_callbacks *callbacks)
|
||||
#if defined(USE_BGFX)
|
||||
extern int drawbgfx_init(running_machine &machine, osd_draw_callbacks *callbacks);
|
||||
#endif
|
||||
#if (USE_OPENGL)
|
||||
extern int drawogl_init(running_machine &machine, osd_draw_callbacks *callbacks);
|
||||
#endif
|
||||
|
||||
//============================================================
|
||||
// PARAMETERS
|
||||
@ -234,10 +232,8 @@ bool windows_osd_interface::window_init()
|
||||
#endif
|
||||
if (video_config.mode == VIDEO_MODE_NONE)
|
||||
drawnone_init(machine(), &draw);
|
||||
#if (USE_OPENGL)
|
||||
if (video_config.mode == VIDEO_MODE_OPENGL)
|
||||
drawogl_init(machine(), &draw);
|
||||
#endif
|
||||
// set up the window list
|
||||
last_window_ptr = &win_window_list;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user