summaryrefslogtreecommitdiffstatshomepage
path: root/src/osd/windows/video.c
Commit message (Collapse)AuthorAgeFilesLines
* Rename *.c -> *.cpp in our source (nw) Miodrag Milanovic2015-11-081-521/+0
|
* don't include it if you don't want it (nw) Cowering2015-07-081-0/+2
|
* Fix/extend parsing of -resolution command line arg Daniel Lopez2015-06-141-1/+7
| | | | | | | | | | | In both Windows and SDL builds, format of -resolution can now be any of: <width>x<height> <width>x<height>x<depth> <width>x<height>x<depth>@<refresh> <width>x<height>@<refresh> Omitted values are defaulted to 0, at the point of parsing (as before).
* Cleanups and version bumpmame0161 Miodrag Milanovic2015-04-291-1/+1
|
* Make sure monitor refresh is called when switchres is used (SDL). Remove couriersud2015-04-211-1/+0
| | | a printf. (nw)
* Fix repetitive monitor updates. By design, MAME has an issue setting couriersud2015-04-201-2/+2
| | | | aspect correctly on monitor resolution changes. This needs to be addressed separately. [Couriersud]
* fix a leak (nw) Miodrag Milanovic2015-04-201-0/+2
|
* Fixed non-unicode builds (nw) Miodrag Milanovic2015-04-061-1/+1
|
* don't crash if malloc fails (nw) Peter Ferrie2015-03-021-1/+1
|
* Some more alignment. (nw) couriersud2015-03-011-40/+48
|
* Aligned monitor handling between sdl and baseline. [Couriersud] couriersud2015-03-011-52/+38
|
* Fix clipping bug (e.g. apparent in neogeo) for video accel. Minor code couriersud2015-03-011-4/+5
| | | changes. [Couriersud]
* OpenGL on windows now supports glsl options. This worked out of the box couriersud2015-02-281-7/+64
| | | | | | | | | with wine64 and on virtualbox windows7 (64bit). mametiny.exe gridlee -video opengl -gl_glsl -glsl_shader_mame0 shader/glsl_plain -glsl_shader_mame1 shader/TV/tv -now -gl_forcepow2texture -keepaspect [Couriersud]
* Merged sdl_video_config and win_video_config couriersud2015-02-281-2/+2
|
* C++'d more of window.c (nw) couriersud2015-02-261-1/+1
|
* Moved opengl related stuff to modules/opengl couriersud2015-02-261-5/+8
|
* More alignment of code: couriersud2015-02-221-2/+2
| | | | | | | - HDC is passed differently to gdi renderer (the only one using it). - Merged sdl_window_config and win_window_config into osd_window_config. - Use osd_window_config instead of replicating individual member variables in osd_window.
* Make OpenGL renderer available in mainline build as well. This needs to couriersud2015-02-221-50/+52
| | | | be explicitly enabled by specifying USE_OPENGL=1. More code alignment. [Couriersud]
* More code alignment for windows and renderer. (nw) couriersud2015-02-121-17/+13
|
* Added BGFX as video output. For now rendering info shown only (nw) Miodrag Milanovic2015-02-011-0/+2
|
* Cleanups and version bumpmame0155 Miodrag Milanovic2014-10-151-5/+5
|
* Added window to osd_interface (nw) Miodrag Milanovic2014-09-011-15/+30
| | | | win_monitor_info to class win_window_info to class, partial
* For windows auto is now same as d3d, till video part is redone (nw) Miodrag Milanovic2014-05-081-0/+2
|
* -Made osd_interface base class for OSD and moved initialization for each ↵ Miodrag Milanovic2014-04-251-16/+12
| | | | | | | | subsystem in it as virtual calls. (nw) -Moved midi handling in base class -Cleaned running_machine of information of next machine -All is cleaned after exiting of running_machine so debugger window is removed as well till next machine is started -Made osdmini to compile
* reverting to classic ui due to lot of issues, as much as I hate reverting ↵ Miodrag Milanovic2014-04-171-0/+28
| | | | some else code (nw)
* we anyway do not support win95 for a time :) (nw) Miodrag Milanovic2014-04-161-5/+0
|
* Moved eminline and related files into /src/osd since it's system related (nw) Miodrag Milanovic2014-04-161-5/+5
| | | | | | | | Moved delegates into /src/lib/util to enable usage of delegates in other project parts Moved mame_printf_* calls into /src/osd/osdcore.c and renamed them to osd_printf_* Changed mess.mak to display compilation of ymmu100.ppm nicely
* Merge of new menubar code Nathan Woods2014-04-121-28/+0
|
* Moved src/emu/ui.? ==> src/emu/ui/ui.?, changed to follow MAME OOP ↵ Nathan Woods2014-01-291-1/+1
| | | | conventions; we now have a ui_manager class
* Bulk convert files that already had standard BSD license in my name Aaron Giles2013-10-161-35/+2
| | | | to new license tagged form.
* "put HLSL back ..." fix build etc. David Haywood2013-06-061-0/+12
|
* As this project is clearly now run by people who care more about "feelings" ↵ Ryan Holtz2013-06-061-12/+0
| | | | | and playing patty-cake with one another rather than actual results, consider this my resignation letter. Anyone who wants to know where HLSL went, feel free to ask Tafoid why he couldn't take a simple joke.
* debugqt: prevent threading deadlock in win32 with qt debugger (nw) cracyc2013-06-041-1/+1
|
* Cleaned a bit Carl's solution for optional QT debugger for Windows (nw) Miodrag Milanovic2013-05-301-1/+1
|
* - d3dhlsl.c: Made HLSL switchable at runtime, Ctrl+Alt+F12. [MooglyGuy] Ryan Holtz2013-01-131-0/+4
|
* less ugly way to silence gcc 4.6 (no whatsnew) Miodrag Milanovic2011-12-151-2/+2
|
* Fixed warnings found by GCC 4.6.2 without change of h63484.c since that one ↵ Miodrag Milanovic2011-09-221-0/+2
| | | | is wip (no whatsnew)
* HLSL Updates: [Ryan Holtz, Bat Country Entertainment, austere, SoltanGris42] Ryan Holtz2011-05-301-0/+8
| | | | | | | - Added the ability to render screenshots at arbitrary resolutions. - Added the ability to record AVI videos (albeit with no audio) at arbitrary resolutions. - Added a 43-tap-wide FIR-based NTSC filter with tunable Y, I and Q frequency response. - Updated scanlines to have a user-tunable pixel-height ratio in addition to the current screen-height ratio. - Fixed a VRAM leak that was causing many dynamic-resolution drivers to run out of memory mid-run.
* Switch to using delegates for some callbacks: Aaron Giles2011-04-271-1/+1
| | | | | | | | | | | | - non-device timer callbacks - machine state changing callbacks - configuration callbacks - per-screen VBLANK callbacks - DRC backend callbacks For the timer case only, I added wrappers for the old-style functions. Over time, drivers should switch to device timers instead, reducing the number of timers that are directly allocated through the scheduler.
* BIG update. Aaron Giles2011-03-291-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove redundant machine items from address_space and device_t. Neither machine nor m_machine are directly accessible anymore. Instead a new getter machine() is available which returns a machine reference. So: space->machine->xxx ==> space->machine().xxx device->machine->yyy ==> device->machine().yyy Globally changed all running_machine pointers to running_machine references. Any function/method that takes a running_machine takes it as a required parameter (1 or 2 exceptions). Being consistent here gets rid of a lot of odd &machine or *machine, but it does mean a very large bulk change across the project. Structs which have a running_machine * now have that variable renamed to m_machine, and now have a shiny new machine() method that works like the space and device methods above. Since most of these are things that should eventually be devices anyway, consider this a step in that direction. 98% of the update was done with regex searches. The changes are architected such that the compiler will catch the remaining errors: // find things that use an embedded machine directly and replace // with a machine() getter call S: ->machine-> R: ->machine\(\)\. // do the same if via a reference S: \.machine-> R: \.machine\(\)\. // convert function parameters to running_machine & S: running_machine \*machine([^;]) R: running_machine \&machine\1 // replace machine-> with machine. S: machine-> R: machine\. // replace &machine() with machine() S: \&([()->a-z0-9_]+machine\(\)) R: \1 // sanity check: look for this used as a cast (running_machine &) // and change to this: *(running_machine *)
* Converted core_options to a class. Removed a bunch of marginal Aaron Giles2011-03-031-47/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | functionality in favor of alternate mechanisms. Errors are now reported via an astring rather than via callbacks. Every option must now specify a type (command, integer, float, string, boolean, etc). Command behavior has changed so that only one command is permitted. [Aaron Giles] Changed fileio system to accept just a raw searchpath instead of an options/option name combination. [Aaron Giles] Created emu_options class dervied from core_options which wraps core emulator options. Added mechanisms to cleanly change the system name and add/remove system-specific options, versus the old way using callbacks. Also added read accessors for all the options, to ensure consistency in how parameters are handled. Changed most core systems to access emu_options instead of core_options. Also changed machine->options() to return emu_options. [Aaron Giles] Created cli_options class derived from emu_options which adds the command-line specific options. Updated clifront code to leverage the new class and the new core behaviors. cli_execute() now accepts a cli_options object when called. [Aaron Giles] Updated both SDL and Windows to have their own options classes, derived from cli_options, which add the OSD-specific options on top of everything else. Added accessors for all the options so that queries are strongly typed and simplified. [Aaron Giles] Out of whatsnew: I've surely screwed up some stuff, though I have smoke tested a bunch of things. Let me know if you hit anything odd. Also I know this change will impact the WINUI stuff, please let me know if there are issues. All the functionality necessary should still be present. If it's not obvious, please talk to me before adding stuff to the core_options class.
* mame_file is now emu_file and is a class. It is required Aaron Giles2011-02-121-35/+35
| | | | | | | | | | | | | | | | | | | | | | | | to pass a core_options object to the constructor, along with a search path. This required pushing either a running_machine or a core_options through some code that wasn't previously ready to handle it. emu_files can be reused over multiple open/close sessions, and a lot of core code cleaned up nicely as things were converted to them. Also created a file_enumerator class for iterating over files in a searchpath. This replaces the old mame_openpath functions. Changed machine->options() to return a reference. Removed public nvram_open() and fixed jchan/kaneko16 to stop directly saving NVRAM. Removed most of the mame_options() calls; this will soon go away entirely, so don't add any more. Added core_options to device_validity_check() so they can be used to validate things.
* Cleaned OSD windows and emu part from NEWUI dependencies (no whatsnew) Miodrag Milanovic2011-01-131-11/+0
|
* Incorporate MESS change into MAME core. Scott Stone2010-11-061-2/+2
|
* Create new class osd_interface to house OSD callbacks. Added new Aaron Giles2010-10-211-8/+6
| | | | | | | | | module osdepend.c with default empty implementations. Changed mame_execute() and cli_execute() to accept a reference to an osd_interface which is provided by the caller. Updated SDL and Windows OSD to create an osd_interface-derived class and moved their OSD callbacks to be members.
* Fix crash when specifying -effect. Aaron Giles2010-10-161-44/+0
| | | | | | Moved -effect implementation out of OSD code and into core since the implementations were identical across Windows/SDL and implemented in the core itself.
* Converted render.c objects into C++ objects. Updated all callers. Aaron Giles2010-10-131-1/+1
|
* Split mame.c into mame.c and machine.c, the latter containing the Aaron Giles2010-06-301-20/+20
| | | | | | | | | | | | | | | | | | | running_machine definition and implementation. Moved global machine-level operations and accessors into methods on the running_machine class. For the most part, this doesn't affect drivers except for a few occasional bits: mame_get_phase() == machine->phase() add_reset_callback() == machine->add_notifier(MACHINE_NOTIFY_RESET, ...) add_exit_callback() == machine->add_notifier(MACHINE_NOTIFY_EXIT, ...) mame_get_base_datetime() == machine->base_datetime() mame_get_current_datetime() == machine->current_datetime() Cleaned up the region_info class, removing most global region accessors except for memory_region() and memory_region_length(). Again, this doesn't generally affect drivers.
* Remove stray bitmap_free's. Aaron Giles2010-06-081-2/+1
|
* WARNING: There are likely to be regressions in both functionality and Aaron Giles2010-06-081-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | performance as a result of this change. Do not panic; report issues to the list in the short term and I will look into them. There are probably also some details I forgot to mention. Please ask questions if anything is not clear. NOTE: This is a major internal change to the way devices are handled in MAME. There is a small impact on drivers, but the bulk of the changes are to the devices themselves. Full documentation on the new device handling is in progress at http://mamedev.org/devwiki/index.php/MAME_Device_Basics Defined two new casting helpers: [Aaron Giles] downcast<type>(value) should be used for safe and efficient downcasting from a base class to a derived class. It wraps static_cast<> by adding an assert that a matching dynamic_cast<> returns the same result in debug builds. crosscast<type>(value) should be used for safe casting from one type to another in multiple inheritance scenarios. It compiles to a dynamic_cast<> plus an assert on the result. Since it does not optimize down to static_cast<>, you should prefer downcast<> over crosscast<> when you can. Redefined running_device to be a proper C++ class (now called device_t). Same for device_config (still called device_config). All devices and device_configs must now be derived from these base classes. This means each device type now has a pair of its own unique classes that describe the device. Drivers are encouraged to use the specific device types instead of the generic running_device or device_t classes. Drivers that have a state class defined in their header file are encouraged to use initializers off the constructor to locate devices. [Aaron Giles] Removed the following fields from the device and device configuration classes as they never were necessary or provided any use: device class, device family, source file, version, credits. [Aaron Giles] Added templatized variant of machine->device() which performs a downcast as part of the device fetch. Thus machine->device<timer_device>("timer") will locate a device named "timer", downcast it to a timer_device, and assert if the downcast fails. [Aaron Giles] Removed most publically accessible members of running_device/device_t in favor of inline accessor functions. The only remaining public member is machine. Thus all references to device->type are now device->type(), etc. [Aaron Giles] Created a number of device interface classes which are designed to be mix- ins for the device classes, providing specific extended functionality and information. There are standard interface classes for sound, execution, state, nvram, memory, and disassembly. Devices can opt into 0 or more of these classes. [Aaron Giles] Converted the classic CPU device to a standard device that uses the execution, state, memory, and disassembly interfaces. Used this new class (cpu_device) to implement the existing CPU device interface. In the future it will be possible to convert each CPU core to its own device type, but for now they are still all CPU devices with a cpu_type() that specifies exactly which kind of CPU. [Aaron Giles] Created a new header devlegcy.h which wraps the old device interface using some special template classes. To use these with an existing device, simply remove from the device header the DEVICE_GET_INFO() declaration and the #define mapping the ALL_CAPS name to the DEVICE_GET_INFO. In their place #include "devlegcy.h" and use the DECLARE_LEGACY_DEVICE() macro. In addition, there is a DECLARE_LEGACY_SOUND_DEVICE() macro for wrapping existing sound devices into new-style devices, and a DECLARE_LEGACY_NVRAM_DEVICE() for wrapping NVRAM devices. Also moved the token and inline_config members to the legacy device class, as these are not used in modern devices. [Aaron Giles] Converted the standard base devices (VIDEO_SCREEN, SPEAKER, and TIMER) from legacy devices to the new C++ style. Also renamed VIDEO_SCREEN to simply SCREEN. The various global functions that were previously used to access information or modify the state of these devices are now replaced by methods on the device classes. Specifically: video_screen_configure() == screen->configure() video_screen_set_visarea() == screen->set_visible_area() video_screen_update_partial() == screen->update_partial() video_screen_update_now() == screen->update_now() video_screen_get_vpos() == screen->vpos() video_screen_get_hpos() == screen->hpos() video_screen_get_vblank() == screen->vblank() video_screen_get_hblank() == screen->hblank() video_screen_get_width() == screen->width() video_screen_get_height() == screen->height() video_screen_get_visible_area() == screen->visible_area() video_screen_get_time_until_pos() == screen->time_until_pos() video_screen_get_time_until_vblank_start() == screen->time_until_vblank_start() video_screen_get_time_until_vblank_end() == screen->time_until_vblank_end() video_screen_get_time_until_update() == screen->time_until_update() video_screen_get_scan_period() == screen->scan_period() video_screen_get_frame_period() == screen->frame_period() video_screen_get_frame_number() == screen->frame_number() timer_device_adjust_oneshot() == timer->adjust() timer_device_adjust_periodic() == timer->adjust() timer_device_reset() == timer->reset() timer_device_enable() == timer->enable() timer_device_enabled() == timer->enabled() timer_device_get_param() == timer->param() timer_device_set_param() == timer->set_param() timer_device_get_ptr() == timer->get_ptr() timer_device_set_ptr() == timer->set_ptr() timer_device_timeelapsed() == timer->time_elapsed() timer_device_timeleft() == timer->time_left() timer_device_starttime() == timer->start_time() timer_device_firetime() == timer->fire_time() Updated all drivers that use the above functions to fetch the specific device type (timer_device or screen_device) and call the appropriate method. [Aaron Giles] Changed machine->primary_screen and the 'screen' parameter to VIDEO_UPDATE to specifically pass in a screen_device object. [Aaron Giles] Defined a new custom interface for the Z80 daisy chain. This interface behaves like the standard interfaces, and can be added to any device that implements the Z80 daisy chain behavior. Converted all existing Z80 daisy chain devices to new-style devices that inherit this interface. [Aaron Giles] Changed the way CPU state tables are built up. Previously, these were data structures defined by a CPU core which described all the registers and how to output them. This functionality is now part of the state interface and is implemented via the device_state_entry class. Updated all CPU cores which were using the old data structure to use the new form. The syntax is currently awkward, but will be cleaner for CPUs that are native new devices. [Aaron Giles] Converted the okim6295 and eeprom devices to the new model. These were necessary because they both require multiple interfaces to operate and it didn't make sense to create legacy device templates for these single cases. (okim6295 needs the sound interface and the memory interface, while eeprom requires both the nvram and memory interfaces). [Aaron Giles] Changed parameters in a few callback functions from pointers to references in situations where they are guaranteed to never be NULL. [Aaron Giles] Removed MDRV_CPU_FLAGS() which was only used for disabling a CPU. Changed it to MDRV_DEVICE_DISABLE() instead. Updated drivers. [Aaron Giles] Reorganized the token parsing for machine configurations. The core parsing code knows how to create/replace/remove devices, but all device token parsing is now handled in the device_config class, which in turn will make use of any interface classes or device-specific token handling for custom token processing. [Aaron Giles] Moved many validity checks out of validity.c and into the device interface classes. For example, address space validation is now part of the memory interface class. [Aaron Giles] Consolidated address space parameters (bus width, endianness, etc.) into a single address_space_config class. Updated all code that queried for address space parameters to use the new mechanism. [Aaron Giles]