Commit Graph

2787 Commits

Author SHA1 Message Date
Olivier Galibert
2180679a35 d64: update following sector extraction evolution 2021-03-30 14:24:14 +02:00
Robbbert
c5f293954d trs80m3: Added support for high-speed CAS files. 2021-03-29 04:19:43 +11:00
Robbbert
648374e435 trs80: fixed loading of CAS files 2021-03-28 21:08:40 +11:00
Vas Crabb
e298c31a69 srcclean in preparation for release 2021-03-28 14:34:50 +11:00
Michael Zapf
cc790e4315 ti99: Fixed some rarely used TDF floppy format variants. 2021-03-21 16:29:56 +01:00
AJR
d578fa0744 Restore validation for command-line and .ini options (disabled since 0.188) and make some errors non-fatal 2021-03-21 10:48:55 -04:00
Olivier Galibert
40acc597d4 netlist: Relicensing of the GPL code to BSD-3 with the blessing of the
copyright owners.  Much thanks for that Couriersud, the main creator
and contributor, but also to Jonathan Gevaryahu and Sergey Svishchev.

There are small remnants in machine/NL_*, specifially breakout, pong
doubles and rebound that are also copyrighted by the DICE team,
whoever that means.  They're not critical since they only concern
these drivers and not an important core subsystem.
2021-03-09 09:26:00 +01:00
arbee
444470572b ap_dsk35: updates [R. Belmont]
- Set form factor for 2mg and dc42 disks so the SuperDrive can handle them
- Accept ProDOS-format dc42 3.5" disks
2021-03-06 13:14:56 -05:00
Olivier Galibert
a0a57763ab 2mg: tolerate a standard mistake 2021-03-05 20:22:23 +01:00
AJR
ad3fa37944 corefile.cpp: Make core_filename_extract_base behave more robustly in degenerate cases 2021-03-05 11:32:37 -05:00
Olivier Galibert
e0da4a9f27 C++ wart. Why can't the C++ standard say that the default destructor of a class that has inheritance or virtual methods is automatically virtual? But thou shalt is a little annoying 2021-03-05 13:41:18 +01:00
Olivier Galibert
381e15a711 fs_prodos: Explain the init better
floppy: Don't fail creation because the extension is unknown
2021-03-05 12:43:52 +01:00
Olivier Galibert
92326e47af floppy: Beginning of the support for preformatted floppy images.
What's missing:
- parameters (like the disk name when it exists)
- possibly a cleanup of ram_open and friends (but not sure of the appropriate direction in which to go)
2021-03-05 10:17:20 +01:00
Olivier Galibert
61b7e54fea itt3030: Add missing terminator 2021-03-04 14:57:11 +01:00
Olivier Galibert
551714138a apple_gcr: Refuse 800K images on single-sided drives 2021-03-04 13:48:34 +01:00
Dirk Best
e5d1cec868 formats: Fix missed RC759 format 2021-03-04 11:24:17 +01:00
Olivier Galibert
d436cbd3a6 formats: Create mame_formats_full_list which gives access to all the supported formats, make floptool use it. Castool should use it too probably, but I don't want to touch it. 2021-03-04 10:14:24 +01:00
Dirk Best
23769b0970 rc759: Add RTC and floppy, start cleanup 2021-03-03 13:38:54 +01:00
Olivier Galibert
a52b69d27c Fix dependencies 2021-03-02 20:51:01 +01:00
Olivier Galibert
1c177c16a6 flopimg: don't fault on nibble extraction on degenerated tracks 2021-03-02 09:32:11 +01:00
Olivier Galibert
439f28144f upd765_dsk, wd177x_dsk: Do not crash on damaged disks 2021-02-26 13:47:10 +01:00
Vas Crabb
a425bd5d90 srcclean in preparation for branching release 2021-02-21 16:08:12 +11:00
Olivier Galibert
b9511ec83f mfi: Don't crash on a fully unformatted disk 2021-02-20 16:08:22 +01:00
Olivier Galibert
a4489dcdb4 woz: Correct trks chunk size 2021-02-16 21:55:12 +01:00
Olivier Galibert
26bf6638a9 woz: Add write
some formats: Correct setting up of form factor and variant
2021-02-15 23:45:00 +01:00
Olivier Galibert
ea3904bdf4 woz: Fix 2.0 format track length 2021-02-15 20:22:10 +01:00
AJR
bc0146c203 Eliminate ARRAY_LENGTH template in favor of C++17's std::size
* osdcomm.h: Move definition of EQUIVALENT_ARRAY to coretmpl.h

