Introduction to Mednafen

Mednafen is a portable, utilizing OpenGL and SDL, argument(command-line)-driven multi-system emulator. Mednafen has the ability to remap hotkey functions and virtual system inputs to a keyboard, a joystick, or both simultaneously. Save states are supported, as is real-time game rewinding. Screen snapshots may be taken, in the PNG file format, at the press of a button. Mednafen can record audiovisual movies in the QuickTime file format, with several different lossless codecs supported.

The following systems are supported(refer to the emulation module documentation for more details):

Mednafen is distributed under the terms of the GNU GPLv2.

Due to the threaded model of emulation used in Mednafen, and limitations of SDL, a joystick is preferred over a keyboard to play games, as the joystick will have slightly less latency, although the latency differences may not be perceptible to most people.


Mednafen 0.9.48September 18, 2017 - 18:05 PDT

Notable changes since 0.9.47:
  • SS: Fixed graphics corruption in the intro of "Batman Forever".
  • SS: Fixed hang in "Jung Rhythm" when trying to retry a failed stage.
  • SS: Fixed crash in "Tenchi Muyou! Ryououki Gokuraku" when it tries to play an opening movie.
  • SS: Fixed messed-up colors in "Discworld 2".
  • SS: Fixed hang when trying to resume a suspended game in "Tactics Ogre".
  • SS: Fixed the periodic loud popping noise during FMV playback in "Grandia"(an emulation bugfix; sound may still pop/click if you have a slower CPU of course).
  • SS: Added a hack/kludge to allow bypassing of data cache on reads(such that the timing benefits of partial cache emulation are preserved, without cache coherency problems that partial cache emulation sometimes leads to with poorly programmed games), and added an internal database to enable it on select games; fixes graphical glitches and/or hangs in "Area 51 (USA and Europe)", "Clockwork Knight 2 (USA)", "DeJig - Lassen Art Collection", "Father Christmas", "Golden Axe The Duel", "Sega Saturn Choice Cuts", "Spot Goes to Hollywood (USA and Japan)", "Street Fighter Zero", "Street Fighter Zero 3", "Super Puzzle Fighter II Turbo", and "Virtual Volleyball".
  • SS: Full cache emulation is now enabled for "Whizz"(by using an internal database), to resolve(or at least reduce) quasi-random hanging issues during startup.


SHA-256: d3cc0c838f496511946d6ea18fda5965d2b71577c610acc811835cc87d152102
SHA-256: c3ccb78325bae8cbbf7d9101317a61e364c4dcd21c59004225a7307866599fa5
SHA-256: ed40023c66bc545a724f4190e6e18fb54bb97cc4249a445120f2b70a825f43e7

Mednafen 0.9.47August 26, 2017 - 02:36 PDT

Notable changes since 0.9.46:
  • SS: Added save state support(read the first section of the Saturn module's documentation before loading save states from external sources).
  • SS: Fixed startup hangs in "Device Reign", "Real Sound", "Resident Evil", "SD Gundam G Century S", "Super Tempo", "Tennis Arena", "Tilk", "Yuukyuu Gensoukyoku", "Yuukyuu Gensoukyoku 2nd Album", "Yuukyuu Gensoukyoku ensemble", "Yuukyuu Gensoukyoku ensemble 2", "Yuukyuu no Kobako Official Collection", and "Zero4 Champ".


SHA-256: 51137e60aeab070af8aba8ddc305834d2cf233be8ce82112cf38e93fe5329f3a
SHA-256: 68686760456feeb615a2279474b9c78fcd5927f91de285ba7b545b23d9900836
SHA-256: 6ad4bbf1b53508c4d1caee392516501cf5e4ce8e6b2053633f00a610e632c4af

Mednafen 0.9.46August 10, 2017 - 22:50 PDT

A small update, primarily to fix a few bugs.

-- 0.9.46: --

August 10, 2017:
	Compile with explicit -fstrict-aliasing, for distributions/OSes that have configured gcc to
	not enable strict aliasing at -O2(and possibly other levels).

	Fixed a bug that could, under certain conditions, cause emulator OSD elements to not be updated in the time
	after entering frame advance mode and before a frame advance.

August 7, 2017:
	Use a sorted std::vector instead of std::multimap to store current settings, to reduce memory usage.

August 6, 2017:
	SS: Added ss.input.port*.3dpad.mode.defpos settings to control the default position of the digital/analog mode switch.

August 5, 2017:
	Allow addresses above FFFF to be entered as the logical watch address in the debugger.

August 4, 2017:
	SS: Added kludge to fix layer offset problem in "Daytona USA CCE".

	NES: The functionality controlled by setting "nes.fnscan" now recognizes "(F)" and "(France)" as PAL.

	NES: Added support for iNES mapper 40.

July 11, 2017:
	Utilize _byteswap_*() functions in endian.h when compiling with Microsoft's C++ compiler.

June 22, 2017:
	Fixed a couple of minor issues(log header formatting, and skipped logging of first instruction in step mode) with the debugger's
	undocumented trace log feature.

	NES: Corrected the period of PAL noise channel frequency setting 0x1.

June 21, 2017:
	NES: Fixed a few square wave sound channel emulation bugs(wrong phase for duty setting 3, and failing to clock the period counter
	when the channel is silenced).

SHA-256: 674faf42bdb0ad5649aea65da266b0be3428995caaa7be183fc6d3ed7732467a
SHA-256: e869db3dac14d020471055d81bc8d21d6cf63cf3d9806ea14879cf9eff8eab4d
SHA-256: 282ef3d6b383978976bedb991b9df57b846713028fcca48c2e1be966a66be41e

Mednafen 10, 2017 - 00:49 PDT

This very minor release fixes a regression introduced in 0.9.45, that caused garbled sound output when using the (non-default) exclusive-mode WASAPI sound driver with certain higher-end sound cards.


SHA-256: f95f68acc14f9b30b201e15b8205d85ac9dc7e581ea6b61e225e990491f01e69
SHA-256: 4d8a575cbb575115e7d12421a155dd46c7f15dffa359a61ab29e4b8809fda53f
SHA-256: bce8a7d15abdaf65365ade78a981e75ea30d626baa6c54c154fecc16bb8e9481

Mednafen 0.9.45June 2, 2017 - 07:08 PDT

-- 0.9.45: --

May 29, 2017:
	Tweaked netplay sound buffer underrun kludge code.

	The netplay server host and port being connected to are now printed to the netplay console at the beginning of a
	connection attempt.

	Netplay connection attempts to servers are now non-blocking.

May 25, 2017:
	SS: Synchronize end of SMPC clock change commands to beginning of vsync instead of beginning of vblank, per tests on a SS.

May 23, 2017:
	SS: Reworked how the VDP2 rendering thread waits, to make Saturn emulation usable with the default OpenBSD kernel.

	SS: Added emulation of the light gun("Stunner"/"Virtua Gun").

April 28, 2017:
	#include'd many commonly-used C and C++ standard library headers in types.h(and removed redundant #include statements 
	from various header and source files), to reduce the probability of portability problems
	(due to neglecting to explicitly include a header file) when different standard C/C++ libraries
	behave differently in regards to what header files include what other header files.

	Added a sound output driver for OpenBSD's /dev/audio.

	Reworked the sound output format conversion code to be more versatile, 

