summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/diimage.c
Commit message (Collapse)AuthorAgeFilesLines
* Cleanups and version bumpmame0142u6 Angelo Salese2011-06-191-1/+1
|
* Converted printer image device to modern (no whatsnew) Miodrag Milanovic2011-06-141-1/+29
|
* Cleanup of image device base classes and prepare for rewrite (no whatsnew) Miodrag Milanovic2011-06-101-1/+465
|
* Removed memory allocation calls from image device (no whatsnew) Miodrag Milanovic2011-05-251-42/+0
|
* Fixed problem with image devices due to same name in interface and device ↵ Miodrag Milanovic2011-05-041-2/+2
| | | | class (no whatsnew)
* diimage.c: fix uninitialized variables found by Valgrind [R. Belmont] R. Belmont2011-05-011-1/+3
|
* Collapsed device_config and device_t into one class. Updated all Aaron Giles2011-04-271-61/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | existing modern devices and the legacy wrappers to work in this environment. This in general greatly simplifies writing a modern device. [Aaron Giles] General notes: * some more cleanup probably needs to happen behind this change, but I needed to get it in before the next device modernization or import from MESS :) * new template function device_creator which automatically defines the static function that creates the device; use this instead of creating a static_alloc_device_config function * added device_stop() method which is called at around the time the previous device_t's destructor was called; if you auto_free anything, do it here because the machine is gone when the destructor is called * changed the static_set_* calls to pass a device_t & instead of a device_config * * for many devices, the static config structure member names over- lapped the device's names for devcb_* functions; in these cases the members in the interface were renamed to have a _cb suffix * changed the driver_enumerator to only cache 100 machine_configs because caching them all took a ton of memory; fortunately this implementation detail is completely hidden behind the driver_enumerator interface * got rid of the macros for creating derived classes; doing it manually is now clean enough that it isn't worth hiding the details in a macro
* (Big tangle of changes that all happened as I was looking into the ROM Aaron Giles2011-04-131-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | loader rewrite, which is still in progress....) Replaced mamedriv.c with a new driver list mechanism that is generated by the build tools. The emulator core now expects the presence of a file called src/$(TARGET)/$(SUBTARGET).lst which is just a raw list of driver names, one per line. C and C++ comments are still permitted. This file is parsed by a new build tool makelist which extracts the driver names, sorts them, and generates a file called drivlist.c, which is consumed by the core. [Aaron Giles] Added new osdcore function osd_malloc_array() which is identical to osd_malloc() but obviously hints that the underlying allocation is for an array. Updated all callers to use the appropriate form. Modified the Windows allocator to only use guard pages for array-style allocations, allowing us to enable them once again in debug builds. [Aaron Giles] Created new static class driver_list to wrap accesses to the list of available drivers. Improved speed of driver lookups by relying on the presorting done by makelist. [Aaron Giles] Created helper class driver_enumerator as a helper for iterating through the list of drivers. This class supports basic filtering and iteration, and also serves as a temporary cache of machine_configs. [Aaron Giles] Created cli_frontend object to wrap all the CLI handling code in clifront.c. Updated/simplified all the code to take advantage of the driver_enumerator. [Aaron Giles] Created media_auditor object to wrap all the auditing functions in audit.c. Updated all users to the new interface. Note that the new auditing mechanism is slightly out of sync with the romload code in terms of finding ROMs owned by devices, so it may mis-report some issues until the new ROM loading code is in. [Aaron Giles] Added concept of a per-device searchpath. For most devices, their searchpath is just the short name of the device. For driver_devices, the searchpath is driver[;parent[;bios]]. This searchpath will eventually be used by the rom loader to find ROMs. For now it is used by the media auditor only. [Aaron Giles] Created info_xml_creator object to wrap all the info generation functions in info.c. Converted the file to C++ and cleaned up the input processing code. [Aaron Giles] (not for whatsnew ... Known issues: auditing of CHDs appears busted, and debug builds report unfreed memory if you use the built-in game picker)
* cartslot.c/chd_cd.c: added support for a callback function to test softlist ↵ Fabio Priuli2011-04-071-1/+1
| | | | | sharedfeat (e.g. 'compatibility') and display a warning message accordingly. updated cdi.c as an example [Fabio Priuli] support for floppy and tapes is in progress, but I have to discuss with Micko first :)
* BIG update. Aaron Giles2011-03-291-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 *)
* Cleanup of machine.h. Shuffled some fields around, and moved several Aaron Giles2011-03-281-3/+3
| | | | | | | | | | | | | to private member variables with accessors: machine->m_respool ==> machine->respool() machine->config ==> machine->config() machine->gamedrv ==> machine->system() machine->m_regionlist ==> machine->first_region() machine->sample_rate ==> machine->sample_rate() Also converted internal lists to use simple_list.
* Removed hashfile and dependencies (no whatsnew) Miodrag Milanovic2011-02-141-44/+0
|
* Hash generation and general cleanup. New class hash_collection holds Aaron Giles2011-02-141-36/+12
| | | | | | | | | | | and manages a collection of hashes, and can be built from an internal format string which is stored with each ROM. All core instances are cleaned up to use the new interfaces, but it's likely that hashfile code in MESS will need an update. Also compacted the form of the hash strings used for ROMs, and fixed verification/hashing of non-ZIPped files.
* mame_file is now emu_file and is a class. It is required Aaron Giles2011-02-121-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | 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.
* Ok, last major rename for this round: Aaron Giles2011-01-011-2/+2
| | | | | | | | | | | | | | | | memory_region() == machine->region()->base() memory_region_length() == machine->region()->bytes() region_info -> memory_region Regex searches: S: memory_region( *)\(( *)([^,&]+), *([^)]+)\) R: \3->region\1\(\2\4\)->base\(\) S: memory_region_length( *)\(( *)([^,&]+), *([^)]+)\) R: \3->region\1\(\2\4\)->bytes\(\)
* Swap: (astring.len() != 0) -> astring Aaron Giles2010-08-211-5/+5
| | | | Swap: (astring.len() == 0) -> !astring
* Fixed image device error handling [ShimaPong, Miodrag Milanovic] Miodrag Milanovic2010-08-041-15/+13
|
* Fixed image based cheat file loading (no whatsnew) Miodrag Milanovic2010-07-281-6/+5
|
* Cleanups and version bump.mame0138u4 Aaron Giles2010-07-221-1/+1
|
* Adding ability to support other types of software lists, so floppies, ↵ Miodrag Milanovic2010-07-081-0/+1
| | | | cassettes, cd-roms are now possible to be used [Miodrag Milanovic]
* Cleanups and version bump.mame0138u3 Aaron Giles2010-07-061-10/+10
|
* Added new static call in diimage and added call to initialize subdevices for ↵ Miodrag Milanovic2010-06-291-0/+15
| | | | image device (no whatsnew)
* Implemented hash file and battery support and did some cleanup (no whatsnew) Miodrag Milanovic2010-06-241-1/+195
|
* - Moved ioproc implementation from MESS [Miodrag Milanovic] Miodrag Milanovic2010-06-231-9/+40
| | | - Implemented more image device calls, and did some cleanup (no whatsnew)
* - Moved softlist implementation from MESS [Miodrag Milanovic] Miodrag Milanovic2010-06-201-42/+143
| | | | | - Moved image related UI from MESS to emu core - Reimplemented filename related image device calls
* fix Linux 64-bit compile (no whatsnew) R. Belmont2010-06-191-1/+1
|
* Prevent some overrides of exiting variables, implementation will be updated ↵ Miodrag Milanovic2010-06-181-2/+2
| | | | later (no whatsnew)
* Implemented most of calls for image device (no whatsnew) Miodrag Milanovic2010-06-181-2/+192
|
* - removed MESS dependency from config.c Miodrag Milanovic2010-06-171-1/+55
| | | | | | | | - moved image legacy device implementation to devimage.c - created image.c implementation with initialization of devices/configuration for image devices, used those calls from mame.c - some minor cleanup of legacy device and initial implementation of some calls (no whatsnew for now, this is just for log,will put more info on final commit)
* devlegacy.c,clifront.c,info.c [Miodrag Milanovic] Miodrag Milanovic2010-06-151-0/+89
- Created legacy image device - Moved opresolv implementation from MESS - listmedia is option is available in MAME too - listxml output now contains image devices