* sharc.cpp, gt64xxx.cpp, ym2413.cpp, gb_lcd.cpp, snes_ppu.cpp: Use STRUCT_MEMBER for save state registration

* gio/newport.cpp, megadrive/svp.cpp, nes_ctrl/bcbattle.cpp, arm7.cpp, tms9995.cpp, pckeybrd.cpp, sa1110.cpp, sa1111.cpp, jangou_blitter.cpp, vic4567.cpp: Use std::fill(_n) instead of memset

* emucore.h: Remove obsolete typedef
2021-02-14 11:05:57 -05:00
AJR
71c868f75f util/palette.cpp: Fix assertion failure in some GCC builds 2021-02-10 13:33:36 -05:00
arbee
1029a103aa ap_dsk35: make .2MG its own separate format handler [R. Belmont] 2021-02-05 22:55:12 -05:00
arbee
9a4421810c ap_dsk35: support .2MG images in the new-style apple_gcr_format [R. Belmont] 2021-02-04 19:27:34 -05:00
Olivier Galibert
9399502542 2gs: Fixes, and more fixes 2021-02-04 22:00:57 +01:00
AJR
c47ed0112e coretmpl.h: Move lru_cache_map to separate header 2021-02-03 17:42:14 -05:00
Olivier Galibert
9bb34aec20 flopimg: Fix wrapping on mac sector extraction 2021-01-31 19:15:16 +01:00
leesaudan2
3fc703e806
Added Apple 2 disk image format: .nib (read-only support) (#7725)
This format was not supported by the new floppy subsystem.
This commit provides read-only support of .nib files.
2021-01-30 19:35:58 +01:00
Stiletto
3153838929
Update "2020" text to "2021" (#7713)
Update "2020" text to "2021".
2021-01-28 00:11:17 -05:00
Vas Crabb
78f6ff34a5 srcclean in preparation for branching release 2021-01-24 13:33:07 +11:00
Olivier Galibert
2cb2bdc1a0 flopimg: Fix gcr checksum 2021-01-22 16:23:11 +01:00
Olivier Galibert
aa33ec1273 ATTR_UNUSED, do you welcome C++17 in your heart and mind? 2021-01-22 13:23:58 +01:00
Olivier Galibert
bd2db8dcc6 flopimg: Change the extracted bitstreams into vector<bool>
flopimg: Change the extracted sectors into vector<vector<uint8_t>>
flopimg: Add a Mac sector extraction
apple 3.5 gcr: Generalize track creation/extraction
apple 3.5 gcr: Add a pure sector format
2021-01-22 00:02:30 +01:00
AJR
91921618c2 Much more core std::string_view modernization
- Remove corestr.h from emu.h; update a few source files to not use it at all
- Change strtrimspace, strtrimrightspace and core_filename_extract_* to be pure functions taking a std::string_view by value and returning the same type
- Change strmakeupper and strmakelower to be pure functions taking a std::string_view and constructing a std::string
- Remove the string-modifying version of zippath_parent
- Change tag-based lookup functions in device_t to take std::string_view instead of const std::string & or const char *
- Remove the subdevice tag cache from device_t (since device finders are now recommended) and replace it with a map covering directly owned subdevices only
- Move the working directory setup method out of device_image_interface (only the UI seems to actually use the full version of this)
- Change output_manager to use std::string_view for output name arguments
- Change core_options to accept std::string_view for most name and value arguments (return values are still C strings for now)
- Change miscellaneous other functions to accept std::string_view arguments
- Remove a few string accessor macros from romload.h
- Remove many unnecessary c_str() calls from logging/error messages
2021-01-20 18:06:15 -05:00
Olivier Galibert
bb7b375aa6 dc42: better cell size on save and remove extraneous logging 2021-01-17 11:40:20 +01:00
Olivier Galibert
1b20d1f218 swim2: Add reading, writing gcr up to track 63. 2021-01-15 20:39:21 +01:00
fulivi
fad7c9e0be
hp2640.cpp: Added tape emulation. (#7625)
* formats/hti_tape.cpp: Added support for Manchester encoded DC100 cassettes.
* machine/hp2640_tape.cpp: added emulation of DC100 tape drives.
* machine/hp_dc100_tape.cpp: Added unit name display.
2021-01-12 23:29:30 +11:00
arbee
81e5960881 imd_dsk: restore # of tracks check [R. Belmont] 2021-01-10 16:35:20 -05:00
arbee
73618d95de imd_dsk: use has_variant() and accept either HD or QD as 80-track drives [R. Belmont] 2021-01-10 07:53:36 -05:00
arbee
a3f159f097 imd_dsk: add missing file [R. Belmont] 2021-01-09 19:16:13 -05:00
arbee
30ad3e4674 imd_fmt.cpp: if an IMD image is 40 track but the drive is HD, put the data on even tracks like hardware would show [R. Belmont] 2021-01-09 19:05:52 -05:00
Olivier Galibert
23af0ace46 Provide the variants to the floppy formats 2021-01-09 21:42:29 +01:00
AJR
4d0ecd468d zippath.cpp: Checkpoint #2
- Fix unintialized variable issue in zippath_resolve
- Eliminate one internal helper function
2021-01-08 10:35:04 -05:00
Vas Crabb
4fd3a17070 util/zippath.cpp: Fix suffix for zip archives. 2021-01-08 04:10:10 +11:00
AJR
29e96c84a8 zippath.cpp: Checkpoint
- Adopt std::string_view as the input parameter type for most functions. (This necessitates some explicit copying to std::string since other APIs have not been updated yet.)
- Remove zippath_parent_basename, whose implementation was utterly broken and fortunately unused.
2021-01-06 15:17:44 -05:00
AJR
87d8079cac options.h: Be more honest about #including prerequisites 2021-01-02 16:35:51 -05:00
AJR
e2e01f7fec vbiparse.cpp: Add missing #include 2021-01-02 16:07:22 -05:00
AJR
c0933daa5a disasmintf.h: Attempt at fixing build on other compilers 2021-01-02 15:53:07 -05:00
AJR
60e518cc50 Low-level #include overhaul
- vecstream.h: Revert changes made in aa29519528. The std::string_view conversion has been made a non-member function (util::buf_to_string_view) and moved to coretmpl.h.
- strformat.h: Remove the using declaration importing util::string_format into the global namespace. It has been moved to emucore.h and a few tool sources; other references have been qualified.
- osdcore.h: Split out file, directory and path classes and methods to a new header (osdfile.h), Doxygenizing the documentation comments.
- Disaggregate many #includes that were including other standard or custom headers. emu.h now includes basically the same things that it did, but other headers have been streamlined; for instance, emucore.h no longer stealth-includes osdcore.h several ways.
2021-01-02 15:18:15 -05:00
AJR
78f93a270c palette.cpp: Use std::fill instead of memset for dirty vector; add range check 2021-01-02 15:08:44 -05:00
AJR
0a5148e05a Cassette image processing cleanup
- Add cassette_image::image_read_byte method for reading one byte at a time
- coco_cas.cpp: Eliminate dependency on emucore.h
- thom_cas.cpp: Declare some temporary variables much closer to where they are used
- tvc_cas.cpp: Read and write entire sectors at a time
2021-01-01 19:15:51 -05:00
AJR
aa29519528 Further additions of std::string_view
- corefile.cpp, fileio.cpp: Change puts to take a std::string_view parameter
- rendlay.cpp: Use std::string_view instead of bare pointers in various functions
- vecstream.h: Add std::string_view conversion operator to obtain output buffer without needing to make it a C string with explicit null termination
- xmlfile.cpp: Add get_attribute_string_ptr method that distinguishes between empty strings and absent attributes without falling back to C strings
2021-01-01 12:22:17 -05:00
AJR
21fd983545 hash.cpp, hashing.cpp: Change string processing to use std::string_view parameters; add sum16 type 2021-01-01 12:16:05 -05:00
AJR
505860225c util/xmlfile.cpp: C++ comment conversion 2020-12-31 15:26:21 -05:00
Vas Crabb
43f569e58f srcclean for 0.227 2020-12-27 05:35:56 +11:00
Vas Crabb
fb911eb6be util/wavwrite.cpp: Hopefully fix build with clang libc++. 2020-12-27 01:59:19 +11:00
Vas Crabb
9e36b6a6d9 More Lua interface cleanup - it's simpler with cleaner underlyng APIs.
Made the sound manager mute controls readable, and got rid of system
enable since it just controls system mute anyway.  This was causing
confusion: phantom2 was trying to use both independentlyt casuing the
mute bit to be ignored.

THe Lua interface changes are mostly changing methods to properties,
some renames to make things clearer, and some additional properties for
better control over snapshots.
2020-12-27 01:32:37 +11:00
AJR
735e7d5b2a util/png: Use std::string_view internally in another function 2020-12-22 08:18:47 -05:00
AJR
2194589656 util/png: Update add_text to take std::string_view for arguments 2020-12-21 23:07:50 -05:00
Vas Crabb
ed872d1bd2 Fix some oversights and emergent behaviour with view selection.
Exposed the "native snapview" option on the video manager.  Trying to
use presence of a single view is a poor proxy that breaks with
multi-screen systems.

Allow rotation to be changed for native snapshot views, and disable the
zoom to screen area control when it has no effect on the selected view.

Treat an empty string identically to "auto" for view selectction.
Previously this was being used for prefix matching so it would force the
first view.  (This caused the bad snapshot view selection.  It had been
relying on "internal" not being a common view name prefix so it fell
through to automatic selection, but when changed to an empty string it
forced the first view.)

Documented "auto" as well as "native" for the -snapview option and
changed the default to auto rather than an empty string for consistency
with the -viewN options.

Added [w]string_view handlers to the stuff that's instantiated in
strformat.cpp since we'll be increasingly using them.

Cleaned up and updated some documentation.
2020-12-20 15:28:27 +11:00
Vas Crabb
1df245cb99 More Lua engine clean-up and documentation, resulting in core cleanup.
More Lua interface cleanup, additional properties and methods, and
documentation migration/expansion.

Emulated switch inputs can have "not" codes applied to host input axis
directions.  It works the same way as host switch inputs - push twice
for a "not" prefix.

Input polling helpers no longer need to store state in the input device
items.  There’s less leakage, and less chance of things interfering with
each other.

Allow snapshot view options to be configured through the internal UI via
the video options menu.  Made video options menus place initial focus on
the currently selected view item.  Removed some crud from the menu base
class.

Fixed the description of the "snapview" option.  The value to get raw
screen pixels was changed to "native" a long time ago but the
description was never updated.

Re-arranged the Golden Poker button lamps so that the 6-button layouts
for Jolli Witch and Wild Witch make sense.  In 6-button mode, the hold
buttons double as bonus game and bet buttons, but the lamp outputs don't
change.  The simplest way to deal with this without requiring the user
to switch views or using layout scripting is to place the dedicated
buttons directly below the hold buttons that correspond to them.

Removed some software list data that was redundantly copied into
device_image_interface (m_supported was never even set, so it didn't
even work), and made crc() work better (previously it wasn't
recalculuated after unloading and loading another image).

Made strformat.h and devcb.h play nicer with C++17 and pre-standard
C++20.  Format precision now correctly limits the length of string
views.  Confirmed that strformat.{h,cpp} works with pre-standard C++20
support in GCC 9.

Removed an auto_alloc from cpu/arm7.
2020-12-18 15:54:52 +11:00
nhand42
ccacd0f165
support Redump extended bin/cue format for Dreamcast discs (#7422)
* initial check-in of Redump bin/cue support for Dreamcast GDI

* correctly identifies multi-cue format and sets GDROM flags

* creates a working Crazy Taxi chd from a Redump bin/cue

* disabled debugging code and started tidying up

* simple tool to compare chdman bin/cue and bin/gdi conversions, should be identical

* final tidy up, the testing is going well

* testing failed for Aero Dancing i (Japan), didnt zero last track

* added some comments about .gdi compatibility

* addressing review feedback on pull request #7422

* match TOSEC layout for Pattern I discs (3 tracks)

* initial support for Pattern III discs

* Pattern III discs now work and match TOSEC layout

* reading datasize from wrong track, same result though

* identify the GDI pattern, makes the code clearer

* support for Pattern II and consecutive AUDIO tracks

* use C99 type not POSIX type to build on Windows

* support Redump tracks split across two .bin files
2020-12-17 18:48:47 +02:00
AJR
2ca5f3a386 unicode.h: Updates
- Remove from emu.h (except for UTF8_xxx macros, which have been transplanted to emucore.h since a lot of drivers use them) and osdepend.h
- Add std::string_view overrides for uchar_from_utf8 and normalize_unicode
2020-12-15 13:36:55 -05:00
Miodrag Milanovic
5e23dc37a8 orao103: Support new TAP format and format now done properly 2020-12-06 19:04:05 +01:00
Sandro Ronco
3a4506bd3e cqm_dsk.cpp, ti89.cpp: Fix wrong fallthroughs. 2020-11-18 21:41:13 +01:00
Vas Crabb
612b6472e7 -unidasm: Allow input piped from stdin by specifying a bare hyphen as the filename. [AJR, Vas Crabb]
-netlist: Give devices the C++17 namespace treatment.

-Tidied up compiler warning options for 3rdparty.

-emu/render.cpp: Exposed a few information view item properties.
2020-11-18 00:58:30 +11:00
Vas Crabb
ac270744f3 Fix most implicit fallthrough warnings from clang 2020-11-17 09:18:37 +11:00
Vas Crabb
253e7f1cae Remove some deprecated instantiations of static constexpr members (MSVC complains about them now) 2020-11-15 13:43:36 +11:00
Vas Crabb
4298ce18fb Enable GCC implicit fallthrough warning.
I've guessed whether break or [[fallthrough]] is appropriate.  In cases
where it looked particularly suspicious, I added a FIXME comment.  All
of these changes should be reviewed by someone familiar with the code.
2020-11-15 03:58:54 +11:00
Vas Crabb
55b8ca317a -Switch to building MAME as C++17.
* Updated sol2 to 3.2.2
* Updated pugixml to 1.10
* Increased minimum clang version to 6
* Cleaned up some stuff that can use new features
2020-11-15 03:53:47 +11:00
Vas Crabb
39a42d517d Got rid of a couple of easy auto_alloc_array 2020-11-09 05:09:18 +11:00
Vas Crabb
7dcf0c013f emu/devfind.h: Added missing memory_share_array_creator.
Also some miscellaneous tidying up.
2020-11-08 05:43:57 +11:00
Vas Crabb
87948d7b89 srcclean in preparation for 0.226 release branch 2020-10-25 12:32:15 +11:00
Nigel Barnes
af16e6fbe9 aquarius: Added support for .CAQ cassette images.
- Select 20K RAM as default.
2020-10-19 21:14:54 +01:00
Vas Crabb
d6f7c7febf emu/debug: Removed more macros, added more const, make a couple more things use smart pointers. 2020-10-12 19:06:54 +11:00
Vas Crabb
0590cd598a formats/apridisk.cpp: Don't use megabytes of stack space. 2020-10-10 00:00:42 +11:00
Aaron Giles
1bc64213f0 brdrline: Add frontiers, reduce timestep to improve performance 2020-10-09 01:53:19 -07:00
Nigel Barnes
1a17e59008 csw_cas: Added support for v1.xx format, non-compressed RLE, and removed LegacyWaveFiller. 2020-10-08 18:01:04 +01:00
Aaron Giles
0cd5d5941d frogs: Add AFUNC frontiers to improve performance 2020-10-08 09:22:58 -07:00
Aaron Giles
7fc54760e1 netlist: Add LM348, CD4071, CD4081 devices 2020-10-08 08:26:45 -07:00
Vas Crabb
b90fd35515 Various improvements to image file handling:
Moved MS DIB parser out of ICO file reader and made it available for
artwork and layout images.

Added more efficient I/O and better error checking for JPEG file loading
(MAME will no longer exit immediately on a bad JPEG file).

Made caller responsible for opening files for loading images, to avoid
decompressing images used in ZIP/7z artwork multiple times.

Added support for JPEG and Windows DIB to picture_image_device.

Added support for SVG image files in external artwork.

Added support for using I/O port value for animation state and masking
animation state values.

Made bounds elements more flexible in layouts.

Reworked headers to reduce dependencies.

Updated layout file format documentation.
2020-10-08 02:04:31 +11:00
Aaron Giles
4fb2dfeb69 vicdual: Add frogs netlist. Make sound board interface more general. 2020-10-07 01:06:20 -07:00
beta-tester
288ca11503
brdrline: sound improvements (#7332)
- cleaned some parts of nl_brdrline.cpp (removed test points)
- changed MB4391 function to pow2 to shorten sounds a bit
- changed trigger inputs in vicdual.cpp to fit more to the sounds i remember.
- moved trigger mapping from vicdual to nl_brdrline
2020-10-06 16:45:53 -07:00
Aaron Giles
db3a24507f
Hook up Borderline netlist, provided by 'beta-tester' (#7328) [beta-tester]
* netlist: Explicitly trim connection names.
* Hook up Borderline netlist, provided by 'beta-tester'
* brdrline: Add static solver, using dynamic timestep, update driver flags.
2020-10-05 13:29:05 -04:00
Vas Crabb
f390ea1004 3rdparty/nanosvg: Re-base on latest upstream.
Now based on upstream cc6c08d3a80f1a305021af3d6394cdf1535d02a2.

Among other things, this version is supposed to be less sensitive to the
global locale.
2020-10-05 22:18:22 +11:00
Vas Crabb
0c8938f584 -emu/rendlay.cpp: Allow item animation.
-cgang.cpp: Make internal artwork more fun.
2020-10-05 00:18:33 +11:00
couriersud
7066028be1 netlist: fix VS build. 2020-10-03 14:41:17 +02:00
couriersud
b49a86981c netlist: catch parenthesis count mismatch in formulas. 2020-10-03 14:41:15 +02:00
Vas Crabb
9ac531e2b9 Exception specifications on deleted operators/constructors aren't useful. 2020-10-03 13:56:21 +10:00
AJR
9f7ef9e9c4 pmatrix_cr.h: More logical fix for the nothrow issue 2020-10-02 20:26:48 -04:00
couriersud
467b8f7d09 netlist: Revert changes intended to make the code work on OSX 10.10.
* This is working on all contemporary compilers. If outdated compilers
are to be used it is fine but a suitable compile path should be used.
2020-10-03 02:06:25 +02:00
AJR
d95c5b097a Fix clang error: exception specification of explicitly defaulted move assignment operator does not match the calculated one 2020-10-02 15:48:25 -04:00
couriersud
c0754c36cd netlist: simplify code. 2020-10-02 19:58:32 +02:00
couriersud
c797d55aaf netlist: move core_terms to netlist_state.
* These are used during creation and reset only. No need to
    maintain them on net_t level.
2020-10-02 19:58:31 +02:00