April 25, 2017:
	NES: Wrote new "Barcode Battler II" emulation code to replace the old "Barcode World" code, based on quick testing with
	actual hardware(albeit the English version).

April 24, 2017:
	SSFPlay: Added save state support.

SHA-256: 49715544a5eb7a678f7f01994f38aa14e2192f00d201684184665665073a600e
SHA-256: 89a6f67711c2e0bb4c5e59fb684e7e54dbb3b3c4acee94ecab52740a204e942d
SHA-256: 27c6bc064e96a54fe082b834fa29019ac8e82b9f1bc9be047e2ec633bd1b424f

Mednafen 21, 2017 - 21:33 PDT

Notable changes since 0.9.43:
  • Added command-line option "-which_medium", to specify which CD to start with when using multi-CD M3U sets.
  • SNES: Fixed "Tractor Beam" spell graphical glitches in "Star Ocean".
  • SNES: Fixed emulator hang when saving state in "Panic Bomber W".
  • SNES_FAUST: Added PAL support.
  • SNES_FAUST: Made minor optimizations to the BG rendering code.
  • SNES_FAUST: Added setting "snes_faust.correct_aspect", default value of "1".
  • SS: Fixed broken input in "Primal Rage"(a 0.9.43 regression).
  • SS: Added support for a 16MiB RAM cart mapped into the A-bus CS1 area(for "Heart of Darkness" and homebrew).
  • VB: Added support for custom palettes.
  • VB: Reworked how LED on-state duration is translated into RGB values and added setting "vb.ledonscale"; the default value of "vb.ledonscale" is set such that the overall brightness will be lower than in previous versions of Mednafen, to reduce white crush, but the user can set it to a value of "1.9921875" to approximate the old brightness level.
  • WonderSwan: Removed setting "wswan.rotateinput", and added a new device("gamepadraa") that can be selected on virtual input port 1 to automatically rotate inputs when the display is rotated.


SHA-256: 2427ab0718475c84c8f908894e74dcac2145992d23958d182a40eee122c95544
SHA-256: 31950987af0d34b000766f57347e84a1b5f3f2d016792ed7deb74e4a9a565d0f
SHA-256: 447bb75e9c0c0c85e8614699ade138d84a64db0dc087e0fa010bd062ea03d4c7

Mednafen 0.9.43February 26, 2017 - 09:07 PST

