1 #LyX 2.0 created this file. For more info see http://www.lyx.org/
6 \use_default_options true
7 \maintain_unincluded_children false
9 \language_package default
14 \font_typewriter default
15 \font_default_family default
16 \use_non_tex_fonts false
23 \default_output_format default
25 \bibtex_command default
26 \index_command default
27 \paperfontsize default
38 \paperorientation portrait
47 \paragraph_separation indent
48 \paragraph_indentation default
49 \quotes_language english
52 \paperpagestyle default
53 \tracking_changes false
66 \begin_layout Standard
67 lsnes is SNES rerecording emulator based on bsnes core.
74 \begin_layout Enumerate
79 \begin_layout Enumerate
83 \begin_layout Enumerate
84 accuracy or compatiblity core.
87 \begin_layout Enumerate
88 Patched version (using included 6 patches)
92 \begin_layout Enumerate
96 \begin_layout Enumerate
100 \begin_layout Enumerate
104 \begin_layout Enumerate
108 \begin_layout Enumerate
109 sdlmain (SDL only, part of SDL)
112 \begin_layout Enumerate
113 boost_conversion (this is header-only library)
116 \begin_layout Enumerate
117 libswscale (wxwidgets graphics only)
120 \begin_layout Enumerate
121 Portaudio (portaudio sound only)
124 \begin_layout Enumerate
125 std::thread and co (for threaded dumper only)
128 \begin_layout Enumerate
129 Lua (if Lua support is needed).
132 \begin_layout Itemize
133 Version 5.1.X or 5.2X.
136 \begin_layout Section
140 \begin_layout Standard
141 Building is via makefile, the following options are available:
144 \begin_layout Itemize
145 CROSS_PREFIX=<prefix>
149 \begin_layout Itemize
150 Prefix to apply to commands when building executables / object files for
151 the target architecture.
155 \begin_layout Itemize
160 \begin_layout Itemize
165 \begin_layout Itemize
166 Name of C++ compiler.
169 \begin_layout Itemize
170 CROSS_PREFIX is prepended if compiling for target architecture.
173 \begin_layout Itemize
174 This needs to be at least GCC 4.6.
177 \begin_layout Itemize
178 Set to 'g++-mp-4.6' if compiling on Mac OS X using GCC 4.6 from Macports.
181 \begin_layout Itemize
186 \begin_layout Itemize
191 \begin_layout Itemize
192 Name of host C++ compiler.
195 \begin_layout Itemize
196 Default is value of 'CC' option.
200 \begin_layout Itemize
201 USER_HOSTCCFLAGS=<flags>:
205 \begin_layout Itemize
206 Compiler flags to pass when compiling/linking for host architecture.
209 \begin_layout Itemize
214 \begin_layout Itemize
219 \begin_layout Itemize
220 Extra flags to pass when compiling for target architecture
223 \begin_layout Itemize
228 \begin_layout Itemize
229 USER_LDFLAGS=<flags>:
233 \begin_layout Itemize
234 Extra flags to pass when linking for target architecture.
237 \begin_layout Itemize
242 \begin_layout Itemize
243 USER_PLATFORM_CFLAGS=<flags>
247 \begin_layout Itemize
248 Extra flags to pass when compiling files using platform-dependent code for
252 \begin_layout Itemize
257 \begin_layout Itemize
258 USER_PLATFORM_LDFLAGS=<flags>
262 \begin_layout Itemize
263 Extra flags to pass when linking files using platform-dependent code for
267 \begin_layout Itemize
272 \begin_layout Itemize
277 \begin_layout Itemize
278 Set the font file to use.
281 \begin_layout Itemize
282 Currently the valid values are:
286 \begin_layout Itemize
287 cp437.hex: Standard VGA font (256 characters).
290 \begin_layout Itemize
291 unifontfull-5.1.20080820.hex: GNU unifont (covers most of Unicode BMP)
295 \begin_layout Itemize
296 Default is 'unifontfull-5.1.20080820.hex'
300 \begin_layout Itemize
305 \begin_layout Itemize
306 Package to use for Lua support.
309 \begin_layout Itemize
310 Usually valid value is 'lua' or 'lua5.1'.
313 \begin_layout Itemize
314 Default is not to build Lua support.
318 \begin_layout Itemize
323 \begin_layout Itemize
324 Override platform default for dumper threading support.
327 \begin_layout Itemize
328 Threading is default on Linux.
331 \begin_layout Itemize
332 'YES' tries to use threading.
335 \begin_layout Itemize
336 'NO' disables threading.
339 \begin_layout Itemize
340 Note: This has absolutely nothing to do with platform threading.
344 \begin_layout Itemize
345 BSNES_IS_COMPAT=<anything>
349 \begin_layout Itemize
350 Signals that BSNES core used is compatiblity core, not accuracy core.
353 \begin_layout Itemize
354 Default is to assume accuracy core.
358 \begin_layout Itemize
359 JOYSTICK=<implementation>
363 \begin_layout Itemize
364 Set joystick implementation.
369 \begin_layout Itemize
370 SDL: Use SDL for joystick (requires SDL graphics)
373 \begin_layout Itemize
374 EVDEV: Use EVDEV for joystick (Linux only).
377 \begin_layout Itemize
378 DUMMY: Disable joystick support.
382 \begin_layout Itemize
387 \begin_layout Itemize
388 SOUND=<implementation>
392 \begin_layout Itemize
393 Set sound implementation.
398 \begin_layout Itemize
399 SDL: Use SDL for sound (requires SDL graphics)
402 \begin_layout Itemize
403 PORTAUDIO: Use Portaudio for sound.
406 \begin_layout Itemize
407 DUMMY: Disable sound support
411 \begin_layout Itemize
416 \begin_layout Itemize
417 GRAPHICS=<implementation>
421 \begin_layout Itemize
422 Set windowing library to use.
427 \begin_layout Itemize
428 SDL: Use SDL for graphics
431 \begin_layout Itemize
432 WXWIDGETS: Use wxWidgets for graphics.
436 \begin_layout Itemize
441 \begin_layout Section
445 \begin_layout Subsection
449 \begin_layout Standard
450 <kind> in the following can be one of:
453 \begin_layout Itemize
454 rom: Cartridge ROM (BIOS for special carts).
458 \begin_layout Itemize
459 bsx: BS-X (non-slotted) Game flash ROM.
462 \begin_layout Itemize
463 bsxslotted: BS-X (slotted) Game flash ROM.
466 \begin_layout Itemize
470 \begin_layout Itemize
471 slot-a: Sufami Turbo Slot A ROM
474 \begin_layout Itemize
475 slot-b: Sufami Turbo Slot B ROM
478 \begin_layout Subsubsection
479 --<kind>=<file> (lsnes/SDL, lsnes-avidump)
482 \begin_layout Standard
483 Load <file> as specified ROM (SFC/BS/DMG/ST file format).
486 \begin_layout Subsubsection
487 --headered-<kind>=<file> (lsnes/SDL, lsnes-avidump)
490 \begin_layout Standard
491 Load <file> as specified ROM, stripping first 512 bytes.
492 Handy for loading SMC / FIG and such files.
495 \begin_layout Subsubsection
496 --<kind>-xml=<file> (lsnes/SDL, lsnes-avidump)
499 \begin_layout Standard
500 Override hardware detection for ROM, reading the values from <file> (BSNES
504 \begin_layout Subsubsection
505 --ips-<kind>=<file> (lsnes/SDL, lsnes-avidump)
508 \begin_layout Standard
509 Apply BPS/IPS patch <file> to ROM <kind>.
510 If specified multiple times, the patches are applied in order.
513 \begin_layout Subsubsection
514 --ips-<kind>-xml=<file> (lsnes/SDL, lsnes-avidump)
517 \begin_layout Standard
518 Apply BPS/IPS patch <file> to XML of ROM <kind>.
519 If specified multiple times, the patches are applied in order.
522 \begin_layout Subsubsection
523 --ips-offset=<offset> (lsnes/SDL, lsnes-avidump)
526 \begin_layout Standard
527 Set offset to apply to IPS patches.
529 Handy for applying headered IPS patches (use offset of -512 for this).
530 The offset must be 0 for BPS patches.
533 \begin_layout Subsubsection
537 \begin_layout Standard
538 Force ROM to be considered PAL-only.
541 \begin_layout Itemize
542 Only works on SNES and SGB ROMs (not BS-X or Sufami Turbo).
545 \begin_layout Itemize
546 Attempting to load NTSC movie file will error out.
549 \begin_layout Subsubsection
553 \begin_layout Standard
554 Force ROM to be considered NTSC-only.
557 \begin_layout Itemize
558 Attempting to load PAL movie file will error out.
561 \begin_layout Subsection
565 \begin_layout Subsubsection
566 <filename> (lsnes/SDL, lsnes-avidump, movieinfo)
569 \begin_layout Standard
570 Load <filename> as movie or savestate file.
571 All other session options are ignored.
574 \begin_layout Subsubsection
575 --port1=<device> (lsnes/SDL)
578 \begin_layout Standard
583 \begin_layout Itemize
584 none: No device connected
587 \begin_layout Itemize
588 gamepad: One gamepad (the default)
591 \begin_layout Itemize
592 multitap: Four gamepads (warning: makes most games refuse to start)
595 \begin_layout Itemize
599 \begin_layout Subsubsection
600 --port2=<type> (lsnes/SDL)
603 \begin_layout Standard
608 \begin_layout Itemize
609 none: No device connected (the default)
612 \begin_layout Itemize
616 \begin_layout Itemize
617 multitap: Four gamepads.
620 \begin_layout Itemize
624 \begin_layout Itemize
625 superscope: Super Scope
628 \begin_layout Itemize
629 justifier: One justifier
632 \begin_layout Itemize
633 justifiers: Two justifiers
636 \begin_layout Subsubsection
637 --gamename=<name> (lsnes/SDL)
640 \begin_layout Standard
641 Set the name of game to <name>.
645 \begin_layout Subsubsection
646 --author=<name> (lsnes/SDL)
649 \begin_layout Standard
650 Add author with full name of <name> (no nickname).
653 \begin_layout Subsubsection
654 --author=|<name> (lsnes/SDL)
657 \begin_layout Standard
658 Add author with nickname of <name> (no full name).
661 \begin_layout Subsubsection
662 --author=<fullname>|<nickname> (lsnes/SDL)
665 \begin_layout Standard
666 Add author with full name of <fullname> and nickname of <nickname>.
669 \begin_layout Subsubsection
670 --rtc-second=<value> (lsnes/SDL)
673 \begin_layout Standard
674 Set RTC second (0 is 1st January 1970 00:00:00Z).
675 Default is 1,000,000,000.
678 \begin_layout Subsubsection
679 --rtc-subsecond=<value> (lsnes/SDL)
682 \begin_layout Standard
689 \begin_layout Subsection
694 \begin_layout Subsubsection
695 --run=<file> (lsnes/SDL)
698 \begin_layout Standard
699 After running main RC file, run this file.
700 If multiple are specified, these execute in order specified.
703 \begin_layout Subsection
704 dump options (lsnes-dumpavi only)
707 \begin_layout Subsubsection
711 \begin_layout Standard
714 \begin_inset Quotes eld
718 \begin_inset Quotes erd
724 \begin_layout Subsubsection
728 \begin_layout Standard
729 Set compression level (0-18).
733 \begin_layout Subsubsection
737 \begin_layout Standard
738 Set number of frames to dump.
742 \begin_layout Subsubsection
746 \begin_layout Standard
747 Run specified lua script (lsnes-dumpavi does not have initialization files).
750 \begin_layout Subsubsection
754 \begin_layout Standard
755 Use JMD dumping instead of AVI dumping.
758 \begin_layout Subsubsection
762 \begin_layout Standard
763 Use SDMP dumping instead of AVI dumping.
766 \begin_layout Subsubsection
770 \begin_layout Standard
771 Dump in single segment (SDMP only).
774 \begin_layout Section
775 Startup file lsnes.rc
778 \begin_layout Standard
779 Upon startup, lsnes (lsnes/SDL only) executes file lsnes.rc as commands.
780 This file is located in:
783 \begin_layout Itemize
788 lsnes.rc (if %APPDATA% exists)
791 \begin_layout Itemize
792 Unix: $XDG_CONFIG_HOME/lsnes/lsnes.rc (if $XDG_CONFIG_HOME exists)
795 \begin_layout Itemize
796 Unix: $HOME/.config/lsnes/lsnes.rc (if $HOME exists)
799 \begin_layout Itemize
800 All: ./lsnes.rc (fallback default).
803 \begin_layout Standard
804 If leading directories do not exist, attempt to create them is made.
807 \begin_layout Section
811 \begin_layout Itemize
812 Commands beginning with '*' invoke the corresponding command without alias
816 \begin_layout Itemize
817 If command starts with '+' (after possible '*'), the command is executed
818 as-is when button is pressed, and when button is released, it is executed
819 with '+' replaced by '-'.
822 \begin_layout Itemize
823 Commands without '+' execute only on negative edge (release).
826 \begin_layout Subsection
830 \begin_layout Standard
831 Settings control various aspects of emulator behaviour.
834 \begin_layout Subsubsection
835 set-setting <setting> <value>
838 \begin_layout Standard
839 Sets setting <setting> to value <value> (may be empty).
842 \begin_layout Subsubsection
843 unset-setting <setting>
846 \begin_layout Standard
847 Try to unset setting <setting> (not all settings can be unset).
850 \begin_layout Subsubsection
851 get-setting <setting>
854 \begin_layout Standard
855 Read value of setting <setting>
858 \begin_layout Subsubsection
862 \begin_layout Standard
863 Print names and values of all settings.
866 \begin_layout Subsection
870 \begin_layout Standard
871 Keybindings bind commands or aliases to keys (or pseudo-keys).
875 \begin_layout Standard
879 \begin_layout Itemize
880 Do not bind edge active (+/-) commands to keys with modifiers, that won't
884 \begin_layout Itemize
885 Names of keys and modifiers are platform-dependent.
888 \begin_layout Itemize
889 Be careful before binding pseudo-keys (such as joystick axes, buttons or
890 hats) with modifiers.
891 That may or may not work right.
894 \begin_layout Subsubsection
895 bind-key [<mod>/<modmask>] <key> <command>
898 \begin_layout Standard
899 Bind <command> to key <key> (activating if modifiers in <modmask> (comma-seperat
900 ed list) are set as <mod> (comma-seperated list).
903 \begin_layout Standard
904 The names of keys and modifiers are platform-dependent.
907 \begin_layout Subsubsection
908 unbind-key [<mod>/<modmask>] <key>
911 \begin_layout Standard
912 Unbind command from <key> (with specified <mod> and <modmask>).
915 \begin_layout Subsubsection
916 set-axis <axis> [disabled | axis | axis-inverse | pressure0- | pressure0+
917 | pressure-0 | pressure-+ | pressure+0 | pressure+-] [minus=<val>] [zero=<val>]
918 [plus=<val>] [tolerance=<val>]
921 \begin_layout Standard
922 Set axis parameters for axis <axis>.
925 \begin_layout Itemize
926 disabled: Disable axis
929 \begin_layout Itemize
933 \begin_layout Itemize
934 axis-inverse: Inverse axis
937 \begin_layout Itemize
938 pressure0-: Pressure sensitive.
939 Released at 0, pressed at -.
942 \begin_layout Itemize
943 pressure0+: Pressure sensitive.
944 Released at 0, pressed at +.
947 \begin_layout Itemize
948 pressure-0: Pressure sensitive.
949 Released at -, pressed at 0.
952 \begin_layout Itemize
953 pressure-+: Pressure sensitive.
954 Released at -, pressed at +.
957 \begin_layout Itemize
958 pressure+0: Pressure sensitive.
959 Released at +, pressed at 0.
962 \begin_layout Itemize
963 pressure+-: Pressure sensitive.
964 Released at +, pressed at -.
967 \begin_layout Itemize
968 minus=<val>: Calibration at extreme minus position (-32768-32767)
971 \begin_layout Itemize
972 zero=<val>: Calibration at neutral position (-32768-32767)
975 \begin_layout Itemize
976 plus=<val>: Calibration at extreme plus position (-32768-32767)
979 \begin_layout Itemize
980 tolerance=<value>: Center band tolerance (0<x<1).
981 The smaller the value, the more sensitive the control is.
984 \begin_layout Subsubsection
988 \begin_layout Standard
989 Print all key bindings in effect.
992 \begin_layout Subsection
996 \begin_layout Standard
997 Aliases bind command to sequence of commands.
998 After alias has been defined, it replaces the command it shadows.
1001 \begin_layout Standard
1005 \begin_layout Itemize
1006 You can't alias command to itself.
1009 \begin_layout Itemize
1010 Aliases starting with +/- are edge active just like ordinary commands starting
1014 \begin_layout Itemize
1015 One command can be aliased to multiple commands.
1018 \begin_layout Subsubsection
1019 alias-command <command> <expansion>
1022 \begin_layout Standard
1023 Append <expansion> to alias <command>.
1024 If alias does not already exist, it is created.
1027 \begin_layout Subsubsection
1028 unalias-command <command>
1031 \begin_layout Standard
1032 Clear alias expansion for <command>.
1035 \begin_layout Subsubsection
1039 \begin_layout Standard
1040 Print all aliases and their expansions in effect.
1043 \begin_layout Subsection
1047 \begin_layout Standard
1048 Run <script> as if commands were entered on the command line.
1051 \begin_layout Subsection
1055 \begin_layout Standard
1056 Following commands control video dumping:
1059 \begin_layout Subsubsection
1063 \begin_layout Standard
1064 Dump AVI video to prefix <prefix> Notes:
1067 \begin_layout Itemize
1068 The codec is Camstudio Codec in gzip mode.
1071 \begin_layout Itemize
1072 Encoder and muxer are internal, available on all platforms.
1075 \begin_layout Itemize
1076 Audio enable/disable and framerate has no effect.
1079 \begin_layout Itemize
1080 The audio dumped to .avi is low-quality version.
1081 The high-quality version is dumped to .sox file.
1084 \begin_layout Subsubsection
1088 \begin_layout Standard
1089 End current AVI video dump (closing the emulator also closes the dump).
1092 \begin_layout Subsubsection
1096 \begin_layout Standard
1097 Dump JMD video to file <file>.
1100 \begin_layout Subsubsection
1104 \begin_layout Standard
1105 End the current JMD dump in progress.
1108 \begin_layout Subsubsection
1112 \begin_layout Standard
1113 Dump SDMP to <prefix>, splitting at 2GB.
1116 \begin_layout Subsubsection
1120 \begin_layout Standard
1121 Dump SDMP to <file>, no splitting
1124 \begin_layout Subsubsection
1128 \begin_layout Standard
1129 End the current SDMP dump in progress.
1132 \begin_layout Subsection
1136 \begin_layout Standard
1137 <address> may be decimal or hexadecimal (prefixed with '0x').
1138 <value> can be hexadecimal (prefixed with '0x'), unsigned or signed (prefixed
1142 \begin_layout Standard
1143 The available element <sizes> are:
1146 \begin_layout Itemize
1150 \begin_layout Itemize
1154 \begin_layout Itemize
1158 \begin_layout Itemize
1162 \begin_layout Standard
1163 When reading RAM and ROM, multi-byte reads/writes are big-endian.
1164 When dealing with DSP memory, multi-byte reads/writes are native-endian
1165 (do not use operand sizes exceeding DSP bitness, except dword is OK for
1169 \begin_layout Subsubsection
1170 read-<size> <address>
1173 \begin_layout Standard
1174 Read the value of byte in <address>.
1177 \begin_layout Subsubsection
1178 read-s<size> <address>
1181 \begin_layout Standard
1182 Read the value of signed byte in <address>.
1185 \begin_layout Subsubsection
1186 write-<size> <address> <value>
1189 \begin_layout Standard
1190 Write <value> to byte in address <address>.
1193 \begin_layout Subsubsection
1197 \begin_layout Standard
1198 Reset the memory search
1201 \begin_layout Subsubsection
1205 \begin_layout Standard
1206 Print number of candidates remaining
1209 \begin_layout Subsubsection
1213 \begin_layout Standard
1214 Print all candidates remaining
1217 \begin_layout Subsubsection
1218 search-memory <usflag><sizeflag><op>
1221 \begin_layout Standard
1222 Searches memory for addresses satisfying criteria.
1225 \begin_layout Standard
1229 \begin_layout Itemize
1233 \begin_layout Itemize
1237 \begin_layout Standard
1241 \begin_layout Itemize
1245 \begin_layout Itemize
1249 \begin_layout Itemize
1253 \begin_layout Itemize
1257 \begin_layout Standard
1261 \begin_layout Itemize
1262 lt: < previous value.
1265 \begin_layout Itemize
1266 le: <= previous value.
1269 \begin_layout Itemize
1270 eq: = previous value.
1273 \begin_layout Itemize
1274 ne: != previous value.
1277 \begin_layout Itemize
1278 ge: >= previous value.
1281 \begin_layout Itemize
1282 gt: > previous value.
1285 \begin_layout Subsubsection
1286 search-memory <sizeflag> <value>
1289 \begin_layout Standard
1290 Searches for addresses that currently have value <value>.
1291 <sizeflag> is as in previous command.
1294 \begin_layout Subsection
1298 \begin_layout Standard
1299 These commands are not available in lsnesrc, but are available after ROM
1303 \begin_layout Subsubsection
1307 \begin_layout Standard
1308 Quits the emulator (asking for confirmation).
1309 If /y is given, no confirmation is asked.
1312 \begin_layout Subsubsection
1316 \begin_layout Standard
1317 Toggle paused/unpaused
1320 \begin_layout Subsubsection
1324 \begin_layout Standard
1326 If the button is still held after configurable timeout expires, game unpauses
1327 for the duration frame advance is held.
1330 \begin_layout Subsubsection
1334 \begin_layout Standard
1336 If the button is still held after configurable timeout expires, game unpauses
1337 for the duration frame advance is held.
1340 \begin_layout Subsubsection
1344 \begin_layout Standard
1345 Skip to first poll in frame after current.
1348 \begin_layout Subsubsection
1352 \begin_layout Standard
1353 Reset the SNES after this frame.
1356 \begin_layout Subsubsection
1360 \begin_layout Standard
1361 Load savestate <filename> in current mode.
1364 \begin_layout Subsubsection
1365 load-state <filename>
1368 \begin_layout Standard
1369 Load savestate <filename> in readwrite mode.
1372 \begin_layout Subsubsection
1373 load-readonly <filename>
1376 \begin_layout Standard
1377 Load savestate <filename> in readonly mode.
1380 \begin_layout Subsubsection
1381 load-preserve <filename>
1384 \begin_layout Standard
1385 Load savestate <filename> in readonly mode, preserving current events.
1388 \begin_layout Subsubsection
1389 load-movie <filename>
1392 \begin_layout Standard
1393 Load savestate <filename>, ignoring save part in readonly mode.
1396 \begin_layout Subsubsection
1397 save-state <filename>
1400 \begin_layout Standard
1401 Save system state to <filename> as soon as possible.
1404 \begin_layout Subsubsection
1405 save-movie <filename>
1408 \begin_layout Standard
1409 Save movie to <filename>.
1412 \begin_layout Subsubsection
1416 \begin_layout Standard
1417 Set read-write mode.
1420 \begin_layout Subsubsection
1424 \begin_layout Standard
1428 \begin_layout Subsubsection
1432 \begin_layout Standard
1433 Toggle between read-only and read-write modes.
1436 \begin_layout Subsubsection
1440 \begin_layout Standard
1441 Set name of the game to <name>
1444 \begin_layout Subsubsection
1448 \begin_layout Standard
1449 Print the name of the game.
1452 \begin_layout Subsubsection
1456 \begin_layout Standard
1457 Adds new author <author>.
1458 If <author> does not contain '|' it is full name.
1459 If it contains '|', '|' splits the full name and nickname.
1462 \begin_layout Subsubsection
1463 edit-author <num> <author>
1466 \begin_layout Standard
1467 Edit the author in slot <num> (0-based) to be <author> (see add-author for
1471 \begin_layout Subsubsection
1475 \begin_layout Standard
1476 Remove author in slot <num>
1479 \begin_layout Subsubsection
1483 \begin_layout Standard
1487 \begin_layout Subsubsection
1488 test-1, test-2, test-3
1491 \begin_layout Standard
1492 Internal test commands.
1496 \begin_layout Subsubsection
1497 take-screenshot <filename>
1500 \begin_layout Standard
1501 Save screenshot to <filename>.
1504 \begin_layout Subsubsection
1505 +controller<num><button>
1508 \begin_layout Standard
1509 Press button <button> on controller <num> (1-8).
1510 The following button names are known:
1513 \begin_layout Itemize
1517 \begin_layout Itemize
1521 \begin_layout Itemize
1525 \begin_layout Itemize
1529 \begin_layout Itemize
1533 \begin_layout Itemize
1537 \begin_layout Itemize
1541 \begin_layout Itemize
1545 \begin_layout Itemize
1549 \begin_layout Itemize
1553 \begin_layout Itemize
1557 \begin_layout Itemize
1561 \begin_layout Itemize
1565 \begin_layout Itemize
1569 \begin_layout Itemize
1573 \begin_layout Itemize
1577 \begin_layout Subsubsection
1578 controllerh<num><button>
1581 \begin_layout Standard
1582 Hold/unhold button <button> on controller <num> (1-8).
1583 See +controller for button names.
1586 \begin_layout Subsubsection
1587 autofire (<pattern>|-)...
1590 \begin_layout Standard
1591 Set autofire pattern.
1592 Each parameter is comma-separated list of button names (in form of 1start,
1593 1A, 2B, etc..) to hold on that frame.
1594 After reaching the end of pattern, the pattern restarts from the beginning.
1597 \begin_layout Subsubsection
1601 \begin_layout Standard
1605 \begin_layout Subsection
1609 \begin_layout Subsubsection
1610 cycle-jukebox-backward
1613 \begin_layout Standard
1614 Cycle save jukebox backwards.
1617 \begin_layout Subsubsection
1618 cycle-jukebox-forward
1621 \begin_layout Standard
1622 Cycle save jukebox forwards
1625 \begin_layout Subsubsection
1626 add-jukebox-save <filename>
1629 \begin_layout Standard
1630 Add <filename> to jukebox saves.
1633 \begin_layout Subsubsection
1637 \begin_layout Standard
1638 Do load from jukebox (current mode).
1641 \begin_layout Subsubsection
1645 \begin_layout Standard
1646 Do state save to jukebox.
1649 \begin_layout Subsection
1653 \begin_layout Standard
1654 Only available if lua support is compiled in.
1657 \begin_layout Subsubsection
1658 evaluate-lua <luacode>
1661 \begin_layout Standard
1662 Run Lua code <luacode> using built-in Lua interpretter.
1665 \begin_layout Subsubsection
1669 \begin_layout Standard
1670 Run specified lua file using built-in Lua interpretter.
1673 \begin_layout Subsection
1677 \begin_layout Subsubsection
1678 add-watch <name> <expression>
1681 \begin_layout Standard
1682 Adds new watch (or modifies old one).
1685 \begin_layout Subsubsection
1689 \begin_layout Standard
1693 \begin_layout Subsection
1697 \begin_layout Subsubsection
1698 enable-sound <on/off>
1701 \begin_layout Standard
1702 Enable/Disable sound.
1705 \begin_layout Subsubsection
1706 set-sound-device <device>
1709 \begin_layout Standard
1710 Set sound device to <device>
1713 \begin_layout Subsubsection
1717 \begin_layout Standard
1718 Show status of sound system.
1721 \begin_layout Subsubsection
1725 \begin_layout Standard
1726 Show all available devices.
1729 \begin_layout Subsection
1730 SDL Platform commands
1733 \begin_layout Standard
1734 The following are valid on SDL platform.
1737 \begin_layout Subsubsection
1741 \begin_layout Standard
1742 Asks to press a key and then identifies that (pseudo-)key.
1745 \begin_layout Subsubsection
1749 \begin_layout Standard
1750 Toggle between windowed/fullscreen console.
1753 \begin_layout Subsubsection
1757 \begin_layout Standard
1758 Scroll messages window as far back as it goes.
1761 \begin_layout Subsubsection
1765 \begin_layout Standard
1766 Scroll messages window as far forward as it goes.
1769 \begin_layout Subsubsection
1773 \begin_layout Standard
1774 Scroll messages window back one screenful.
1777 \begin_layout Subsubsection
1781 \begin_layout Standard
1782 Scroll messages window forward one screenful.
1785 \begin_layout Section
1789 \begin_layout Subsection
1793 \begin_layout Subsubsection
1797 \begin_layout Standard
1798 Set where bsnes looks for firmware files.
1800 \begin_inset Quotes eld
1804 \begin_inset Quotes erd
1810 \begin_layout Subsubsection
1814 \begin_layout Standard
1816 Numeric, range is 0.001 to
1817 \begin_inset Quotes eld
1821 \begin_inset Quotes erd
1825 Default is native framerate.
1828 \begin_layout Subsubsection
1832 \begin_layout Standard
1833 Set save compression level (integer 0-9).
1834 Default is 7 (0 is no compression).
1837 \begin_layout Subsubsection
1841 \begin_layout Standard
1842 Set the frame advance timeout in milliseconds.
1843 Numeric integer, range is 0-999999999.
1847 \begin_layout Subsection
1851 \begin_layout Subsubsection
1855 \begin_layout Standard
1856 AVI dumper: Always dump at 512x448 or 512x478 regardless of what the console
1860 \begin_layout Subsubsection
1864 \begin_layout Standard
1865 AVI dumper: Set the default left border thickness (unless lua overrides)
1871 \begin_layout Subsubsection
1875 \begin_layout Standard
1876 AVI dumper: Set the default right border thickness (unless lua overrides)
1882 \begin_layout Subsubsection
1886 \begin_layout Standard
1887 AVI dumper: Set the default top border thickness (unless lua overrides)
1893 \begin_layout Subsubsection
1897 \begin_layout Standard
1898 AVI dumper: Set the default bottom border thickness (unless lua overrides)
1904 \begin_layout Subsubsection
1908 \begin_layout Standard
1909 AVI dumper: Maximum number of frames per dump segment (0 => unlimited).
1914 \begin_layout Subsubsection
1918 \begin_layout Standard
1919 AVI dumper: Compression level (0-18).
1922 \begin_layout Itemize
1923 Compression levels 10 and above are not compatible with stock CSCD codec.
1926 \begin_layout Itemize
1927 Recomended level is 7.
1930 \begin_layout Subsection
1934 \begin_layout Subsubsection
1938 \begin_layout Standard
1939 JMD dumper: Compression level (0-9).
1942 \begin_layout Subsection
1943 SDL platform settings
1946 \begin_layout Subsubsection
1947 autorepeat-first-delay
1950 \begin_layout Standard
1951 Sets the delay for first character in typematic autorepeat.
1954 \begin_layout Subsubsection
1955 autorepeat-subsequent-delay
1958 \begin_layout Standard
1959 Sets the delay for subsequent characters in typematic autorepeat.
1962 \begin_layout Section
1966 \begin_layout Subsection
1967 Core (in main table)
1970 \begin_layout Subsubsection
1974 \begin_layout Standard
1975 Print line to message console.
1978 \begin_layout Subsubsection
1979 exec(string command)
1982 \begin_layout Standard
1983 Run command as it was entered on the command line
1986 \begin_layout Subsection
1990 \begin_layout Standard
1991 Bitwise logical functions and related.
1994 \begin_layout Subsubsection
1995 bit.none(number...) / bit.bnot(number...)
1998 \begin_layout Standard
1999 48-bit bitwise NOT / NONE function (set bits that are set in none of the
2003 \begin_layout Subsubsection
2004 bit.any(number...) / bit.bor(number...)
2007 \begin_layout Standard
2008 48-bit bitwise OR / ANY function (set bits that are set in any of the arguments).
2011 \begin_layout Subsubsection
2012 bit.all(number...) / bit.band(number...)
2015 \begin_layout Standard
2016 48-bit bitwise AND / ALL function (set bits that are set in all of the arguments
2020 \begin_layout Subsubsection
2021 bit.parity(number...) / bit.bxor(number...)
2024 \begin_layout Standard
2025 48-bit bitwise XOR / PARITY function (set bits that are set in odd number
2029 \begin_layout Subsubsection
2030 bit.lrotate(number base[, number amount[, number bits]])
2033 \begin_layout Standard
2034 Rotate bits-bit (max 48, default 48) number left by amount (default 1) places.
2037 \begin_layout Subsubsection
2038 bit.rrotate(number base[, number amount[, number bits]])
2041 \begin_layout Standard
2042 Rotate bits-bit (max 48, default 48) number right by amount (default 1)
2046 \begin_layout Subsubsection
2047 bit.lshift(number base[, number amount[, number bits]])
2050 \begin_layout Standard
2051 Shift bits-bit (max 48, default 48) number left by amount (default 1) places.
2052 The new bits are filled with zeroes.
2055 \begin_layout Subsubsection
2056 bit.lrshift(number base[, number amount[, number bits]])
2059 \begin_layout Standard
2060 Shift bits-bit (max 48, default 48) number logically right by amount (default
2062 The new bits are filled with zeroes.
2065 \begin_layout Subsubsection
2066 bit.arshift(number base[, number amount[, number bits]])
2069 \begin_layout Standard
2070 Shift bits-bit (max 48, default 48) number arithmetically right by amount
2072 The new bits are shifted in with copy of the high bit.
2075 \begin_layout Subsection
2079 \begin_layout Standard
2080 Most of these functions can only be called in on_paint and on_video callbacks.
2081 Exceptions are noted.
2084 \begin_layout Standard
2086 Bits 0-7 are the blue component, bits 8-15 are the green component, bits
2087 16-23 are the red component, bits 24-31 are alpha component (0 is fully
2088 opaque, 255 is almost transparent).
2089 -1 is the fully transparent color.
2090 Alpha values greater than 127 do work.
2093 \begin_layout Standard
2094 Origin of coordinates is at top left corner of game display area.
2095 Left and top gaps correspond to negative coordinates.
2098 \begin_layout Subsubsection
2102 \begin_layout Standard
2103 Returns 2-tuple (hresolution, vresolution).
2106 \begin_layout Subsubsection
2107 gui.<class>_gap(number gap)
2110 \begin_layout Standard
2111 Set the <class> (left, right, top, bottom) gap to specified value (max gap
2115 \begin_layout Subsubsection
2116 gui.text(number x, number y, string text[, number fgc[, number bgc]])
2119 \begin_layout Standard
2120 Draw specified text on the GUI (each character cell is 8 or 16 wide and
2125 \begin_layout Itemize
2126 x: X-coordinate to start the drawing from (and x-coordinate at begining
2130 \begin_layout Itemize
2131 y: Y-coordinate to start the drawing from.
2134 \begin_layout Itemize
2135 text: The text to draw.
2138 \begin_layout Itemize
2139 fgc: Text color (default is 0xFFFFFF (white))
2142 \begin_layout Itemize
2143 bgc: Background color (default is -1 (transparent))
2146 \begin_layout Subsubsection
2147 gui.textH(number x, number y, string text[, number fgc[, number bgc]])
2150 \begin_layout Standard
2151 Like gui.text, but draw using double-width.
2154 \begin_layout Subsubsection
2155 gui.textV(number x, number y, string text[, number fgc[, number bgc]])
2158 \begin_layout Standard
2159 Like gui.text, but draw using double-height.
2162 \begin_layout Subsubsection
2163 gui.textHV(number x, number y, string text[, number fgc[, number bgc]])
2166 \begin_layout Standard
2167 Like gui.text, but draw using double-width/double-height.
2170 \begin_layout Subsubsection
2171 gui.rectangle(number x, number y, number width, number height[, number thickness[
2172 , number outline[, number fill]]])
2175 \begin_layout Standard
2176 Draw rectangle on the GUI.
2180 \begin_layout Itemize
2181 x: X-coordinate of left edge.
2184 \begin_layout Itemize
2185 y: Y-coordinate of upper edge.
2188 \begin_layout Itemize
2189 width: Width of rectangle.
2192 \begin_layout Itemize
2193 height: Height of rectangle.
2196 \begin_layout Itemize
2197 thickness: Thickness of outline (default is 1).
2200 \begin_layout Itemize
2201 outline: Color of outline (default is 0xFFFFFF (white))
2204 \begin_layout Itemize
2205 fill: Color of fil (default is -1 (transparent))
2208 \begin_layout Subsubsection
2209 gui.pixel(number x, number y[, number color])
2212 \begin_layout Standard
2213 Draw one pixel on the GUI.
2217 \begin_layout Itemize
2218 x: X-coordinate of the pixel
2221 \begin_layout Itemize
2222 y: Y-coordinate of the pixel
2225 \begin_layout Itemize
2226 color: Color of the pixel (default is 0xFFFFFF (white))
2229 \begin_layout Subsubsection
2230 gui.crosshair(number x, number y[, number length[, number color]])
2233 \begin_layout Standard
2238 \begin_layout Itemize
2239 x: X-coordinate of the crosshair
2242 \begin_layout Itemize
2243 y: Y-coordinate of the crosshair
2246 \begin_layout Itemize
2247 length: Length of the crosshair lines (default 10).
2250 \begin_layout Itemize
2251 color: Color of the crosshair (default is 0xFFFFFF (white))
2254 \begin_layout Subsubsection
2255 gui.line(number x1, number y1, number x2, number y2[, number color])
2258 \begin_layout Standard
2263 \begin_layout Itemize
2264 x1: X-coordinate of one end.
2267 \begin_layout Itemize
2268 y1: Y-coordinate of one end.
2271 \begin_layout Itemize
2272 x2: X-coordinate of the other end.
2275 \begin_layout Itemize
2276 y2: Y-coordinate of the other end.
2279 \begin_layout Itemize
2280 color: Color of the line (default is 0xFFFFFF (white)).
2283 \begin_layout Subsubsection
2284 gui.circle(number x, number y, number r[, number thick[, number border[,
2288 \begin_layout Standard
2293 \begin_layout Itemize
2294 x: X-coordinate of the center
2297 \begin_layout Itemize
2298 y: Y-coordinate of the center
2301 \begin_layout Itemize
2302 r: The radius of the circle
2305 \begin_layout Itemize
2306 thick: Border thickness
2309 \begin_layout Itemize
2310 border: Border color (default is 0xFFFFFF (white))
2313 \begin_layout Itemize
2314 fill: Fill color (default is -1 (transparent)).
2317 \begin_layout Subsubsection
2321 \begin_layout Standard
2322 Request on_repaint() to happen as soon as possible.
2323 Can be used anywhere.
2326 \begin_layout Subsubsection
2327 gui.subframe_update(boolean on)
2330 \begin_layout Standard
2331 Request subframe updates (calling on_paint() on subframes) to happen (on=true)
2332 or not happen (on=false).
2333 Can be used anywhere.
2336 \begin_layout Subsubsection
2337 gui.screenshot(string filename)
2340 \begin_layout Standard
2341 Write PNG screenshot of the current frame (no drawings) to specified file.
2342 Can be used anywhere.
2345 \begin_layout Subsubsection
2346 gui.color(number r, number g, number b[, number a])
2349 \begin_layout Standard
2350 Returns color (in notation Lua scripts use) corresponding to color (r,g,b),
2351 each component in scale 0-255.
2352 If a is specified, that is alpha (0 is fully transparent, 256(sic) is fully
2354 The default alpha is 256.
2357 \begin_layout Subsubsection
2358 gui.status(string name, string value)
2361 \begin_layout Standard
2363 \begin_inset Quotes eld
2367 \begin_inset Quotes erd
2370 to <value> in status area.
2371 Can be used anywhere.
2374 \begin_layout Subsection
2378 \begin_layout Standard
2380 Only available in on_input callback.
2383 \begin_layout Subsubsection
2384 input.get(number controller, number index)
2387 \begin_layout Standard
2388 Read the specified index (0-11) from specified controller (0-7).
2392 \begin_layout Itemize
2393 Uses physical controller numbering.
2394 Gamepad in port 2 is controller 4, not 1!
2397 \begin_layout Subsubsection
2398 input.set(number controller, number index, number value)
2401 \begin_layout Standard
2402 Write the specified index (0-11) from specified controller (0-7), storing
2407 \begin_layout Itemize
2408 Uses physical controller numbering.
2409 Gamepad in port 2 is controller 4, not 1!
2412 \begin_layout Subsubsection
2413 input.reset([number cycles])
2416 \begin_layout Standard
2418 If cycles is greater than zero, do delayed reset.
2419 0 (or no value) causes immediate reset.
2422 \begin_layout Itemize
2423 Only available with subframe flag false.
2426 \begin_layout Subsection
2430 \begin_layout Standard
2431 Host memory handling (extra memory saved to savestates).
2432 Host memory starts empty.
2435 \begin_layout Subsubsection
2436 hostmemory.read(number address)
2439 \begin_layout Standard
2440 Reads hostmemory slot address.
2441 Slot numbers out of range return false instead of numeric.
2444 \begin_layout Subsubsection
2445 hostmemory.write(number address, number value)
2448 \begin_layout Standard
2449 Writes hostmemory slot with 0-255.
2450 Slot numbers out of range cause extension of host memory slot space.
2453 \begin_layout Subsubsection
2454 hostmemory.readbyte(number address)
2457 \begin_layout Standard
2458 Read unsigned byte (1 element) from given address.
2459 Slots out of range return false.
2462 \begin_layout Subsubsection
2463 hostmemory.writebyte(number address, number value)
2466 \begin_layout Standard
2467 Write unsigned byte (1 element) to given slot.
2468 Slot numbers out of range cause extension.
2471 \begin_layout Subsubsection
2472 hostmemory.readsbyte(number address)
2475 \begin_layout Standard
2476 Read signed byte (1 element) from given address.
2477 Slots out of range return false.
2480 \begin_layout Subsubsection
2481 hostmemory.writesbyte(number address, number value)
2484 \begin_layout Standard
2485 Write signed byte (1 element) to given slot.
2486 Slot numbers out of range cause extension.
2489 \begin_layout Subsubsection
2490 hostmemory.readword(number address)
2493 \begin_layout Standard
2494 Read unsigned word (2 elements) from given address.
2495 Slots out of range return false.
2498 \begin_layout Subsubsection
2499 hostmemory.writeword(number address, number value)
2502 \begin_layout Standard
2503 Write unsigned word (2 elements) to given slot.
2504 Slot numbers out of range cause extension.
2507 \begin_layout Subsubsection
2508 hostmemory.readsword(number address)
2511 \begin_layout Standard
2512 Read signed word (2 elements) from given address.
2513 Slots out of range return false.
2516 \begin_layout Subsubsection
2517 hostmemory.writesword(number address, number value)
2520 \begin_layout Standard
2521 Write signed word (2 elements) to given slot.
2522 Slot numbers out of range cause extension.
2525 \begin_layout Subsubsection
2526 hostmemory.readdword(number address)
2529 \begin_layout Standard
2530 Read unsigned doubleword (4 elements) from given address.
2531 Slots out of range return false.
2534 \begin_layout Subsubsection
2535 hostmemory.writedword(number address, number value)
2538 \begin_layout Standard
2539 Write unsigned doubleword (4 elements) to given slot.
2540 Slot numbers out of range cause extension.
2543 \begin_layout Subsubsection
2544 hostmemory.readsdword(number address)
2547 \begin_layout Standard
2548 Read signed doubleword (4 elements) from given address.
2549 Slots out of range return false.
2552 \begin_layout Subsubsection
2553 hostmemory.writesdword(number address, number value)
2556 \begin_layout Standard
2557 Write signed doubleword (4 elements) to given slot.
2558 Slot numbers out of range cause extension.
2561 \begin_layout Subsubsection
2562 hostmemory.readqword(number address)
2565 \begin_layout Standard
2566 Read unsigned quadword (8 elements) from given address.
2567 Slots out of range return false.
2570 \begin_layout Subsubsection
2571 hostmemory.writeqword(number address, number value)
2574 \begin_layout Standard
2575 Write unsigned quadword (4 elements) to given slot.
2576 Slot numbers out of range cause extension.
2579 \begin_layout Subsubsection
2580 hostmemory.readsqword(number address)
2583 \begin_layout Standard
2584 Read signed quadword (8 elements) from given address.
2585 Slots out of range return false.
2588 \begin_layout Subsubsection
2589 hostmemory.writesqword(number address, number value)
2592 \begin_layout Standard
2593 Write signed quadword (8 elements) to given slot.
2594 Slot numbers out of range cause extension.
2597 \begin_layout Subsection
2601 \begin_layout Standard
2605 \begin_layout Subsubsection
2606 movie.currentframe()
2609 \begin_layout Standard
2610 Return number of current frame.
2613 \begin_layout Subsubsection
2617 \begin_layout Standard
2618 Return number of frames in movie.
2621 \begin_layout Subsubsection
2625 \begin_layout Standard
2626 Return true if in readonly mode, false if in readwrite.
2629 \begin_layout Subsubsection
2630 movie.set_readwrite()
2633 \begin_layout Standard
2634 Set readwrite mode (does not cause on_readwrite callback).
2637 \begin_layout Subsubsection
2638 movie.frame_subframes(number frame)
2641 \begin_layout Standard
2642 Count number of subframes in specified frame (frame numbers are 1-based)
2646 \begin_layout Subsubsection
2647 movie.read_subframe(number frame, number subframe)
2650 \begin_layout Standard
2651 Read specifed subframe in specified frame and return data as array (100
2652 elements, numbered 0-99 currently).
2655 \begin_layout Subsection
2659 \begin_layout Standard
2660 Routines for settings manipulation
2663 \begin_layout Subsubsection
2664 settings.get(string name)
2667 \begin_layout Standard
2668 Get value of setting.
2669 If setting is blank, returns false.
2670 If setting value can't be obtained, returns (nil, error message).
2673 \begin_layout Subsubsection
2674 settings.set(string name, string value)
2677 \begin_layout Standard
2678 Set value of setting.
2679 If setting can't be set, returns (nil, error message).
2682 \begin_layout Subsubsection
2683 settings.is_set(string name)
2686 \begin_layout Standard
2687 Returns if setting is set.
2688 If setting does not exist, returns (nil, error message).
2691 \begin_layout Subsubsection
2692 settings.blank(string name)
2695 \begin_layout Standard
2696 Blanks a setting and returns true.
2697 If setting can't be blanked, returns (nil, error message).
2700 \begin_layout Subsection
2704 \begin_layout Standard
2705 Contains various functions for managing memory
2708 \begin_layout Subsubsection
2712 \begin_layout Standard
2713 Returns the number of VMAs
2716 \begin_layout Subsubsection
2717 memory.read_vma(number index)
2720 \begin_layout Standard
2721 Reads the specified VMA (indices start from zero).
2722 Trying to read invalid VMA gives nil.
2723 The read VMA is table with the following fields:
2726 \begin_layout Itemize
2727 region_name (string): The readable name of the VMA
2730 \begin_layout Itemize
2731 baseaddr (number): Base address of the VMA
2734 \begin_layout Itemize
2735 lastaddr (number): Last address in the VMA.
2738 \begin_layout Itemize
2739 size (number): The size of VMA in bytes.
2742 \begin_layout Itemize
2743 readonly (boolean): True of the VMA corresponds to ROM.
2746 \begin_layout Itemize
2747 native_endian (boolean): True if the VMA has native endian as opposed to
2751 \begin_layout Subsubsection
2752 memory.find_vma(number address)
2755 \begin_layout Standard
2756 Finds the VMA containing specified address.
2757 Returns table in the same format as read_vma or nil if not found.
2760 \begin_layout Subsubsection
2761 memory.readbyte(number address)
2764 \begin_layout Standard
2765 Reads the specified address as unsigned byte and returns the result.
2768 \begin_layout Subsubsection
2769 memory.readsbyte(number address)
2772 \begin_layout Standard
2773 Reads the specified address as signed byte and returns the result.
2776 \begin_layout Subsubsection
2777 memory.writebyte(number address, number value)
2780 \begin_layout Standard
2781 Writes the specified value (negative values undergo 2's complement) to specified
2782 address (as a byte).
2785 \begin_layout Subsubsection
2786 memory.readword(number address)
2789 \begin_layout Standard
2790 Reads the specified address as unsigned word and returns the result.
2793 \begin_layout Subsubsection
2794 memory.readsword(number address)
2797 \begin_layout Standard
2798 Reads the specified address as signed word and returns the result.
2801 \begin_layout Subsubsection
2802 memory.writeword(number address, number value)
2805 \begin_layout Standard
2806 Writes the specified value (negative values undergo 2's complement) to specified
2807 address (as a word).
2810 \begin_layout Subsubsection
2811 memory.readdword(number address)
2814 \begin_layout Standard
2815 Reads the specified address as unsigned doubleword and returns the result.
2818 \begin_layout Subsubsection
2819 memory.readsdword(number address)
2822 \begin_layout Standard
2823 Reads the specified address as signed doubleword and returns the result.
2826 \begin_layout Subsubsection
2827 memory.writedword(number address, number value)
2830 \begin_layout Standard
2831 Writes the specified value (negative values undergo 2's complement) to specified
2832 address (as a doubleword).
2835 \begin_layout Subsubsection
2836 memory.readqword(number address)
2839 \begin_layout Standard
2840 Reads the specified address as unsigned quadword and returns the result.
2843 \begin_layout Subsubsection
2844 memory.readsqword(number address)
2847 \begin_layout Standard
2848 Reads the specified address as signed quadword and returns the result.
2851 \begin_layout Subsubsection
2852 memory.writeqword(number address, number value)
2855 \begin_layout Standard
2856 Writes the specified value (negative values undergo 2's complement) to specified
2857 address (as a quadword).
2860 \begin_layout Subsection
2864 \begin_layout Standard
2865 Contains copy of global variables from time of Lua initialization.
2869 \begin_layout Subsection
2873 \begin_layout Standard
2874 Various callbacks to Lua that can occur.
2877 \begin_layout Subsubsection
2878 Callback: on_paint()
2881 \begin_layout Standard
2882 Called when screen is being painted.
2883 Any gui.* calls requiring graphic context draw on the screen.
2886 \begin_layout Subsubsection
2887 Callback: on_video()
2890 \begin_layout Standard
2891 Called when video dump frame is being painted.
2892 Any gui.* calls requiring graphic context draw on the video.
2895 \begin_layout Subsubsection
2896 Callback: on_frame()
2899 \begin_layout Standard
2900 Called on each starting whole frame.
2903 \begin_layout Subsubsection
2904 Callback: on_startup()
2907 \begin_layout Standard
2908 Called when the emulator is starting (lsnes.rc and --run files has been run).
2911 \begin_layout Subsubsection
2912 Callback: on_pre_load(string name)
2915 \begin_layout Standard
2916 Called just before savestate/movie load occurs (note: loads are always delayed,
2917 so this occurs even when load was initiated by lua).
2920 \begin_layout Subsubsection
2921 Callback: on_err_load(string name)
2924 \begin_layout Standard
2925 Called if loadstate goes wrong.
2928 \begin_layout Subsubsection
2929 Callback: on_post_load(string name, boolean was_savestate)
2932 \begin_layout Standard
2933 Called on successful loadstate.
2934 was_savestate gives if this was a savestate or a movie.
2937 \begin_layout Subsubsection
2938 Callback: on_pre_save(string name, boolean is_savestate)
2941 \begin_layout Standard
2942 Called just before savestate save occurs (note: movie saves are synchronous
2943 and won't trigger these callbacks if called from Lua).
2946 \begin_layout Subsubsection
2947 Callback: on_err_save(string name)
2950 \begin_layout Standard
2951 Called if savestate goes wrong.
2954 \begin_layout Subsubsection
2955 Callback: on_post_save(string name, boolean is_savestate)
2958 \begin_layout Standard
2959 Called on successful savaestate.
2960 is_savestate gives if this was a savestate or a movie.
2963 \begin_layout Subsubsection
2967 \begin_layout Standard
2968 Called when emulator is shutting down.
2971 \begin_layout Subsubsection
2972 Callback: on_input(boolean subframe)
2975 \begin_layout Standard
2976 Called when emulator is just sending input to bsnes core.
2977 Warning: This is called even in readonly mode, but the results are ignored.
2980 \begin_layout Subsubsection
2981 Callback: on_reset()
2984 \begin_layout Standard
2985 Called when SNES is reset.
2988 \begin_layout Subsubsection
2989 Callback: on_readwrite()
2992 \begin_layout Standard
2993 Called when moving into readwrite mode as result of
2994 \begin_inset Quotes eld
2998 \begin_inset Quotes erd
3001 command (note: moving to rwmode by Lua won't trigger this, as per recursive
3005 \begin_layout Subsubsection
3006 Callback: on_snoop(number port, number controller, number index, number
3010 \begin_layout Standard
3011 Called each time bsnes asks for input.
3012 The value is the final value to be sent to bsnes core (readonly mode, autohold
3013 and autofire have been taken into account).
3014 Might be useful when translating movies to format suitable for console
3016 Note: There is no way to modify the value to be sent.
3019 \begin_layout Section
3020 Modifier and key names:
3023 \begin_layout Subsection
3027 \begin_layout Subsubsection
3031 \begin_layout Standard
3032 Following modifier names are known:
3035 \begin_layout Itemize
3036 ctrl, lctrl, rctrl: Control keys
3039 \begin_layout Itemize
3040 alt, lalt, ralt: ALT keys.
3043 \begin_layout Itemize
3044 shift, lshift, rshift: Shift keys.
3047 \begin_layout Itemize
3048 meta, lmeta, rmeta: Meta keys.
3051 \begin_layout Itemize
3052 num, caps: Numlock/Capslock (these are sticky!)
3055 \begin_layout Itemize
3059 \begin_layout Subsubsection
3063 \begin_layout Standard
3064 Following key names are known:
3067 \begin_layout Itemize
3068 backspace, tab, clear, return, pause, escape, space, exclaim, quotedbl,
3069 hash, dollar, ampersand, quote, leftparen, rightparen, asterisk, plus,
3070 comma, minus, period, slash, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, colon, semicolon,
3071 less, equals, greater, question, at, leftbracket, backslash, rightbracket,
3072 caret, underscore, backquote, a, b, c, d, e, f, g, h, i, j, k, l, m, n,
3073 o, p, q, r, s, t, u, v, w, x, y, z, delete, world_0, world_1, world_2,
3074 world_3, world_4, world_5, world_6, world_7, world_8, world_9, world_10,
3075 world_11, world_12, world_13, world_14, world_15, world_16, world_17, world_18,
3076 world_19, world_20, world_21, world_22, world_23, world_24, world_25, world_26,
3077 world_27, world_28, world_29, world_30, world_31, world_32, world_33, world_34,
3078 world_35, world_36, world_37, world_38, world_39, world_40, world_41, world_42,
3079 world_43, world_44, world_45, world_46, world_47, world_48, world_49, world_50,
3080 world_51, world_52, world_53, world_54, world_55, world_56, world_57, world_58,
3081 world_59, world_60, world_61, world_62, world_63, world_64, world_65, world_66,
3082 world_67, world_68, world_69, world_70, world_71, world_72, world_73, world_74,
3083 world_75, world_76, world_77, world_78, world_79, world_80, world_81, world_82,
3084 world_83, world_84, world_85, world_86, world_87, world_88, world_89, world_90,
3085 world_91, world_92, world_93, world_94, world_95, kp0, kp1, kp2, kp3, kp4,
3086 kp5, kp6, kp7, kp8, kp9, kp_period, kp_divide, kp_multiply, kp_minus, kp_plus,
3087 kp_enter, kp_equals, up, down, right, left, insert, home, end, pageup,
3088 pagedown, f1, f2, f3, f4, f5, f6, f7, f8, f9, f10, f11, f12, f13, f14,
3089 f15, numlock, capslock, scrollock, rshift, lshift, rctrl, lctrl, ralt,
3090 lalt, rmeta, lmeta, lsuper, rsuper, mode, compose, help, print, sysreq,
3091 break, menu, power, euro, undo
3094 \begin_layout Itemize
3095 Names of form 'key<n>' where <n> is 0-255 are interpretted as key having
3096 hardware-dependent scan code of <n> (useful to bind those keys that don't
3097 have symbolic names).
3100 \begin_layout Subsubsection
3101 Joystick pseudo-keys:
3104 \begin_layout Itemize
3105 joystick<num>button<button>: Joystick <num> (0-based) button <button> (0-based).
3108 \begin_layout Itemize
3109 joystick<num>hat<hat>n: Joystick <num> (0-based) hat <hat> (0-based) up.
3112 \begin_layout Itemize
3113 joystick<num>hat<hat>w: Joystick <num> (0-based) hat <hat> (0-based) left.
3116 \begin_layout Itemize
3117 joystick<num>hat<hat>s: Joystick <num> (0-based) hat <hat> (0-based) down.
3120 \begin_layout Itemize
3121 joystick<num>hat<hat>e: Joystick <num> (0-based) hat <hat> (0-based) right.
3124 \begin_layout Itemize
3125 joystick<num>axis<axis>-: Joystick <num> (0-based) axis <axis> negative
3126 position (axis modes axis and axis_inverse).
3129 \begin_layout Itemize
3130 joystick<num>axis<axis>+: Joystick <num> (0-based) axis <axis> positive
3131 position (axis modes axis and axis_inverse).
3134 \begin_layout Itemize
3135 joystick<num>axis<axis>: Joystick <num> (0-based) axis <axis> pressure (axis
3139 \begin_layout Subsubsection
3143 \begin_layout Itemize
3144 Escape: Enter/Exit Command mode, cancel modal dialogs.
3147 \begin_layout Itemize
3148 Return (also KPEnter): Execute command, ok modal dialog.
3151 \begin_layout Itemize
3152 Pgup/Up (also KP8/9 if no num lock; command mode): Previous command in command
3156 \begin_layout Itemize
3157 Pgdn/Down(also KP2/3 if no num lock; command mode): Next command in command
3161 \begin_layout Itemize
3162 Home (also KP7 if no num lock; command mode): Beginning of command.
3165 \begin_layout Itemize
3166 End (also KP1 if no num lock; command mode): End of command.
3169 \begin_layout Itemize
3170 Left (also KP4 if no num lock; command mode): Move cursor left.
3173 \begin_layout Itemize
3174 Right (also KP6 if no num lock; command mode): Move cursor right.
3177 \begin_layout Itemize
3179 if no num lock; command mode): Delete character to right of cursor.
3182 \begin_layout Itemize
3183 Insert (also KP0 if no num lock; command mode): Toggle between insert /
3187 \begin_layout Itemize
3188 Backspace (command mode): Delete character to left of cursor.
3191 \begin_layout Itemize
3192 LCTRL+LALT+ESCAPE: Ungraceful shutdown (leaves dump corrupted!).
3195 \begin_layout Subsection
3199 \begin_layout Subsubsection
3203 \begin_layout Standard
3204 Following modifier names are known:
3207 \begin_layout Itemize
3211 \begin_layout Itemize
3215 \begin_layout Itemize
3219 \begin_layout Itemize
3223 \begin_layout Itemize
3227 \begin_layout Subsubsection
3231 \begin_layout Standard
3232 Following key names are known:
3235 \begin_layout Itemize
3236 back, tab, return, escape, space, exclaim, quotedbl, hash, dollar, percent,
3237 ampersand, quote, leftparen, rightparen, asterisk, plus, comma, minus,
3238 period, slash, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, colon, semicolon, less, equals,
3239 greater, question, at, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p,
3240 q, r, s, t, u, v, w, x, y, z, leftbracket, backslash, rightbracket, caret,
3241 underscore, backquote, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p,
3242 q, r, s, t, u, v, w, x, y, z, leftcurly, pipe, rightcurly, tilde, delete,
3243 start, lbutton, rbutton, cancel, mbutton, clear, shift, alt, control, menu,
3244 pause, capital, end, home, lefT, up, right, down, select, print, execute,
3245 snapshot, insert, help, numpad0, numpad1, numpad2, numpad3, numpad4, numpad5,
3246 numpad6, numpad7, numpad8, numpad9, multiply, add, separator, subtract,
3247 decimal, divide, f1, f2, f3, f4, f5, f6, f7, f8, f9, f10, f11, f12, f13,
3248 f14, f15, f16, f17, f18, f19, f20, f21, f22, f23, f24, numlock, scroll,
3249 pageup, pagedown, numpad_space, numpad_tab, numpad_enter, numpad_f1, numpad_f2,
3250 numpad_f3, numpad_f4, numpad_home, numpad_left, numpad_up, numpad_right,
3251 numpad_down, numpad_pageup, numpad_pagedown, numpad_end, numpad_begin,
3252 numpad_insert, numpad_delete, numpad_equal, numpad_multiply, numpad_add,
3253 numpad_separator, numpad_subtract, numpad_decimal, numpad_divide, windows_left,
3254 windows_right, windows_menu, command, special1, special2, special3, special4,
3255 special5, special6, special7, special8, special9, special10, special11,
3256 special12, special13, special14, special15, special16, special17, special18,
3257 special19, special20
3260 \begin_layout Section
3264 \begin_layout Standard
3265 Movie file is .zip archive in itself, normal ZIP archive tools work on it
3266 (note: If you recompress it, do not use compression methods other than
3267 store and deflate and especially do not use encryption of any kind).
3270 \begin_layout Subsection
3271 Detecting clean start/SRAM/Savestate
3274 \begin_layout Itemize
3276 \begin_inset Quotes eld
3280 \begin_inset Quotes erd
3283 it is savestate, otherwise:
3286 \begin_layout Itemize
3287 If file has members with names starting
3288 \begin_inset Quotes eld
3292 \begin_inset Quotes erd
3295 it is movie starting from SRAM, otherwise:
3298 \begin_layout Itemize
3299 It is movie starting from clear state.
3302 \begin_layout Subsection
3306 \begin_layout Standard
3307 Type of game ROM and region (as one line).
3311 \begin_layout Standard
3312 \begin_inset Tabular
3313 <lyxtabular version="3" rows="8" columns="3">
3314 <features tabularvalignment="middle">
3315 <column alignment="center" valignment="top" width="0">
3316 <column alignment="center" valignment="top" width="0">
3317 <column alignment="center" valignment="top" width="0">
3319 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3322 \begin_layout Plain Layout
3328 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3331 \begin_layout Plain Layout
3337 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3340 \begin_layout Plain Layout
3348 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3351 \begin_layout Plain Layout
3357 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3360 \begin_layout Plain Layout
3366 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3369 \begin_layout Plain Layout
3377 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3380 \begin_layout Plain Layout
3386 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3389 \begin_layout Plain Layout
3395 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3398 \begin_layout Plain Layout
3406 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3409 \begin_layout Plain Layout
3415 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3418 \begin_layout Plain Layout
3424 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3427 \begin_layout Plain Layout
3435 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3438 \begin_layout Plain Layout
3444 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3447 \begin_layout Plain Layout
3453 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3456 \begin_layout Plain Layout
3464 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3467 \begin_layout Plain Layout
3473 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3476 \begin_layout Plain Layout
3482 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3485 \begin_layout Plain Layout
3493 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3496 \begin_layout Plain Layout
3502 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3505 \begin_layout Plain Layout
3511 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3514 \begin_layout Plain Layout
3522 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3525 \begin_layout Plain Layout
3531 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3534 \begin_layout Plain Layout
3540 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3543 \begin_layout Plain Layout
3557 \begin_layout Standard
3561 \begin_layout Standard
3562 \begin_inset Tabular
3563 <lyxtabular version="3" rows="3" columns="2">
3564 <features tabularvalignment="middle">
3565 <column alignment="center" valignment="top" width="0">
3566 <column alignment="center" valignment="top" width="0">
3568 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3571 \begin_layout Plain Layout
3577 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3580 \begin_layout Plain Layout
3588 <cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
3591 \begin_layout Plain Layout
3597 <cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
3600 \begin_layout Plain Layout
3608 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" usebox="none">
3611 \begin_layout Plain Layout
3617 <cell alignment="center" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
3620 \begin_layout Plain Layout
3634 \begin_layout Subsection
3638 \begin_layout Standard
3639 Contains type of port #1 (as one line).
3640 Valid values are 'none', 'gamepad', 'multitap' and 'mouse'.
3641 If not present, defaults to 'gamepad'.
3644 \begin_layout Subsection
3648 \begin_layout Standard
3649 Contains type of port #2 (as one line).
3650 Valid values are 'none', 'gamepad', 'multitap', 'mouse', 'superscope',
3651 'justifier' and 'justifiers'.
3652 If not present, defaults to 'none'.
3655 \begin_layout Subsection
3659 \begin_layout Standard
3660 Contains name of the game (as one line).
3663 \begin_layout Subsection
3667 \begin_layout Standard
3668 Contains authors, one per line.
3669 Part before '|' is the full name, part after is the nickname.
3672 \begin_layout Subsection
3676 \begin_layout Standard
3678 \begin_inset Quotes eld
3682 \begin_inset Quotes erd
3686 Used to reject other saves.
3689 \begin_layout Subsection
3690 Member: controlsversion
3693 \begin_layout Standard
3695 \begin_inset Quotes eld
3699 \begin_inset Quotes erd
3703 Used to identify what controls are there.
3706 \begin_layout Subsection
3708 \begin_inset Quotes eld
3712 \begin_inset Quotes erd
3718 \begin_layout Standard
3719 Contains bsnes core version number (as one line).
3722 \begin_layout Subsection
3726 \begin_layout Standard
3727 Contains project ID (as one line).
3728 Used to identify if two movies are part of the same project.
3731 \begin_layout Subsection
3732 Member: {rom,slota,slotb}{,xml}.sha256
3735 \begin_layout Standard
3736 Contains SHA-256 of said ROM or ROM mapping file (as one line).
3737 Absent if corresponding file is absent.
3740 \begin_layout Subsection
3741 Member: moviesram.<name>
3744 \begin_layout Standard
3745 Raw binary startup SRAM of kind <name>.
3746 Only present in savestates and movies starting from SRAM.
3749 \begin_layout Subsection
3753 \begin_layout Standard
3754 Contains frame number (as one line) of frame movie was saved on.
3755 Only present in savestates.
3758 \begin_layout Subsection
3762 \begin_layout Standard
3763 Current value of lag counter (as one line).
3764 Only present in savestates.
3767 \begin_layout Subsection
3768 Member: pollcounters
3771 \begin_layout Standard
3772 Contains poll counters (currently 100 of them), one per line.
3773 Each line is raw poll count if DRDY is set for it.
3774 Otherwise it is negative poll count minus one.
3775 Only present in savestates.
3778 \begin_layout Subsection
3782 \begin_layout Standard
3783 Raw binary dump of host memory.
3784 Only present in savestates.
3787 \begin_layout Subsection
3791 \begin_layout Standard
3792 The raw binary savestate itself.
3793 Savestate detection uses this file, only present in savestates.
3796 \begin_layout Subsection
3800 \begin_layout Standard
3801 Screenshot of current frame.
3802 Only present in savestates.
3803 First 2 bytes are big-endian width of image, rest are 24-bit RGB image
3805 Height of image is inferred from the width and size of data.
3808 \begin_layout Subsection
3812 \begin_layout Standard
3813 Raw binary SRAM of kind <name> at time of savestate.
3814 Only present in savestates.
3817 \begin_layout Subsection
3821 \begin_layout Standard
3822 The actual input track, one line per subframe (blank lines are skipped).
3825 \begin_layout Itemize
3826 If the first byte of each line is '.', ' ', <tab> or '|', then the line is
3827 part of same frame as previous, otherwise it starts a new frame.
3830 \begin_layout Itemize
3831 First subframe must start a new frame.
3834 \begin_layout Standard
3835 Length of movie in frames is number of lines in input file that start a
3839 \begin_layout Subsection
3843 \begin_layout Standard
3844 Contains textual base-10 rerecord count (as one line; emulator just writes
3845 this, it doesn't read it) + 1.
3848 \begin_layout Subsection
3852 \begin_layout Standard
3853 This member stores set of load IDs.
3854 There is one load ID per rerecord (plus one corresponding to start of project).
3857 \begin_layout Itemize
3858 This member constists of concatenation of records
3861 \begin_layout Itemize
3862 Each record is 2-36 bytes long and can represent 1-16,843,009 consequtive
3866 \begin_layout Itemize
3867 IDs are interpretted as 256-bit big-endian integers with warparound.
3870 \begin_layout Itemize
3871 Initial predicted ID is all zeroes.
3874 \begin_layout Standard
3875 Format of each record is:
3878 \begin_layout Itemize
3879 1 byte: Opcode byte.
3880 Bits 0-4 are prefix length (prefixlen), bits 5-6 are count length (countlen).
3884 \begin_layout Itemize
3885 32-prefixlen bytes of ID.
3888 \begin_layout Itemize
3889 countlen bytes of big-endian count (count).
3892 \begin_layout Standard
3893 Records are processed as follows:
3896 \begin_layout Itemize
3897 To form the first ID encoded by record, take the first prefixlen bytes predicted
3898 ID and append the read ID value to it.
3899 The result is the first ID encoded.
3902 \begin_layout Itemize
3903 If countlen is 0, record encodes 1 ID.
3906 \begin_layout Itemize
3907 If countlen is 1, record encodes 2+count IDs.
3910 \begin_layout Itemize
3911 If countlen is 2, record encodes 258+count IDs.
3914 \begin_layout Itemize
3915 If countlen is 3, record encodes 65794+count IDs.
3918 \begin_layout Itemize
3919 The new predicted ID is the next ID after last one encoded by the record.
3922 \begin_layout Standard
3923 The number of rerecords + 1 is equal to the sum of number of IDs encoded
3927 \begin_layout Subsection
3928 Member: starttime.second
3931 \begin_layout Standard
3932 Movie starting time, second part.
3933 Epoch is Unix epoch.
3934 Default is 1,000,000,000.
3937 \begin_layout Subsection
3938 Member: starttime.subsecond
3941 \begin_layout Standard
3942 Movie starting time, subsecond part.
3947 \begin_layout Subsection
3948 Member: savetime.second
3951 \begin_layout Standard
3952 Movie saving time, second part.
3953 Default is starttime.second.
3954 Only present in savestates.
3957 \begin_layout Subsection
3958 Member: savetime.subsecond
3961 \begin_layout Standard
3962 Movie saving time, subsecond part.
3963 Default is starttime.subsecond.
3964 Only present in savestates.
3967 \begin_layout Section
3968 Quick'n'dirty encode guide
3971 \begin_layout Enumerate
3972 Start the emulator and load the movie file.
3975 \begin_layout Enumerate
3976 Set large AVI option 'set-setting avi-large on'
3979 \begin_layout Enumerate
3980 Enable dumping 'dump-avi tmpdump'
3983 \begin_layout Enumerate
3984 Unpause and let it run until you want to end dumping.
3987 \begin_layout Enumerate
3988 Close the emulator (closing the window is the easiest way).
3992 \begin_layout Enumerate
3993 For each tmpdump*.avi file created, on command prompt, do 'x264 --crf 10
3994 -o tmpdump_<numbers>.mkv tmpdump_<numbers>.avi'.
3997 \begin_layout Enumerate
3998 Do 'sox tmpdump.sox tmpdump.ogg rate -v 32000'
4001 \begin_layout Enumerate
4002 Do 'mkvmerge -o tmpdump_video.mkv tmpdump_0000000.mkv + tmpdump_0000001.mkv
4003 + tmpdump_0000002.mkv' (list every tmpdump_<numbers>.mkv, with + in between).
4006 \begin_layout Enumerate
4007 Do 'mkvmerge -o final.mkv tmpdump_video.mkv tmpdump.ogg'.
4008 Now final.mkv contains quick'n'dirty encode.
4011 \begin_layout Section
4012 Axis configurations for some gamepad types:
4015 \begin_layout Subsection
4019 \begin_layout Standard
4020 Axes 2 and 5 (joystick<n>axis2 and joystick<n>axis5) should be set to pressure-+.
4023 \begin_layout LyX-Code
4024 set-axis joystick0axis2 pressure-+
4027 \begin_layout LyX-Code
4028 set-axis joystick0axis5 pressure-+
4031 \begin_layout Itemize
4032 This is needed for SDL only.
4033 EVDEV sets those types correctly.
4036 \begin_layout Subsection
4038 \begin_inset Quotes eld
4042 \begin_inset Quotes erd
4048 \begin_layout Standard
4049 Axes 8-19 should be disabled.
4052 \begin_layout LyX-Code
4053 set-axis joystick0axis8 disabled
4056 \begin_layout LyX-Code
4057 set-axis joystick0axis9 disabled
4060 \begin_layout LyX-Code
4061 set-axis joystick0axis10 disabled
4064 \begin_layout LyX-Code
4065 set-axis joystick0axis11 disabled
4068 \begin_layout LyX-Code
4069 set-axis joystick0axis12 disabled
4072 \begin_layout LyX-Code
4073 set-axis joystick0axis13 disabled
4076 \begin_layout LyX-Code
4077 set-axis joystick0axis14 disabled
4080 \begin_layout LyX-Code
4081 set-axis joystick0axis15 disabled
4084 \begin_layout LyX-Code
4085 set-axis joystick0axis16 disabled
4088 \begin_layout LyX-Code
4089 set-axis joystick0axis17 disabled
4092 \begin_layout LyX-Code
4093 set-axis joystick0axis18 disabled
4096 \begin_layout LyX-Code
4097 set-axis joystick0axis19 disabled
4100 \begin_layout Section
4104 \begin_layout Subsection
4105 Problems from BSNES core:
4108 \begin_layout Itemize
4109 The whole pending save stuff.
4112 \begin_layout Itemize
4113 Lack of layer hiding.
4116 \begin_layout Itemize
4117 It is slow (especially accuracy).
4120 \begin_layout Itemize
4121 Firmwares can't be loaded from ZIP archives.
4124 \begin_layout Subsection
4128 \begin_layout Itemize
4129 Modifiers don't work with pseudo-keys (SDL, EVDEV).
4132 \begin_layout Itemize
4133 Audio for last dumped frame is not itself dumped.
4136 \begin_layout Itemize
4137 Audio in UI is pretty bad in quality if game doesn't run at full speed.
4140 \begin_layout Itemize
4141 AVI compression levels 10-18 are not compatible with AVISynth AVISource.
4144 \begin_layout Itemize
4145 No menus, command based interface (SDL).
4148 \begin_layout Itemize
4149 Long commands don't scroll.
4152 \begin_layout Itemize
4153 The SDL screen drawing is slow.
4156 \begin_layout Itemize
4157 Wxwidgets UI is still pretty buggy.
4160 \begin_layout Section
4164 \begin_layout Subsection
4168 \begin_layout Itemize
4172 \begin_layout Itemize
4173 Fix dumper video corruption with levels 10-18.
4176 \begin_layout Subsection
4180 \begin_layout Itemize
4184 \begin_layout Itemize
4185 Lots of code cleanups
4188 \begin_layout Itemize
4189 Lua interface to settings
4192 \begin_layout Itemize
4193 Allow specifying AVI borders without Lua
4196 \begin_layout Itemize
4197 Fix scaling if vscale > 1 and originx > 0 (left border exists)
4200 \begin_layout Itemize
4201 on_snoop lua callback
4204 \begin_layout Itemize
4205 Faster movie loading and saving.
4208 \begin_layout Subsection
4212 \begin_layout Itemize
4216 \begin_layout Subsection
4220 \begin_layout Itemize
4224 \begin_layout Itemize
4225 Save jukebox functionality.
4228 \begin_layout Subsection
4232 \begin_layout Itemize
4233 Try to fix some nasty failing movie load edge cases
4236 \begin_layout Itemize
4237 Allow specifying scripts to run on command line.
4240 \begin_layout Subsection
4244 \begin_layout Itemize
4245 Major source code reorganization.
4248 \begin_layout Itemize
4249 Backup savestates before overwriting.
4252 \begin_layout Itemize
4253 Don't crash if loading initial state fails.
4256 \begin_layout Subsection
4260 \begin_layout Itemize
4264 \begin_layout Itemize
4265 Fix author name parsing
4268 \begin_layout Itemize
4269 Fix rerecord counting
4272 \begin_layout Itemize
4273 (SDL) Print messages to console if SDL is uninitialized
4276 \begin_layout Itemize
4277 Add movieinfo program
4280 \begin_layout Itemize
4281 Fix loading movies starting from SRAM.
4284 \begin_layout Subsection
4288 \begin_layout Itemize
4289 Add support for unattended dumping
4292 \begin_layout Itemize
4293 Fix compiling for Win32
4296 \begin_layout Itemize
4297 Don't lock up if sound can't be initialized
4300 \begin_layout Itemize
4301 Strip trailing CR from commands
4304 \begin_layout Itemize
4305 Don't try to do dubious things in global ctors (fix crash on startup)
4308 \begin_layout Subsection
4312 \begin_layout Itemize
4313 Small documentation tweaking
4316 \begin_layout Itemize
4320 \begin_layout Itemize
4321 Fix major bug in modifier matching
4324 \begin_layout Subsection
4328 \begin_layout Itemize
4329 Lots of documentation fixes
4332 \begin_layout Itemize
4333 Use dedicated callbacks for event backcomm., not commands.
4336 \begin_layout Itemize
4337 Ensure that the watchdog is not hit when executing delayed reset.
4340 \begin_layout Itemize
4341 Remove errant tab from joystick message.
4344 \begin_layout Subsection
4348 \begin_layout Itemize
4349 Make autofire operate in absolute time, not linear time
4352 \begin_layout Itemize
4353 Reinitialize controls when resuming from loadstate
4356 \begin_layout Itemize
4357 Some more code cleanups
4360 \begin_layout Itemize
4361 If Lua allocator fails, call OOM_panic()
4364 \begin_layout Itemize
4365 Byte/word/dword/qword sized host memory write/read functions.
4368 \begin_layout Itemize
4369 Dump at correct framerate if dumping interlaced NTSC (height=448).
4372 \begin_layout Subsection
4376 \begin_layout Itemize
4377 Actually include the complete source code
4380 \begin_layout Itemize
4384 \begin_layout Subsection
4388 \begin_layout Itemize
4389 Document {save,start}time.{,sub}second.
4392 \begin_layout Itemize
4393 Intercept time() from bsnes core.
4396 \begin_layout Subsection
4400 \begin_layout Itemize
4401 Allow disabling time() interception (allow build on Mac OS X)
4404 \begin_layout Itemize
4405 Use SDLMain on Mac OS X (make SDL not crash)
4408 \begin_layout Itemize
4409 Disable delayed resets (just plain too buggy for now).
4412 \begin_layout Itemize
4416 \begin_layout Itemize
4417 Use 16-bit for graphics/video instead of 32-bit.
4420 \begin_layout Itemize
4421 gui.rectangle/gui.pixel
4424 \begin_layout Itemize
4428 \begin_layout Itemize
4429 New CSCD writer implementation.
4432 \begin_layout Subsection
4436 \begin_layout Itemize
4437 Fix interaction of * and +.
4440 \begin_layout Itemize
4444 \begin_layout Itemize
4445 Use gettimeofday()/usleep(), these seem portable enough.
4448 \begin_layout Itemize
4449 Move joystick axis manipulation to keymapper code.
4452 \begin_layout Itemize
4453 Changes to how read-only works.
4456 \begin_layout Itemize
4457 Refactor controller input code.
4460 \begin_layout Subsection
4464 \begin_layout Itemize
4465 Fix mouseclick scale compensation.
4468 \begin_layout Itemize
4469 Draw area boundaries correctly in SDL code.
4472 \begin_layout Itemize
4476 \begin_layout Itemize
4477 Fix CSCD output (buffer overrun and race condition).
4480 \begin_layout Subsection
4484 \begin_layout Itemize
4485 JMD dumping support.
4488 \begin_layout Itemize
4489 Allow unattended dumping to JMD.
4492 \begin_layout Itemize
4496 \begin_layout Itemize
4497 Switch back to 32-bit colors.
4500 \begin_layout Itemize
4501 Add Lua function gui.color.
4504 \begin_layout Itemize
4505 Use some new C++11 features in GCC 4.6.
4508 \begin_layout Itemize
4509 Be prepared for core frequency changes.
4512 \begin_layout Itemize
4513 Pass colors in one chunk from Lua.
4516 \begin_layout Subsection
4520 \begin_layout Itemize
4521 New lua functions gui.line(), gui.status() and gui.circle(), memory.vma_count(),
4522 memory.read_vma() and memory.find_vma().
4525 \begin_layout Itemize
4526 Numerious documentation fixups
4529 \begin_layout Itemize
4530 RTC time format changed
4533 \begin_layout Itemize
4534 Reformat flags display
4537 \begin_layout Itemize
4538 Allow lua package name to be overridden
4541 \begin_layout Itemize
4542 SDUMP (high-quality dumping).
4545 \begin_layout Itemize
4546 Split platform support to plugins.
4549 \begin_layout Itemize
4550 Make all sound plugins support basic sound commands
4553 \begin_layout Itemize
4554 Support portaudio for sound.
4557 \begin_layout Itemize
4558 Allow disable Lua/SDL searching.
4561 \begin_layout Itemize
4562 Upconvert colors when copying lcscreen to screen.
4565 \begin_layout Itemize
4566 Reorganize source tree.
4569 \begin_layout Itemize
4570 Evdev joystick support.
4573 \begin_layout Itemize
4574 Refactor more code into generic window code.
4577 \begin_layout Subsection
4581 \begin_layout Itemize
4582 Refactor message handling.
4585 \begin_layout Itemize
4589 \begin_layout Itemize
4593 \begin_layout Itemize
4594 Finish pending saves before load/quit.
4597 \begin_layout Itemize
4598 Wxwidgets graphics plugin.
4601 \begin_layout Subsection
4605 \begin_layout Itemize
4606 Get rid of win32-crap.[ch]pp.
4609 \begin_layout Itemize
4610 Move files around a lot.
4613 \begin_layout Itemize
4614 Get rid of need for host C++ compiler.
4617 \begin_layout Itemize
4621 \begin_layout Itemize
4622 Refactor inter-component communication.
4625 \begin_layout Itemize
4629 \begin_layout Itemize
4630 Fix crash on multiline aliases.
4633 \begin_layout Itemize
4634 Load/Save settings in wxwidgets gui.
4637 \begin_layout Subsection
4641 \begin_layout Itemize
4642 Patch problems in bsnes core
4645 \begin_layout Itemize
4646 SNES is little-endian, not big-endian!
4649 \begin_layout Itemize
4650 Fix memory corruption in lcscreen::load()
4653 \begin_layout Subsection
4657 \begin_layout Itemize
4658 Fix interpretting repeat counts in rrdata loading.
4661 \begin_layout Itemize
4662 New lua callback: on_frame()
4665 \begin_layout Itemize
4666 Remove calls to runtosave() that aren't supposed to be there
4669 \begin_layout Itemize
4670 Lua function: movie.read_rtc()
4673 \begin_layout Itemize
4674 Ignore src/fonts/font.cpp
4677 \begin_layout Itemize
4678 Fix more bsnes core problems
4681 \begin_layout Itemize
4682 Control bsnes random seeding
4685 \begin_layout Itemize
4689 \begin_layout Itemize
4690 Some bsnes core debugging features (state dump and state hash)
4693 \begin_layout Itemize
4694 Fix titlebar version number (no, the last version wasn't 'lsnes-0-beta21',
4695 it was 'lsnes rr0-beta21').
4698 \begin_layout Subsection
4702 \begin_layout Itemize
4703 Fix memory corruption due to macro/field mixup
4706 \begin_layout Itemize
4707 search-memory update
4710 \begin_layout Itemize
4711 Allow direct-mapped framebuffer
4714 \begin_layout Itemize
4715 SDL: Use SDL_ANYFORMAT if possible
4718 \begin_layout Itemize
4719 SDMP2SOX: 2s delay modes.
4722 \begin_layout Itemize
4726 \begin_layout Itemize
4727 Use sed -E, not sed -r.
4728 Fixes building on Mac OS X.
4731 \begin_layout Itemize
4732 Wxwidgets: Save jukebox on exit
4735 \begin_layout Itemize
4736 Fix RTC if using load-movie on savestate.
4739 \begin_layout Itemize
4740 Fix crash related to full console mode.
4743 \begin_layout Subsection
4747 \begin_layout Itemize
4748 Wxwidgets: Allow bringing application to foreground on Mac OS X.
4751 \begin_layout Itemize
4752 Wxwidgets: Allow compiling on Mac OS X.
4755 \begin_layout Itemize
4756 Use movie compare instead of movie hashing (faster save/load).
4759 \begin_layout Itemize
4763 \begin_layout Subsection
4767 \begin_layout Itemize
4768 sdmp2sox: Pad soundtrack if using -l or -L.
4771 \begin_layout Itemize
4772 sdmp2sox: Fix NTSC overscan.
4775 \begin_layout Itemize
4776 sdmp2sox: Add AR correction mode.
4779 \begin_layout Itemize
4780 call lua_close() when exiting.
4783 \begin_layout Itemize
4784 Fix zip_writer bug causing warnings from info-zip and error from advzip.
4787 \begin_layout Subsection
4791 \begin_layout Itemize
4792 Fix IPS patching code (use bsnes core IPS patcher).
4795 \begin_layout Itemize
4796 Implement BPS patching (using bsnes core IPS patcher).
4799 \begin_layout Itemize
4800 Add feature to load headered ROMs.
4803 \begin_layout Subsection
4807 \begin_layout Itemize
4808 Show command names when showing keybindings
4811 \begin_layout Subsection
4815 \begin_layout Itemize
4816 Fix pause-on-end to be actually controllable
4819 \begin_layout Itemize
4820 SDL: Poll all events in queue, not just first one (fixes slowness in command
4824 \begin_layout Itemize
4825 Wxwidgets: Fix ROM loading.
4828 \begin_layout Subsection
4832 \begin_layout Itemize
4833 Lua: Add gui.textH, gui.textV, gui.textHV
4836 \begin_layout Itemize
4837 Fix text colors on SDL on Mac OS X
4840 \begin_layout Itemize
4841 Mode 'F' for finished in readonly mode.
4844 \begin_layout Itemize
4848 \begin_layout Itemize
4849 Reliably pause after skip poll
4852 \begin_layout Itemize
4853 Split UI and core into their own threads
4856 \begin_layout Subsection
4860 \begin_layout Itemize
4861 Remove leftover dummy SRAM slot
4864 \begin_layout Itemize
4865 Fix controller numbers.
4868 \begin_layout Subsection
4872 \begin_layout Itemize
4873 Fix lsnes-dumpavi after interface change.
4876 \begin_layout Itemize
4877 Also give BSNES patches for v085.
4880 \begin_layout Itemize
4881 Pack movie data in memory.
4884 \begin_layout Subsection
4888 \begin_layout Itemize
4889 Fix framecount/length given when loading movies.
4892 \begin_layout Itemize
4893 Controller command memory leak fixes.
4896 \begin_layout Itemize
4897 Don't leak palette if freeing screen object.
4900 \begin_layout Subsection
4904 \begin_layout Itemize
4908 \begin_layout Itemize
4909 Wxwidgets: Allow controlling dumper from the menu.
4912 \begin_layout Subsection
4916 \begin_layout Itemize
4917 Rewrite parts of manual
4920 \begin_layout Itemize
4921 Lua: Make it work with Lua 5.2.
4924 \begin_layout Subsection
4928 \begin_layout Itemize
4929 Win32: Fix compile errors.
4932 \begin_layout Subsection
4936 \begin_layout Itemize
4937 Refactor controller input code.
4940 \begin_layout Itemize
4941 Fix crash when using command line on SDL / Mac OS X.
4944 \begin_layout Subsection
4948 \begin_layout Itemize
4949 Delete core/coroutine (obsolete)
4952 \begin_layout Itemize
4953 Lag input display by one frame.
4956 \begin_layout Itemize
4957 Rewind movie to beginning function.
4960 \begin_layout Itemize
4961 Fix wrong frame number reported to Lua when repainting after loadstate
4964 \begin_layout Itemize
4965 Support UI editing of jukebox
4968 \begin_layout Itemize
4969 Wxwidgets: Save settings on exit.
4972 \begin_layout Itemize
4973 Support ${project} for filenames
4976 \begin_layout Itemize
4977 SDL: Fix command history
4980 \begin_layout Subsection
4984 \begin_layout Itemize
4985 Fix some order-of-global-ctor bugs.
4988 \begin_layout Subsection
4992 \begin_layout Itemize
4993 Fix crashes when quitting on Win32.