diff options
Diffstat (limited to 'src/osd/windows')
| -rw-r--r-- | src/osd/windows/d3dhlsl.h | 4 | ||||
| -rw-r--r-- | src/osd/windows/drawbgfx.c | 116 | ||||
| -rw-r--r-- | src/osd/windows/drawdd.c | 4 | ||||
| -rw-r--r-- | src/osd/windows/drawgdi.c | 2 | ||||
| -rw-r--r-- | src/osd/windows/video.h | 2 | ||||
| -rw-r--r-- | src/osd/windows/window.h | 30 | ||||
| -rw-r--r-- | src/osd/windows/windows.mak | 4 |
7 files changed, 80 insertions, 82 deletions
diff --git a/src/osd/windows/d3dhlsl.h b/src/osd/windows/d3dhlsl.h index 7f3a6bdf169..8b8904123b2 100644 --- a/src/osd/windows/d3dhlsl.h +++ b/src/osd/windows/d3dhlsl.h @@ -335,8 +335,8 @@ private: base * d3dintf; // D3D interface - running_machine * machine; - d3d::renderer * d3d; // D3D renderer + running_machine * machine; + d3d::renderer * d3d; // D3D renderer bool master_enable; // overall enable flag bool vector_enable; // vector post-processing enable flag diff --git a/src/osd/windows/drawbgfx.c b/src/osd/windows/drawbgfx.c index 1444138a0ad..3061f32b591 100644 --- a/src/osd/windows/drawbgfx.c +++ b/src/osd/windows/drawbgfx.c @@ -19,7 +19,7 @@ // MAMEOS headers #include "window.h" -#include <bgfxplatform.h> +#include <bgfxplatform.h> #include <bgfx.h> class renderer_bgfx : public osd_renderer @@ -95,7 +95,7 @@ int renderer_bgfx::create() bgfx::winSetHwnd(window().m_hwnd); bgfx::init(); bgfx::reset(rect_width(&client), rect_height(&client), BGFX_RESET_VSYNC); - + // Enable debug text. bgfx::setDebug(BGFX_DEBUG_STATS);// BGFX_DEBUG_TEXT); @@ -165,70 +165,70 @@ int renderer_bgfx::draw(int update) */ case render_primitive::LINE: // check if it's really a point -/* - if (((prim->bounds.x1 - prim->bounds.x0) == 0) && ((prim->bounds.y1 - prim->bounds.y0) == 0)) - { - curPrimitive=GL_POINTS; - } else { - curPrimitive=GL_LINES; - } - - if(pendingPrimitive!=GL_NO_PRIMITIVE && pendingPrimitive!=curPrimitive) - { - glEnd(); - pendingPrimitive=GL_NO_PRIMITIVE; - } - - if ( pendingPrimitive==GL_NO_PRIMITIVE ) - { - set_blendmode(sdl, PRIMFLAG_GET_BLENDMODE(prim->flags)); - } - - glColor4f(prim->color.r, prim->color.g, prim->color.b, prim->color.a); - - if(pendingPrimitive!=curPrimitive) - { - glBegin(curPrimitive); - pendingPrimitive=curPrimitive; - } - - // check if it's really a point - if (curPrimitive==GL_POINTS) - { - glVertex2f(prim->bounds.x0+hofs, prim->bounds.y0+vofs); - } - else - { - glVertex2f(prim->bounds.x0+hofs, prim->bounds.y0+vofs); - glVertex2f(prim->bounds.x1+hofs, prim->bounds.y1+vofs); - }*/ +/* + if (((prim->bounds.x1 - prim->bounds.x0) == 0) && ((prim->bounds.y1 - prim->bounds.y0) == 0)) + { + curPrimitive=GL_POINTS; + } else { + curPrimitive=GL_LINES; + } + + if(pendingPrimitive!=GL_NO_PRIMITIVE && pendingPrimitive!=curPrimitive) + { + glEnd(); + pendingPrimitive=GL_NO_PRIMITIVE; + } + + if ( pendingPrimitive==GL_NO_PRIMITIVE ) + { + set_blendmode(sdl, PRIMFLAG_GET_BLENDMODE(prim->flags)); + } + + glColor4f(prim->color.r, prim->color.g, prim->color.b, prim->color.a); + + if(pendingPrimitive!=curPrimitive) + { + glBegin(curPrimitive); + pendingPrimitive=curPrimitive; + } + + // check if it's really a point + if (curPrimitive==GL_POINTS) + { + glVertex2f(prim->bounds.x0+hofs, prim->bounds.y0+vofs); + } + else + { + glVertex2f(prim->bounds.x0+hofs, prim->bounds.y0+vofs); + glVertex2f(prim->bounds.x1+hofs, prim->bounds.y1+vofs); + }*/ break; case render_primitive::QUAD: /* - if(pendingPrimitive!=GL_NO_PRIMITIVE) - { - glEnd(); - pendingPrimitive=GL_NO_PRIMITIVE; - } + if(pendingPrimitive!=GL_NO_PRIMITIVE) + { + glEnd(); + pendingPrimitive=GL_NO_PRIMITIVE; + } + + glColor4f(prim->color.r, prim->color.g, prim->color.b, prim->color.a); - glColor4f(prim->color.r, prim->color.g, prim->color.b, prim->color.a); + set_blendmode(sdl, PRIMFLAG_GET_BLENDMODE(prim->flags)); - set_blendmode(sdl, PRIMFLAG_GET_BLENDMODE(prim->flags)); + texture = texture_update(window, prim, 0); - texture = texture_update(window, prim, 0); - - sdl->texVerticex[0]=prim->bounds.x0 + hofs; - sdl->texVerticex[1]=prim->bounds.y0 + vofs; - sdl->texVerticex[2]=prim->bounds.x1 + hofs; - sdl->texVerticex[3]=prim->bounds.y0 + vofs; - sdl->texVerticex[4]=prim->bounds.x1 + hofs; - sdl->texVerticex[5]=prim->bounds.y1 + vofs; - sdl->texVerticex[6]=prim->bounds.x0 + hofs; - sdl->texVerticex[7]=prim->bounds.y1 + vofs; + sdl->texVerticex[0]=prim->bounds.x0 + hofs; + sdl->texVerticex[1]=prim->bounds.y0 + vofs; + sdl->texVerticex[2]=prim->bounds.x1 + hofs; + sdl->texVerticex[3]=prim->bounds.y0 + vofs; + sdl->texVerticex[4]=prim->bounds.x1 + hofs; + sdl->texVerticex[5]=prim->bounds.y1 + vofs; + sdl->texVerticex[6]=prim->bounds.x0 + hofs; + sdl->texVerticex[7]=prim->bounds.y1 + vofs; - glDrawArrays(GL_QUADS, 0, 4); + glDrawArrays(GL_QUADS, 0, 4); */ break; @@ -238,7 +238,7 @@ int renderer_bgfx::draw(int update) } window().m_primlist->release_lock(); - // Advance to next frame. Rendering thread will be kicked to + // Advance to next frame. Rendering thread will be kicked to // process submitted rendering primitives. bgfx::frame(); diff --git a/src/osd/windows/drawdd.c b/src/osd/windows/drawdd.c index 195a3190573..f56ffd4b989 100644 --- a/src/osd/windows/drawdd.c +++ b/src/osd/windows/drawdd.c @@ -140,8 +140,8 @@ struct monitor_enum_info /* mode_enum_info holds information during a display mode enumeration */ struct mode_enum_info { - renderer_dd * renderer; - osd_window * window; + renderer_dd * renderer; + osd_window * window; INT32 minimum_width, minimum_height; INT32 target_width, target_height; double target_refresh; diff --git a/src/osd/windows/drawgdi.c b/src/osd/windows/drawgdi.c index 86baf429202..ccbbc6c03eb 100644 --- a/src/osd/windows/drawgdi.c +++ b/src/osd/windows/drawgdi.c @@ -94,7 +94,6 @@ static void drawgdi_exit(void) int renderer_gdi::create() { - // fill in the bitmap info header bminfo.bmiHeader.biSize = sizeof(bminfo.bmiHeader); bminfo.bmiHeader.biPlanes = 1; @@ -117,7 +116,6 @@ int renderer_gdi::create() void renderer_gdi::destroy() { - // free the bitmap memory if (bmdata != NULL) global_free_array(bmdata); diff --git a/src/osd/windows/video.h b/src/osd/windows/video.h index 5cd54455213..79aca4d5b4d 100644 --- a/src/osd/windows/video.h +++ b/src/osd/windows/video.h @@ -64,7 +64,7 @@ private: MONITORINFOEX m_info; // most recently retrieved info float m_aspect; // computed/configured aspect ratio of the physical device - char * m_name; + char * m_name; }; diff --git a/src/osd/windows/window.h b/src/osd/windows/window.h index 882f0aef00d..7e99ec04b38 100644 --- a/src/osd/windows/window.h +++ b/src/osd/windows/window.h @@ -53,7 +53,7 @@ public: #endif m_prescale(1), m_primlist(NULL) - {} + {} virtual ~osd_window() { } virtual render_target *target() = 0; @@ -81,18 +81,18 @@ public: virtual win_monitor_info *winwindow_video_window_monitor(const RECT *proposed) = 0; // window handle and info - HWND m_hwnd; - HDC m_dc; // only used by GDI renderer! + HWND m_hwnd; + HDC m_dc; // only used by GDI renderer! // FIXME: this is the same as win_window_list->m_hwnd, i.e. first window. // During modularization, this should be passed in differently - HWND m_focus_hwnd; + HWND m_focus_hwnd; - int m_resize_state; + int m_resize_state; #endif - osd_window_config m_win_config; - int m_prescale; - render_primitive_list * m_primlist; + osd_window_config m_win_config; + int m_prescale; + render_primitive_list * m_primlist; }; class osd_renderer @@ -100,13 +100,13 @@ class osd_renderer public: /* Generic flags */ - static const int FLAG_NONE = 0x0000; - static const int FLAG_NEEDS_OPENGL = 0x0001; - static const int FLAG_HAS_VECTOR_SCREEN = 0x0002; + static const int FLAG_NONE = 0x0000; + static const int FLAG_NEEDS_OPENGL = 0x0001; + static const int FLAG_HAS_VECTOR_SCREEN = 0x0002; /* SDL 1.2 flags */ - static const int FLAG_NEEDS_DOUBLEBUF = 0x0100; - static const int FLAG_NEEDS_ASYNCBLIT = 0x0200; + static const int FLAG_NEEDS_DOUBLEBUF = 0x0100; + static const int FLAG_NEEDS_ASYNCBLIT = 0x0200; osd_renderer(osd_window *window, const int flags) : m_window(window), m_flags(flags) { } @@ -139,11 +139,11 @@ public: protected: /* Internal flags */ - static const int FI_CHANGED = 0x010000; + static const int FI_CHANGED = 0x010000; private: - osd_window *m_window; + osd_window *m_window; int m_flags; }; diff --git a/src/osd/windows/windows.mak b/src/osd/windows/windows.mak index 631c70dc3bb..62c9c11c74c 100644 --- a/src/osd/windows/windows.mak +++ b/src/osd/windows/windows.mak @@ -399,7 +399,7 @@ OSDOBJS = \ $(OSDOBJ)/modules/netdev/none.o \ ifdef USE_OPENGL -OSDOBJS += $(WINOBJ)/../sdl/drawogl.o $(WINOBJ)/../sdl/gl_shader_tool.o $(WINOBJ)/../sdl/gl_shader_mgr.o +OSDOBJS += $(WINOBJ)/../sdl/drawogl.o $(WINOBJ)/../sdl/gl_shader_tool.o $(WINOBJ)/../sdl/gl_shader_mgr.o OBJDIRS += $(WINOBJ)/../sdl DEFS += -DUSE_OPENGL=1 @@ -414,7 +414,7 @@ DEFS += -DUSE_SDL_SOUND endif ifndef DONT_USE_NETWORK -DEFS += -DSDLMAME_NET_PCAP +DEFS += -DSDLMAME_NET_PCAP endif CCOMFLAGS += -DDIRECT3D_VERSION=0x0900 |