Notable changes since 0.9.42:
  • PSX: Reduced DualShock rumble latency by 1 frame.
  • SS: Added multitap emulation, enableable via settings "ss.input.sport1.multitap" and "ss.input.sport2.multitap".
  • SS: Added steering wheel emulation(for "Virtua Racing", and other racing games that lack 3D Pad analog support).
  • SS: Added Mission Stick and Dual Mission Stick emulation.
  • SS: Added 101-key US keyboard emulation.
  • SS: Fixed hang in "F1 Challenge".
  • SS: Fixed missing voice acting and related hangs in "Magic Knight Rayearth".
  • Reworked how input grabbing is handled. The new way uses only one key combo(CTRL+SHIFT+Menu), and will adapt its behavior based on any keyboards being selected on any virtual input ports or not(refer to the documentation for full details). A new setting is added, "command.toggle_grab", and two settings were removed, "command.toggle_grab_input" and "command.toggle_cidisable".
  • Emulated keyboard(FKB, Tsushin, Saturn) key state is now only updated when input grabbing is toggled on.


SHA-256: b8305914cdf297fe6483219fa10c3fa14116fff8eed02f61326a0e32dd350f4d
SHA-256: 656c298fd28bfbd9f003537347971c41cb3ae759a23c95c3ecb22fa13a7748aa
SHA-256: e8931cceb9d42943beca70e83f876c5d7f469fe510f63506e27f418b1673f6ad

Mednafen 0.9.42February 7, 2017 - 22:04 PST

Notable changes since 0.9.41:
  • NES: Added support for iNES mapper 190.
  • SNES_FAUST: Added multitap support(enable via setting "snes_faust.input.sport2.multitap").
  • SS: Fixed severely-flickering graphics in "Virtua Cop" and "Virtua Cop 2".
  • SS: Fixed speed problems in "Pocket Fighter".
  • SS: Fixed FMV tearing in "Johnny Bazookatone".
  • SS: Fixed hang in "GunBlaze-S".
  • SS: Fixed hangs in "Virtua Fighter" and "Virtua Fighter Remix"(still some graphical weirdness, though).
  • SS: Fixed hang in "Zero Divide".
  • SS: Fixed missing sound problem in "Arcade's Greatest Hits".
  • SS: Fixed missing sound and related issues in "Ultimate Mortal Kombat 3".


SHA-256: 93e000286bd24ed5d39e6f67a22b950f3081aa71eeee1107a552246bbd3b5c25
SHA-256: 6e31184c72b6f8d461f423ae6b235e9ab38143fe12d4dbfb5c2c50b5992660a5
SHA-256: 7f2724faaca60f5bd2a39e19515d2bf9cdfc87024e3d455da7ec2a430a23cd3b

Mednafen 0.9.41January 21, 2017 - 11:16 PST

The 64-bit Windows build is now compiled with gcc 4.9.4, but modified to produce slightly smaller and slightly faster Mednafen executables. The patch is available as "mednafen/patches/gcc-4.9.4-mingw-w64-noforcepic-smalljmptab.patch" in the source tarball.

The source tarball is now compressed with xz instead of bzip2.

Particularly notable changes since
  • Renamed settings "*.pixshader" to "*.shader".
  • Added simple color TV CRT-approximating OpenGL shader, "goat".
  • PSX: Added "" setting to control the combination of buttons used when the functionality controlled by the "psx.input.analog_mode_ct" setting is enabled.
  • SMS: Added settings "sms.slstart", "sms.slend", "sms.slstartp", and "sms.slendp".
  • SNES: Added setting "snes.h_blend", default value of "0", that when set to "1" will enable a horizontal blend/blur filter.
  • SS: Added setting "ss.correct_aspect", default value of "1", to allow the user to disable aspect ratio correction(not recommended, but whatever~).
  • SS: Added setting "ss.h_overscan", default value of "1", to allow the user to show less of the screen on the left and right sides by setting it to "0".
  • SS: Added setting "ss.h_blend", default value of "0", that when set to "1" will enable a horizontal blend/blur filter(with a more noticeable effect on the Saturn video modes with a higher horizontal resolution).
  • SS: Fixed the low volume problem in "Daytona USA".
  • SS: Fixed missing/corrupted graphics of battle scenes in "Grandia".
  • WonderSwan: Minor sound and graphics emulation accuracy improvements, from patches and suggestions provided by trap15.


SHA-256: 74736b9b52a7ba6270b67ae8e6c876a887e0e26a00a7d96bdd49af17992aac47
SHA-256: 2eed5383624d781c34bc18cbe42ab51bf5a633161d71fdc68cf14bf0e9a768d5
SHA-256: ae6483a20f0c0aa900a2e14908d3c004fea056ffcef179c582e4f3f3c077f664

Mednafen 19, 2016 - 21:01 PDT

This release adds PAL/European support to the Sega Saturn emulation.


SHA-256: b42470b2ddf68ce0747f5b8ba4e1d1c3047fa8c45b8e168da43f3e2461ec34cc
SHA-256: 9acceb0d6239105605dc598d56563adb7d5dfce56671ab5ddfa0aef33cdc19c2
SHA-256: 6ca033328ee26c4696cf3a7820ab02a6ca7c6bfbe194b9697c0051cae1566894

Page design and original content copyright © 2005-2017 Mednafen Team. The Mednafen Beetle is copyright © 2005 Camille Young. Nintendo, Nintendo Entertainment System, GameBoy, GameBoy Color, and GameBoy Advance are registered trademarks of Nintendo. Mednafen is not an official Nintendo product, and Mednafen is in no way affiliated with the Nintendo corporation.