Post subject: lsnes emulator development (lsnes rr2-β23)
Emulator Coder
Joined: 3/9/2004
Posts: 4588
Location: In his lab studying psychology to find new ways to torture TASers and forumers
Ilari has updated his SNES / Gameboy / Gameboy Color emulator with new features, and introducing: *First proper Super Gameboy emulator with rerecording! *Lua 5.3 support and the most advanced and feature complete Lua functionality of any emulator! Wiki: Lsnes Files: rr2-β23 with SGB Core - Windows Installer 15.6 MB (Recommended) rr2-β23 - Windows Binaries and Source Code 10.4 MB (Can be used to build for Linux, Windows, OS X, and possibly other UNIX compatible OSs) SGB core.so Builder (from source) 382 bytes (Will need some minor modification to build core.dll instead) A PDF containing the Lua functions reference is part of the download package. Note, if you're not using the Windows installer version with its launch shortcuts, you'll need to manually load the Super Gameboy core.dll to make use of it. For those of you not familiar with lsnes, it emulates the following platforms: *Super Nintendo *Gameboy *Super Gameboy *Gameboy Color *Gameboy Color in Gameboy Advance mode To make use of proper Super Gameboy emulation, use: File -> Load -> Multifile ROM -> Super Gameboy [bsnes v085 / Gambatte r537]. You will then need to select the Super Gameboy BIOS ROM image and the DMG (Gameboy) ROM image. Changes: rr2-β0 [Wednesday January 16th 2013] ==================================== * Refactor bsnes core version handling * Refactor SNES::system_*pu_frequency() calls to interface/bsnes.cpp * Refactor dummy interfaces to interface/bsnes.cpp * Refactor SRAM handling to interface/bsnes.cpp * Split VMA handling * Get rid of bsnes headers for memorymanip.cpp * Move core save/load routines to bsnes.cpp * Built-in ROM patcher * Some build fixes for Mac OS X * Fix compile error in src/video/sdmp.cpp * Fix compile errors in src/platform/wxwidgets/romselect.cpp * Refactor ROM slots handling * Refactor internal interfaces to support arbitrary number of controllers * MAX_ANALOG is no longer used, remove it * Support systems with !=2 ports * Fix segfault in controllerframe::deserialize * Fix case where deserialize doesn't read whole last field * Fix byte order of system field * Actually fix system byte order for gambatte * Change the pollcounter type to avoid errors on movie load * Refactor movie class to library/ * Move globalwrap.hpp to library/ * Use globalwrap in controller-data.cpp * globalwrap: Warn about recursive initialization * Refactor command handling to library/ * Refactor settings to library/ * Plug memory leaks * Don't leak command group internal management commands * Move bridging between commands and settings to library/ * Move messagebuffer to library/ * Move emulator_status to library/ * Unify registration queue handling of commands and settings * Refactor and extend library loading * Fix some compile errors (throw specifiers) * Add a missing header file and correct win32 build error * Merge core controller setting code * Remove optionality of Lua support * Refactor Lua support * Fix some really retarded code in library/movie * Have cores generate controller index maps * Some movie code cleaning up * Avoid spurious polls arising from DRDY of nonexistent tuples * Move reset handling to cores * Have core-specific code build the legacy PCID maps * Allow multiple types of controllers on one port * Extern references in library/controller-data.hpp are no-no * Don't poll for / write non-valid control indices * Gambatte: Fold port0 and port1 together * Split lua_render_context into library/ * Lua: Clean up callback code * Refactor memory mappings & memory search to library/ * Split thread type defines to own header file * Fix button symbols in input display * Fix autohold menu * Compensate for nuts bsnes superscope/justifier handling * Clean up library includes * Sort out the fucking messages mess * Allow passing ROMs by filename instead by data * SNES: New controller types gamepad16 and multitap16 * Fix some misc. compile errors in G++ 4.6 * Lua: memory.getregister for SNES * SNES: Breakpoint support (still preliminary) * SNES: Add trace logging and step hooks * Refactor keyboard modifiers into library/ * Refactor keygroup into library/ * Remove obsolete SDL stuff * Remove more old crapola * Refactor keymapping to library/ * Refactor generic_port_* functions and get rid of button_symbols * Also get rid of controller_names (using template magic) * Data-driven controller buttons * Use controller names instead of classes in autohold menu * Remove obsolete unused functions * Settings-based controllers * Remove export for core_set_region, there's no such function anymore * Move get_{audio,video}_rate() to rom type methods * Make the SNES rate specials methods * More making core functions into methods * Use lambda functions in core bindings * More refactoring core functions into methods * Remove set_preload_settings(), do the things at ROM load if needed * Remove do_basic_core_init (do equivalent tasks on demand) * More making core functions into methods * Yet more moving of core functions to methods * Make set of port types for core a field * Support multiple cores at once * controller mapping: Remove dangerous order assumption * Handle buttons when dynamically loading cores * Fix warnings about variable scope * Support autoloading stuff on startup * Support per-core cover pages * Do something sightly more interesting with covers * Display internal ROM name in cover page * Show region on cover page * Cover page: Characters 9 and 10 are supposed to be invisible * bsnes: system_name is unused, remove it * Replace region with full system * Handle conflicting sysregions * Remove legacy lag counting * Move emulation core bindings to their own directories * Show all supported cores in about window * Auto-generate port type code from defines * More core defines auto-generation * Allow null buttons in input maps * Fix make clean if bsnes and/or gambatte is missing * Fix compiling with gambatte and/or bsnes missing * Add button type TYPE_NULL * Change all systypes from map to set * Refactor finding systype by extension/name * Core conflict resolution * Fix Win32 compile errors rr2-β1 [Saturday January 19th 2013] =================================== * Cores: Blurb * Update libgambatte to SVN 364 * Get rid of partial linking * Load XML even without gamepack files * Support screen rotation & flipping * Fix bug when changing controller key to another subkey of the same key rr2-β2 [Thursday January 24th 2013] =================================== * Use system mutex/condition types instead of platform ones * Get rid of platform thread_id * Get rid of platform threads * joystick_plugin:: -> joystick_driver_ * Joystick: use weak functions * Audio drivers: Use weak functions * graphics_plugin:: -> graphics_driver_ * Graphics driver: Use weak functions * Windows apparently doesn't support weak functions * Lua: bit.test_any, bit.test_all * Lua: bit.popcount * Bit.{test_any,test_all,popcount}: Fix wrong datatype * Lua: bit.clshift / bit.crshift * Lua: bit.flagdecode * Emulate weak dummy driver in a way compatible with Win32 * Lua: bit.rflagdecode * Split duplex support rr2-β3 [Monday February 11th 2013] ================================== * Lua: Render queues as objects * Render queue documentation * Support for hard resets and make some stuff movie settings * Dedicated sound devices dialog * Oops, missing file. * Oops, set the sound mode default to 2 not 3 * Movie editor: Add space before axis fields * Movie editor: Properly space in presence of axis fields * Fix serializing multi-controller ports * Fix serializing multiple ports * Fix saving unconnected ports to movie * Wxwidgets: Don't save or load blank core preferences * Portaudio: Do split duplex with different I/O devices * Portaudio: Fix buggy full-duplex mode * Fix controls with gambatte core * Remove lsnesrc-related code (since what it was used for is long gone) * Clean up framerate handling * Clean up save slots handling * Fix some uninitialized variables caught by Valgrind * Cleanup many settings (all from core) * lsnes-dumpavi: --firmware-path * Fix breakage in last commit * {set,clear}-pause-on-end * Fix lots of -Wall compiler warnings rr2-β4 [Monday March 4th 2013] ============================== * Revert memory leak fix breaking input * Allow cores to create big-endian VMAs * Refactor Opus handing * Opus support: Repacketizer * Opus support: Ignore errors ctls * Better error handling in opus code * Opus support: Fix all sorts of mistakes * Make some things unsigned and fix on platforms where int is not 32 bits * Opus support: Support multistream * Fix memory search bug with host-endian VMAs * Restrict member picking to only .zip files * Fix reading of host-endian VMAs. * Some bizarre stuff... * Fix rlow and rhigh to be right way around * Fix movie editor in obscure case * Lua: Don't wedge VM if callback fails with exception * Refactor Oggopus support rr2-β5 [Monday April 1st 2013] ============================== * Reject Oggopus files that don't have complete pregap * Make opus_packet_tick_count a common function * Rewrite opus_packet_tick_count without lookup tables * Multistream and demuxing fixes * Workaround framebuffer bug if screen width >1024 * Allow on_input to veto/force system controls (including reset line) * Refactoring: copy_from_utf8() * Use named field initializers in cores * Have dedicated window for autohold instead of menu * Support per-button autofire * Fix crashes trying to frameadvance or exit with no ROM loaded * Also use named initializers for null core * Wxwidgets: Autohold: Don't open with no controllers * Warn about nonexistent controller keys more aggressively * Movie editor: Fix mouse * TAS input plugin * Analog passthrough * Gambatte: Clean up unused stuff * Add tests for throttle axes and fix numerious mistakes * TAS input plugin: Tweak coordinate transforms and pad sizes * Movie editor: Mark the panel as wxWANTS_CHARS * TAS input plugin: Accept keyboard hotkeys * Fix analog input using mouse (got broken with analog passthrough) * Don't crash if somebody calls audioapi_get_voice with samples=NULL * Autohold/Autofire: Try fix the "ga" bug * Add missing $(CROSS_PREFIX) to pkg-config for libopus * Use std::u32string instead of std::vector<uint32_t> for UTF-32 strings * Movie editor: Use UTF-32 internally * Fix undefined return value from port unserialization * Move some info from status panel to statusbar * data/verysmall.font is mising glyph 70 (F) * Lua: CUSTOMFONT: Allow painting with halo rr2-β6 [Wednesday April 17th 2013] ================================== * Autofire: Fix false status indications * Fix subframe counter * Fix print() after Lua VM reset * New settings framework * Remove some unused leftover stuff * Fix race condition causing possible crash on startup * Fix compiling if uint64_t and size_t are not compatible * Lua: Don't crash if input.[gs]et{,a} is called outside on_input rr2-β7 [Wednesday April 17th 2013] ================================== * Fix crash on loading GB(c) ROMs. rr2-β8 [Monday June 24th 2013] ============================== * Make save slot info work correctly with prefixes. * Cleanup port defintions. * Allow button display symbols to be Unicode characters. * Make all Lua memory functions optionally take VMA. * Lua: Allow creation of commands. * Commentary: Remove support for old Opus format. * Lua: Throw instead of raising error if VMA is invalid. * Fix statusbar breakage when not recording. * Projects support. * Lua: Don't crash if method execution throws. * Lua: memory2. * Fix bug causing ext0...ext3 to appear pressed on normal gamepad. * Mac OS X compile fix. * Fix desync on loading movie via project load. * Fix memory watch with project active. * Allow per-variable names for booleans. * Don't change settings in UI thread. * Change booleans without prompting. * Support enumerated settings. * Special dialogs for numeric and path settings. * Support loading libopus at runtime. * Lua: Report port internal names instead of hnames * Wxwidgets: Initialize panel renderer variables properly. * Handle project switch as loadstate. * Close ROM. * Fix compilation if wxstring is wide. * Bump max savestate slot count to 999,999,999. * wxwidgets: Don't print narrow characters into wide stream. * SNES: Layer hiding. * Simplify stuff with initializer lists. * Lua: Fix coroutines. * SNES: SMP disasm. * Fix subtitle generation. * Keep memory watches on project creation. * Macro support. rr2-β9 [Sunday August 4th 2013] =============================== * Fix reading byte-sized values via read-(s)byte * Allow specifiying ROM type in load dialog. * More cleanups using initializer lists. * Core actions. * Remove long-umaintained SNES-specific dump format. * SNES disassembler. * Refactor core interface stuff. * Refactor dispatching interface * Fix creating a new project after forcing core. * Mac OS X joystick support * memory.get_lag_flag/memory.set_lag_flag * Show error dialog on important errors. * Autobuild index triple and legacy-pcid maps. * Remove moviestate support. * New file dialogs code. * Binary movies support. * Clip analog macros correctly. * Refactor the settings dialog. * Remember gamepads across restarts. * Unlimited number of keys per inverse bind / controller key. * Savestate to rewind point conversion. * Split lua reference to its own manual. * Kill port type IDs. * Call do_sample from audioapi_submit_buffer. * Lua: gui.adjust_transparency. * Lua: loadfile/dofile: Support basenames. * Lua: gui.bitmap_load*: Support basenames. * Lua: Support packed Lua scripts. * Lua: @@LUA_SCRIPT_FILENAME@@ * Lua: Function to resolve file w.r.t. basneame. rr2-β10 [Friday October 4th 2013] ================================= * Don't show joysticks tab if no joysticks. * Lua: callback.register/callback.unregister * Don't call action_state_updated() while emulator is strating up. * Decouple sets of functions from Lua states. * Properly handle zip_reader trying to open non-.zip. * Cleanup controller and keymapper stuff on exit. * SNES: Call callbacks in correct lua state. * Gambatte: First emit video then sound. * gui.kill_frame: Omit frame from video dump. * Lua: gui.bitmap_pget: Read pixels from bitmap. * Gambatte: DMG palette manipulation. * Gambatte: Allow native-rate sound output. * Lua: open_file. * Lua: Don't load binary chunks. * Don't offer horizontal scale factor as value of verical factor * Config dialog / advanced: Treat doubleclick as change click * Use tree control instead of pair of listboxes in hotkeys&controls * Settings dialog: Support right click context menu * Replace X/Y scale with one scale + optional AR correction * Some sort of fullscreen mode * Tweak the video options panel * Much more compact joystick dialog * Joystick dialog: Center one-digit numbers * Move E() from joystick code to general text panel code * Joystick dialog: Compactify * Portaudio: Heed defaults, don't use full-duplex mode * Fix parsing Oggopus files with tags spanning multiple pages * Remove leftover debug messages * lsnes-dumpavi: Support specifying dump length as overdump length * Make port_type::legal based on data instead of generated * Macros: Support ? modifier for macros (press at random) * Reserve 1 byte for each macro button instead of 2 bits * Be more careful when parsing macros * SNES: Support "compact form" where delay resets aren't supported * Lua: gui.synchronous_repaint() * Support "wrambank" register (read-only) for DMG/CGB * Make lua_obj_pin<T> copyable * Lua: Automatically pass Lua state to lua class ctors * Lua: Use full userdata to store class binds * Lua: lua_class<T>::bind_multi (initializer lists are useful) * Lua: Pass name of method to various lua class methods * Some libgambatte fixes * Simplify memory space read/write code * Clean up reading of values of various types * Simplify memory search by using templates * Support 24-bit memory watches / memory searching * Support float/double memory watch/search * Fix reading binary movies with unknown extensions * If movie is loaded without ROM, prompt for ROM * Fix slotinfo for binary save slots * Add some missing files * Fix memory search datatype names * Add state mapping for SGB Gameboy CPU * Support SGB GB HRAM too * Allow RAM initialization from movie file * Properly change core if ROM is loaded by request * Refactor image slots code * Refactor binary file saving/loading routines * Remove lanczos.cpp, Nothing needs it * Check JSON integer values before trying to parse * enumerate_directory: Don't list . and .. * Fix compiling if Boost threads are used * Mark some globals as const * Make some global variables fields * binary_input_stream: Handle nested extensions correctly * Share file image data among copied instances * Make symbolic constant ROM_SLOT_COUNT for ROM slot count * Save ROM hints * Use ROM hints for default request filename * Scatter-gather value read/write * Fix compilation with wchar_t based wxstring * Cut the ridiculous exception spam from file probing * Support Multi-ROM projects * Fix compilation with wchar_t-based wxString * ROM guessing * Hashing: Show total work size, and don't accidentally block the UI * Fix a bug where quitting emulator would only unpause it * Fix UI blocking on hash verification against movie * Fix Win32 (or GCC 4.8?) compilation * Hex editor * Memory search: Poke * Memory search: Select in hex editor * Hex editor: Add watch * Hex editor: Few fixed-point types * Hex editor: Q12.4 * Memory search: Save, Load, Undo and Redo rr2-β11 [Sunday October 6th 2013] ================================= * Movie editor: Add panel for inputting axis values * Fix uninitialzed variable * Fix graphics update hanging * TAS Input: Improve lightgun support * Multitrack support * TAS input: Don't bug out on loadstate * TAS Input: Compute buffer size for lightgun correctly * Change working directory rr2-β12 [Monday October 14th 2013] ================================== * Fix compilation on Mac OS X * Lua: Also add scatter-gather to memory.* (not just memory2.*) * Fix crash if loading rom with non-default controllers active * Refactor rrdata handling * Merge branch 'rr1-maint * Use correct file for rerecord counting * Fix more bugs in rerecord counting * Fix bug that caused save slots always to be semi-text in projects * Speed up binary savestate saving rr2-β13 [Thursday November 28th 2013] ===================================== * If libgcrypt is available but /dev/urandom is not, use libgcrypt for RNG* Allow setting AVI scale factors * JSON-based controller descriptions * Fix compile for Mac OS X * Optimize generic controllers using dynamically generated code * Make regex thread-safe * JSON: Reduce internal exception spam * Recent Lua scripts * Support latch notifications on SNES * Wxwidgets: Command line history * Oops, forgot to update patchseries for latch notification support * Add on_latch to Lua docs * Try to autodect I386/amd64 * Save bitmaps as PNG * Lua: gui.bitmap_hash/gui.palete_hash * Lua: bsnes.dump_sprite: Allow overriding row stride * Fix recent movies menu * Fix output if core tries to output wider than buffer (currently 4096) * Win32 compile fixes * Don't crash if setting game name & authors outside project context * Support in-memory saves and use those for wxwidgets ROM loading * Fix in-memory slots * Improve randomness of get_random_hexstring (on I386) * Zip: Allow output to arbitrary ostream * HTTP request code * Support stream compression * File upload code * Add command-line file uploader * Upload UI * Movie downloading * Strip path when autofilling filename * httpauth: Use the no-protocol mode * Gambatte: Expose CPU registers * Fix compilation on Win32 * BSNES: Compile with accuracy core * Fix WWW-Autheticate parsing * Rewrite parse_authenticate in saner way * Lua: Fix a typo in error message * Fix writing movie data * Nuke the helper executables on make clean * Print proper error message if Lua expression parse fails * Allow resizing messages window * Oops, remove some crap lines * Messages panel: copy to clipboard / save to file * Messages window: Scroll with wheel * Fold audio device controls to VU meter window * Unified support for breakpoints & cheats rr2-β14 [Tuesday December 31st 2013] ==================================== * Fix printing of errors from some notifications * Don't require to specify bsnes version when building * Null core: Set the hidden flag * Attempt to save if emulator is crashing * Gameboy disasembler * Fix compile with Gambatte not supporting debug hooks * Gambatte: Do not lose colors when ROM is reloaded * Command to set current slot * Optional background sound autodisable * Gambatte: DC levels fixes * Don't crash if loaded dynamic library contains a new core * Fix compile for bsnes accuracy for real * Add bsnes alternate poll timings patch * Fix http_request::_progress * Make parse_value be able to parse 0x notation * Bitmap font to custom font conversion * Also catch terminate() for autosave * Initialize some vars in messages window * Release regexps before finally exiting * Lua: random.* * Lua: Zip create / enumerate * Lua: gui.screenshot_bitmap() * Clean up filesystem stuff * Move binarystream functions to dedicated namespace * Refactor library command functions to dedicated namespace * Refactor library keyboard to dedicated namespace * Refactor library dispatch stuff to dedicated namespace * Build: Fast global need-rebuild detection * Remove some crazy dependencies to keymapper * Extra framebuffer methods * Refactor library framebuffer to dedicated namespace * Further framebuffer refactoring (pixel formats) * Remove some dead files * Refactor custom_font into framebuffer namespace * Refactor library gamepad to dedicated namespace * Refactor library ogg functions to dedicated namespace * Refactor library zip functions to dedicated namespace * Refactor library serialization to dedicated namespace * loadlib refactoring, add program modules * Move opus_packet_tick_count() to main opus library code * Move routines from oggopus to opus namespace * keyboard-mapper: Get rid of command.hpp include * Get rid of DECLARE_LUACLASS * Throw internal error instead of crashing if trying to use nonexistent class * Refactor library Lua base to dedicated namespace * Refactor library settings to dedicated namespace * Refactor library png functions to dedicated namespace * Refactor library UTF8 to dedicated namespace * Clean up hexadecimal<->string conversion * File upload: Behave like cancel was clicked on window close * Fix compilation of make-ports helper * Refactor library fileimage to dedicated namespace * Refactor library filesystem code * SNES: PPU registers * Move library patch functions with file image functions * Get rid of utf8::to32i2() and extract_token() * Fix compile error on some systems * Fix another compile error (constant in Connect()) * SNES: Make needed directories for build if missing * Clean up some hash and RNG code * Crash autosave: Don't try to save movies with NULL sysregion * Lua: Bitmap/renderq object methods * Framebuffer: Set unused color bits to 1 instead of 0 * Fix a bug applying delta gaps on render queue * Lua: RENDERQUEUE:render: Render queue to DBITMAP * Allow color names as color specifications * Some refactoring of the named colors stuff (and a lot more colors) * Lua: HSL colors and color modifiers * JSON Pretty printing support and pretty-print joystick configuration * GB: Disassemble/Tracelog fixes for CB xx * Wxwidgets: Plugin manager * Lua: render_queue_function * Fix off-by-one in counting number of objects in render queue * Clean up error reporting on plugin load failure * Plugin manager: Mark plugins that failed to load * Plugin manager: Atomic overwrites, remove otherstate plugin on rename * Also load plugins from location relative to the executable * Fix compiling on Win32 * Plugin blacklist/killlist (needed on some toys) rr2-β15 [Sunday January 5th 2014] ================================= * options.build: Default to g++, not g++-4.6 (too old) * Fix crash on canceling tracelog filename select * Fix framebuffer::font::get_metrics * Don't crash on certain invalid memory read/write commands * Oops, GB(C) bus was missing * Don't desync if loading a movie preserving input * Fix rerecord count to reset on new movie rr2-β16 [Friday February 14th 2014] =================================== * PNG screenshots are bugged again... * Fix typo in macosx platform makefile * More advanced memory watches * Fix core selection among multiple candidates for downloaded movies * Allow -mt prefix for host boost * Make frame count controller_frame_vector property * Clean up internal name used to designate a save slot * Move main movie compatiblity checking to controller_frame_vector * Optimize controller_frame_vector::compatible() * Fix lockup if exiting emulator with project active * Lua: gui.set_video_scale() * Slot branches * Allow loading empty font and editing font after loading * Lua interface to iconv(3), string.byteU and string.charU * Rename ERROR to FAILED in evaluation status * Lua: Byte order swapping * Lua: Scaling blits, color priority blits, Porter-Duff blits * Lua: Autogenerate sysrc.cpp from sysrc.lua * Lua: identify_class * Lua: Refactor lots of stuff * Lua: Refactor classes * Lua: Make static constructor methods for MMAP_STRUCT and ZIPWRITER * Lua: Cleanup hostmemory and use static method for TILEMAP ctor * Lua: Cleanup gui-rqueue.cpp * Lua: Table of classes * Lua: Refactor some documentation * Lua: Some fixes related to sysrc.lua * Lua: cleanup some more files * Lua: More conversion to lua::parameters * Lua: More refactoring * Lua: Multi-argument parsing and unify color parsing * Lua: Use multi-argument parsing in some more places * Lua: use multi-argument parsing for more files * Lua: Use multiarg in some more files * Lua: Use multiarg for rest of gui-* stuff * Lua: Multiarg refactoring for a few more files * Lua: Refactor the two remaining files to use multiarg * Lua: Convert some core-specific stuff and kill lua::fnptr * Lua: Make class methods take lua::parameters * PRNG: Don't try to access element -1 of array in some cases * Make reference to certain library conditional * Lua: Give the print method as pointer instead of assuming T::print * Lua: all_classes() * Lua: Support __pairs for classes * Lua: Convert some functions to static-only classes * Lua: Get rid of unneeded subclasses of lua::function * lua_func_callback isn't used anymore, remove it * Lua: bit.compose, bit.binary_{ld,st}_*, bit.quotent * Fix some exception specifier mismatches * Refactor some generic reading/writing routines out of moviefile.cpp * wxwidgets: Use text render panel in messages window * Make git diff --check happy * Gambatte: New patch: Optional crash on SIGILL, fix MBC3 * Back movie data off movie file structure * Fix initram handling with rewind to start type actions * Upload: Don't send empty fields * Dynamically allocate moviefile, rrdata and movie structures * Support multi-branch movies * moviefile.cpp is friggin' large, split it up * Load some legacy memory watches * Cleanup lua code by introducing lua::functions * File upload: More usable game name selection * Don't crash if exiting with trace log active * Upload: Drop the system select, it isn't usable * Fix kill_hooks() * Gambatte: Some Trace/Disassemble fixes * Hex editor: Properly erase past-the-end chars for non-mod16 regions * Don't use framebuffer palettes * Lua: memory.hash_region(), memory.store(), memory.storecmp() * Lua docs: Replace "vma" by "memory area" or "marea" * Trace logger / disassembler GUI * Fix parsing of #nnnnnn color notation * Lua: Cleanup & fix memory hash / storecmp functions * Lua: memory2: More functions corresponding to memory.* rr2-β17 [Friday February 28th 2014] =================================== * Makefile: platclean: Only clean emulation files * Lua: COMPARE_OBJ: Check strided memory block for modifications * Some tweaks to Lua docs * Show dialog if loading ROM/movie from command line fails * Lua: Don't run Lua until the emulator has fully started up * Lua: Run startup scripts after amode has been initialized * wxwidgets: Allow entering fullscreen mode from commandline * bsnes: redump sprite/palette functions * Lua: Fix gui.repaint() when paused * Lua: Clean up region bounds computation * Some cleanup * Wxwidgets: --unpause to auto-unpause on start * Properly set Read-Only mode if rewinding * Memory search: Fix display of unsigned dword and signed qword * Tracelogger: Breakpoints * Pass dummy object parameter to do_unregister * Fix system plugins not getting loaded if user plugin enum failed * Move library recentfiles to its own namespace * Don't crash if recentfiles line fails to deserialize * Recentfiles object: named object * New projects menu * C interface * Fix exact core matching when loading projects rr2-β18 [Wednesday March 19th 2014] =================================== * bsnes core: Raise bus breaks against correct address * C interface: Fix lag counting without LSNES_CORE_CAP1_PFLAG * C interface: Check for value != 0, not for control != 0 for lag check * Fix core callbacks being undefined if loading ROM from cmdline * Fix compilation on Mac OS X * Fix mouse electronics test * Tweak new movie dialog layout a bit * Add JSON linter utility * Force some configuration windows to be larger * Correctly show axes as disabled even if offline * Don't double-close audio output * Fix deleting executing breakpoint * Lua: Get lag count function * Allow bsnes tracelogger to trace execution in controller registers * SNES: Fix disassembly of long offsets * Make setting/unsetting non-bus breaks much faster. * Optimize movie.find_frame() rr2-β19 [Monday March 31st 2014] ================================ * Move one #ifdef BSNES_HAS_DEBUGGER to the proper place * Some missing string conversions and headers * Speed up font init * Fix some memory leak complaints from Valgrind * Free some more memory before quitting * Fix potential dtor ordering crash in file hasher * Fix another potential dtor order crash * Refactor workthread.hpp and threadtypes.hpp (renamed to threads.hpp) * Refactor streamcompress.hpp * Lock/Unlock multiple locks at once function / class * Gambatte: Mark system bus as I/O special * Initialize project active_branch/next_branch * Fix loading memory watches on project change * GB: Fix read/write of A, PC and CycleCounter when executing * GB: Fix tracelogger not to screw up breaks * Refactor triple buffering logic to its own file * Small tweak to previous (convert multiplication to bitshift) * Lua: string.regex * Lua: bit.multidiv * Tweak description of bit.multidiv * Lua: bit.test, bit.testn, string.hex, string.lpad, string.rpad * Make redraw_framebuffer call update_movie_state(); * Only update emulator status from within update_movie_state() * Fix the 0 movie length bug * Don't crash if trying to load movie with unknown sysregion * Work around compiler warning on -2^63 written as constant * Make compiler more anal and fix what comes up * Lua: bit.mul32 * Autosave settings immediately after closing settings * Add base support for Lua object overcommit * Use overcommit for palettes, bitmaps, dbitmaps and tilemaps * Error out creating too large bitmaps / tilemaps instead of corrupting memory * Fix compare objects * Fix printing of tilemaps and compare objects * Use overcommit in memory compares * SNES: Support VRAM, OAM, CGRAM and APURAM breakpoints * Refactor emulator status reporting (and fix the statusbar doesn't update bug) rr2-β20 [Monday April 1st 2014] =============================== * Fix typo in changelog * Fix bug in printing MSU-1 track playback messages * Add option to emulate fucked up GBC timings * Coalesce UI events. * Don't update statusbar fast outside paint event rr2-β21 [Sunday May 4th 2014] ============================= * Delete the now-unused emulator_status stuff * Numeric range class, obsolete clip_range. * Lua: gui.solidrectangle * Lua: (D)BITMAP:draw_clip, (D)BITMAP:draw_outside, TILEMAP:draw_outside * c-interface: Add some translation templates * src/lua/gui-bitmap.cpp Initialize spal to avoid compiler warning * Don't use -Werror * Use open/read/write/close for binary saves instead of iostreams * Select slot hotkeys * Fix macros getting frame duplicated after loadstate * Advance macros after frame is complete, not before frame starts * SA1 tracing support + memorywatch/search SA1 IRAM * Recognize SA1IRAM for purposes of breakpoints * ZMBV full search mode * SNES: SA1 registers for memory.getregister/setregister * SNES: Pseudo-registers hcounter and vcounter * Memory search: Resolve memory area if possible * Merge multiple versions of get_read_address() into one * Lua: Deprecate global addresses * moviefile::get_movie_length: Use milliseconds, not nanoseconds * Use curl-config instead of -lcurl * Wipe all sorts of potentially sensitive stuff after use * Memory peek/poke: Accept and show relative addresses * Autodetect followed by undefined with multiple choices: Ask user * Lua: Fix some includes * Fix SA1 open bus * Trace logger (Window): Show start of frame * Trace logger: Allow deleting lines / clearing * Fix potential crash on exit * lsnes-dumpavi: Support downloading movies * Trace logger: Don't double free trace hooks * Support configurable URI shorthands * Movie editor: Draw clear / fix current column * Movie editor: Insert multiple lines at once * Fix loading states with movie-ahead without ROM * If loading ROM with multiple candidates, prompt before adding to recentrom * Tweak the RNG a bit * Some Win32 build fixes * TAS input keyboard support * Use urandom / rtlgenrandom rr2-β22 [Saturday January 24th 2015] ==================================== * Lua: memory.getregisters() * Zeroize: Don't crash if size=0 * Remove unused variable and some commented out debug code * movb -> lsnes_instance.mlogic * lsnes_memory -> lsnes_instance.memory * Don't extern lsnes_lua_state, it is only used in one file * lsnes_lua_state -> lsnes_instance.lua * lsnes_memorywatch -> lsnes_instance.mwatch * lsnes_vsetc -> lsnes_instance.setcache * Get rid of lsnes_vset[foo] * Instancefy inthread.cpp stuff * Instancefy subtitles.cpp stuff * Clean up some uses of lsnes_instance * Instancefy mbranch.cpp stuff * Kill unused generic_controller_name() * Instancefy multitrack.cpp stuff * Instancefy emustatus.cpp stuff * Split random number functions from misc.cpp to dedicated file * Move lsnes_kbd and lsnes_mapper to be instance vars * Command sets WIP * Simplify command::* memory management * Use recursive locks to deal with the locking mess in command::* * Delete some unused fields * Fix valgrind warnings in inthread.cpp * Inverse binding sets * EVDEV: Select on joysticks * Listener object is better than 3 lambdas + handle * Initialize fdset before polling on it * Setting sets * Kill command::set::get_commands() * Reduce dependicies between header files * keyboard.cpp: Get rid of register_queue * keyboard-mapper.cpp: Get rid of register_queue * Lua.cpp: Get rid of register-queue * settingvar.cpp: Get rid of register_queue * Lua.cpp: Don't call unregister callbacks if nothing get unreg'd * Kill off register-queue * Rename some classes * Move memorywatch stuff to dedicated namespace * Namespacify mathexpr * Move lua-framebuffer to lua namespace * lua.hpp: Forward-declare keyboard::key * controller_frame_vector: Use object instead of lambda for notify * Scope listener base classes inside respective master classes * Fix keyboard::keyboard::all_keys and all_modifiers * Toggle sound mute command/hotkey * Move directory stuff to dedicated namespace * Move rename_overwrite from zip:: to directory:: * Change some terms in UI * Don't crash if trying to select key without keys (shouldn't happen) * Instancefy alias binds management * Instancefy next rrdata * Instancefy internal emulation thread execution queue * Instancefy cart mappings * Make main controllers state a instance variable * Introduce run_show_error() and use it to clean up some code * Instancefy project state * Don't crash on exit with voice track loaded * Get rid of most absolute refs to lsnes_instance in src/core * run in emu thread: Throw exceptions over thread switches * Gambatte: Fix bus write breaks * Gambatte: Fix execute breaks on bus and IOAMHRAM * Don't corrupt memory when trying to GC various items on exit * Make the emulator harder to imporperly quit * Fix all sort of Windows stupidities * Add some test commands * Refactor debugging into instance object * Faster arithmetic modulo 2^255-19 on 64-bit * Remove broken crap * Some optimizations & fixes * Some more optimization, some test code for this thing * Move some debug stuff to be in class scope * Instancefy framerate stuff * Instancefy framebuffer stuff * Make various instance stuff to take references to other instance objs * Do some more stuff missed in last commit * Factor queue stuff to its own file * Make instance vars to be pointers * Properly handle deletes if those behave oddly on some platform * Remove unused dump_region_map() * Rewrite basic video dumping framework * Instancefy button manager stuff * Make helper class for instance member allocation / deallocation * Combine some small headers together * Factor message stream stuff to its own files * Some #include cleanup * Move render_video_hud and killed_audio_length to master dumper class * Refactor video dump framedrop handling * Instancefy dispatch stuff * Move action_update to be via dispatch * Remove unused load_rom_from_commandline * More include cleanups * Instancefy base mmio stuff * Get rid of direct references to emulation thread in branchesmenu.cpp * Use variable obtained earlier for current branch * Cleanup direct emulation thread references in editor-authors.cpp * Get rid of direct references from dumpmenu.cpp to emulation thread * Remove direct emulation thread references from keyboard.cpp * Sweep instance variables upward in UI code * Fix repainting status panel * More sweeping instance variables up * Eliminate settings_tab::call_window_fit(), nothing uses it * Push instances up out from settings window code * Push instance vars out of keyboard/mouse driver code * Do not use CORE() multiple times in the same function, it is pointless * Use helper class to simplify per-instance external vars * Fix warnings from valgrind * Refactor slotcache to be instance variable * Make some values const, remove some unused stuff * Lua: Memory address object * Kill emulation_thread, nothing uses it * lua::state::reset(): Use get instead of get_soft * Instancefy lua core stuff * Don't crash if exiting on panic * When panicing, show last message (as it is presumably related) * read_lua_fragment: Don't duplicate the script infinite number of times * Actually don't start if sysrc.lua is bad * Remove Lua 5.1 support * Make some arrow magic constants in gui-arrow.cpp const * Make render queue scratch variables instance variables * Some non-instance variables cleanup * Cleanup unused boost includes * Instancefy audioapi core (but not driver) stuff * Make some static variables in audioapi functions fields of audioapi class * Instancefy currently loaded ROM * Privatefy loaded_rom rtype, region and orig_region * Refactor save jukebox handling into its own class * Make class for emulator run mode * Factor updating status to its own class * Cleanup some symbols * Fix updating statusbar on save slot change * Clean up window-fileupload.cpp * Clean up use of project->moviepath/otherpath * Clean up instance usage in editor-voicesub.cpp * Use UI_in_project_context() in branchesmenu.cpp * bsnes: Fix on_latch in alttimings mode * Fix build on GCC 4.9 * Fix memory.writeregion * Fix compilation on Mac OS X * Fix loading lz images with 128 or more colors * Fix some accidentially mistyped variables in makefile * Lua: Initialize some variables in address.cpp to make GCC happy * Revert "Remove Lua 5.1 support" * 25519: Add valgrind test mode * Opus: Support some newly added stuff * Small whitespace cleanup * Commentary: Fix gain on oggopus export * Fix emulator going out of whack after project load * Add -pthread to flags * Don't overdraw in outside draw * Add few extra sound commands * Fix jukebox slot select * Remember sound device over sound restart * Remember sound devices * Oggopus: Complain about single-dpage streams with bad granulepos * Lua: memory.action_flags * Print messages about loaded libraries * Library: Don't fail link without library support * Wxwidgets: --library=<filename> * C interface: render_text (version bump to v2) * Music: Use all PSID LSIDs as implicit entrypoints (not just the first) * Refactor controller runtime code generation * Namespace library port-controller stuff * Refactor library GC to its own namespace * Refactor memory_region{,_direct} to be subclasses of memory_space * Make workthread a class in top namespace and move some stuff under it * Rename token_iterator_foreach to token_iterator::foreach * Split audioapi to core interface and driver interface parts * Fix crash if canceling load of other project * Allow memory watch to read registers * Show error dialog if project switch fails * Add missing file * gambatte fixes: Properly save MBC3 without RTC * Don't try to do controller runtime codegen on X32, it won't work * Memory watch fixes * Rudimentary library unloading support * Allow binding commands to class instance * Module unloading: Small cleanup * Module unloading: Small further cleanup * Reinitialize gamepads command and fix EVDEV going bonkers on gamepad suddenly disconnecting * Remove unused function * Show VMA relative hex address when dumping debug hook list * Tweak format of command help files and do some further command cleanup * Don't try to unregister killed debug CBs * bsnes: Add hcounter/vcounter registers * Tracelogger: Unregister the frame callback even on hard kill * Music playback: Guard against crazy pcmpos * Wxwidgets: Fix loading ROM from commandline * Fix most hotkeys to show up in configuration (were missing due to errant !) * Fix error message if trying to load ROM with project active * If project switch loads savestate, mark position at point of save * Squash some wrong-thread bugs * Memory editor: Squash another wrong-thread bug * Add the UI thread checking code * runuifun: Allow marking cb routine to run once at a time * wxwidgets: Add some missing conversions for string arguments * Oops from previous commit * Portaudio: Don't blacklist ALSA default/sysdefault for input * Redraw framebuffer when entering break pause * Fix some nondeterminism (probably wouldn't cause desyncs) * Lua: PALETTE:get() * Fix some valgrind warnings * Exit immediately on double fault * Update the default build options * Libao: Don't crash on quit * Remove some utilities that should not be there anymore * Use $DOT_EXECUTABLE_SUFFIX instead of hardcoding .exe * Fattest? Really? * Ignore some build helper programs, now that the .exe rule doesn't cover those * Don't use arbitrary garbage as amount of samples to squash * Show error from Lua if parsing Lua expression fails * Don't let one unload currently used core (crashes the emulator) * Lua 5.3 support * Cleanup Lua multiversion support * Add wide (64 bits) versions of bit functions if Lua 5.3 is used * Fix Win32 build * Fix compile error with Lua 5.1 * Clean up all build helper programs on make clean * Add commands and Lua functions to manipulate running speed * Remove target for font.cpp.dep * Readd rule for font.cpp.dep in different way * Pluginmanager: Autocreate directory instead of crashing * Fix bad download crashing the emulator * bsnes: DMA tracing * bsnes: Support IRQ/NMI tracing rr2-β23 [Thursday May 28th 2015] ================================ * Lua: Don't lua_error() out of context with pending dtors * Add $LSNES_NO_SOUND_IN to disable sound input * Makefile: Build cmdhelp before anything else * keymapper: Verify gamepad config write before committing * Remember volume settings across restarts * Remember video settings * Fix CUSTOMFONT text positioning * Only exit poll advance on poll to non-00 control * Show error instead silently failing tangent positive edge * Fix race condition in makefile * Fix scaling-related crashes * NULL video dumper * Fix some compilation errors on Mac OS X * Move all regex matching to library/string.cpp * Switch to std::regex by default * Movie editor: Don't lock up on trying to display error messages * Add a internal TODO list * Lua: add gui.get_runmode() * Movie editor: Fix unnamed branch to show properly in select branch * If initsram/initstate points to LSS file, pull the matching member * wxwidgets: Hide dumper called "NULL" * Force game panel to window size in fullscreen mode * Implicitly redirect cmdhelp includes to corresponding JSON files * Fix movie length being wrong for imported binary tracks * Lua: input.controller_info(): Don't crash with out-of-range port * Lua: movie.rom_loaded() * Lua: movie.get_rom_info() * Force a repaint when becoming fullscreen * wxwidgets: exit-fullscreen to forcibly exit fullscreen mode * Make gitlinks for bsnes and gambatte * Throw mic in to entropy pool * Fix hostendian memory watches * Fix race condition in do_mix_tsc() * Lua: Don't run class destructor if constructor failed * Fix typo in resolve_filename documentation * bit.(r)flagdecode: Fix unicode in on/off strings * Wxwidgets: Add keycode entries for å, ä and ö * Wxwidgets: Fix § * Wxwidgets: Fix some compile errors in editor-memorywatch.cpp * Wxwidgets: Fix some compile errors in window-fileupload.cpp * Lua: movie.get_game_info * Don't callback to Lua in inconsistent state when loading a new ROM * SNES: Functions for messing with clockrate (for debugging games) * Remove some unnecressary casts * Add back reload-rom and close-rom * Add load-rom command * Split overly large loaded_rom constructor * Fix speed going out of whack after doing unsafe rewind * Refactor loaded_rom to make public fields private * Move NULL core code to its own file * Internally refactor loaded ROM imageset out of loaded ROM code * Refer to loaded ROM imagesets as handles * A bit of code cleanup * Mark the core methods that should be idempotent as const * Refactor dynamic state to its own subobject * Refactor unsafe rewinding a bit now that state is its own subobject * Clean up dynamic state handling a bit * Circle coordinates can go negative and thus must be signed * Add dedicated method for resetting to poweron state * Add description of PALETTE:get() * Fix typo in Lua reference * Don't leak open file descriptors to loaded ROMs * Fix race between killing object and drawing object * Fix a compiler warning * Small rendering speedups * Actually kill objects using palette about to be GC'd * font rendering: Use ranges for bounding instead of buggy routine * Have only one main Lua function trampoline * Use master state for trampolines * Lua: Memory usage limit * Framework for memory usage tracking * Redo text rendering (adds halo support to gui.text()) * Make git diff --check happier * Clean up system font drawing * Memory tracker: Add tracking of render objects * Rework how memory tracking works * Small whitespace cleanup
Warning: Opinions expressed by Nach or others in this post do not necessarily reflect the views, opinions, or position of Nach himself on the matter(s) being discussed therein.
Fortranm
He/Him
Editor, Experienced player (773)
Joined: 10/19/2013
Posts: 1108
Does it mean running a GB game with bsnes in an older version of lsnes is not proper enough? BTW, Pokemon Green still cannot be played properly even in this version. Red just keeps walking upward.
Emulator Coder
Joined: 3/9/2004
Posts: 4588
Location: In his lab studying psychology to find new ways to torture TASers and forumers
Fortranm wrote:
Does it mean running a GB game with bsnes in an older version of lsnes is not proper enough?
Don't take things out of context. It's real SGB emulation with rerecording that works.
Fortranm wrote:
BTW, Pokemon Green still cannot be played properly even in this version. Red just keeps walking upward.
Please try clarifying what you mean. Some games unfortunately don't load, Pokémon Yellow among them. But for the games that do work, you should have a better experience TASing than before.
Warning: Opinions expressed by Nach or others in this post do not necessarily reflect the views, opinions, or position of Nach himself on the matter(s) being discussed therein.
Fortranm
He/Him
Editor, Experienced player (773)
Joined: 10/19/2013
Posts: 1108
In Pokemon Green, the player character automatically walks upward and cannot be stopped. The game can't be processed. Is this the right place to report bugs?
Emulator Coder
Joined: 3/9/2004
Posts: 4588
Location: In his lab studying psychology to find new ways to torture TASers and forumers
I reported this to Ilari, he said he'll look into it. As for right place to report bugs, since this is the SNES section, we should probably report generic lsnes or SNES related bugs here. Of course if you mean Pokemon Green in SGB mode, that becomes a gray area if it should be in this thread, or the parallel thread in the Gameboy Emulators section. If you meant in regular DMG mode, then you should report Pokemon bugs in the other thread.
Warning: Opinions expressed by Nach or others in this post do not necessarily reflect the views, opinions, or position of Nach himself on the matter(s) being discussed therein.
Editor, Skilled player (1502)
Joined: 7/9/2010
Posts: 1317
There's a "Emulate saving each frame" option in the new movie window, what does it do?
Favorite animal: STOCK Gt(ROSA)26Sortm1.1(rtTA,EGFP)Nagy Grm7Tg(SMN2)89Ahmb Smn1tm1Msd Tg(SMN2*delta7)4299Ahmb Tg(tetO-SMN2,-luc)#aAhmb/J YouTube Twitch
creaothceann
He/Him
Editor
Joined: 4/7/2005
Posts: 1874
Location: Germany
It emulate saving each frame?
Editor, Skilled player (1502)
Joined: 7/9/2010
Posts: 1317
I would assume you can rewind to any frame, if it does that, but it doesn't.
Favorite animal: STOCK Gt(ROSA)26Sortm1.1(rtTA,EGFP)Nagy Grm7Tg(SMN2)89Ahmb Smn1tm1Msd Tg(SMN2*delta7)4299Ahmb Tg(tetO-SMN2,-luc)#aAhmb/J YouTube Twitch
Player (39)
Joined: 7/7/2008
Posts: 871
Location: Utah
With this new version available, what would you say is the more superior version of emulating SNES games? Bizhawk or this?
Emulator Coder
Joined: 3/9/2004
Posts: 4588
Location: In his lab studying psychology to find new ways to torture TASers and forumers
Captain Forehead wrote:
With this new version available, what would you say is the more superior version of emulating SNES games? Bizhawk or this?
The vast majority of the time, they should be equal. On the other hand, if you look into which you can make a more sophisticated TAS, like the crazy stuff Masterjun is doing, or if you want to write extremely powerful LUA scripts, then you're better off with lsnes.
Warning: Opinions expressed by Nach or others in this post do not necessarily reflect the views, opinions, or position of Nach himself on the matter(s) being discussed therein.
Active player (405)
Joined: 2/5/2012
Posts: 1677
Location: Brasil
i would like to request/suggest a feature,memory search for intervals/ranges of values instead of just one single value,what is the correct place to suggest?
TAS i'm interested: megaman series: mmbn1 all chips, mmx3 any% psx glitched fighting games with speed goals in general
Amaraticando
It/Its
Editor, Player (157)
Joined: 1/10/2012
Posts: 673
Location: Brazil
Ilari does not check TASvideos anymore. You should make those requests at Freenode, #lsnes channel, to have a chance. For now, I think BizHawk's memory search is much better, though some advanced stuff can be done with Lua in lsnes.