├── jni ├── Application.mk └── Android.mk ├── link.T ├── libretro ├── link.T ├── db │ └── database.h └── dsk │ └── loader.h ├── libretro-common ├── audio │ └── dsp_filters │ │ ├── configure │ │ ├── link.T │ │ ├── Tremolo.dsp │ │ ├── Vibrato.dsp │ │ ├── HighShelfDampen.dsp │ │ ├── Crystalizer.dsp │ │ ├── Reverb.dsp │ │ ├── WahWah.dsp │ │ ├── BassBoost.dsp │ │ ├── Phaser.dsp │ │ ├── EchoReverb.dsp │ │ ├── Mono.dsp │ │ ├── Chorus.dsp │ │ ├── IIR.dsp │ │ ├── Panning.dsp │ │ ├── ChipTuneEnhance.dsp │ │ ├── Echo.dsp │ │ ├── EQ.dsp │ │ ├── LowPassCPS.dsp │ │ └── fft │ │ └── fft.h ├── crt │ ├── include │ │ └── string.h │ └── string.c ├── include │ ├── libchdr │ │ ├── coretypes.h │ │ ├── minmax.h │ │ ├── bitstream.h │ │ ├── libchdr_zlib.h │ │ └── lzma.h │ ├── compat │ │ ├── fnmatch.h │ │ ├── fopen_utf8.h │ │ ├── ifaddrs.h │ │ ├── strcasestr.h │ │ └── strl.h │ ├── utils │ │ └── md5.h │ ├── gfx │ │ ├── scaler │ │ │ ├── filter.h │ │ │ └── scaler_int.h │ │ └── math │ │ │ └── vector_4.h │ ├── retro_assert.h │ ├── memalign.h │ ├── streams │ │ └── stdin_stream.h │ ├── encodings │ │ ├── crc32.h │ │ └── base64.h │ ├── rthreads │ │ └── async_job.h │ ├── retro_inline.h │ ├── boolean.h │ ├── retro_common.h │ ├── time │ │ └── rtime.h │ ├── audio │ │ ├── dsp_filter.h │ │ └── conversion │ │ │ ├── float_to_s16.h │ │ │ └── s16_to_float.h │ ├── math │ │ └── fxp.h │ └── memmap.h ├── compat │ ├── compat_vscprintf.c │ └── compat_strcasestr.c └── rthreads │ └── xenon_sdl_threads.c ├── contrib ├── font │ ├── font.png │ └── convert.py ├── ui_keyboard.png ├── ui_keyboard.xcf ├── ui_keyboard_en.png ├── ui_keyboard_es.png ├── ui_keyboard_fr.png └── remaps │ ├── Sgrizam (1986).rmp │ ├── Deflektor (1987).rmp │ ├── Babas Palace (2017).rmp │ ├── Island of Dr Destructo (1987).rmp │ ├── Octoplex (1989).rmp │ ├── Smash TV (1991).rmp │ ├── Xanadu (2020).rmp │ ├── Dark Fusion (1988).rmp │ ├── Ghouls n Ghosts (1989).rmp │ ├── Guerra de Gamber (2014) copy.rmp │ ├── Arcade Flight Simulator (1986).rmp │ ├── Galactic Plague (1984).rmp │ ├── Ghost n Goblins (1986).rmp │ ├── Mega Phoenix (1991).rmp │ ├── Trantor The Last Stormtrooper (1987).rmp │ ├── Pro Tennis (1985).rmp │ ├── Red Heat (1989).rmp │ ├── Red Sunset (2021).rmp │ ├── Shinobu (2019).rmp │ ├── Space Hawks - Aguilas Del Espacio (1984).rmp │ ├── Camelot Warriors (1986).rmp │ ├── Corsarios (1988).rmp │ ├── Freddy Hardest in South Manhattan (1989).rmp │ ├── Roland in Time (1985).rmp │ ├── Arquimedes XXI (2011).rmp │ ├── Bruce Lee (1984).rmp │ ├── Dragon Ninja (1988).rmp │ ├── Archon (1988).rmp │ ├── Emilio Butragueno Futbol (1988).rmp │ ├── Gabrielle (1987).rmp │ ├── Mundial de Futbol (1990).rmp │ ├── Xenon (1988).rmp │ ├── Space Smugglers (1989).rmp │ ├── 180 (1986).rmp │ ├── Gryzor (1987).rmp │ ├── Solomons Key (1986).rmp │ ├── Super Skweek (1990).rmp │ ├── Worm Slickers (1991).rmp │ ├── Defend or Die (1985).rmp │ ├── Angel Nieto Pole 500.rmp │ ├── 1942 (1986).rmp │ ├── Championship Sprint (1988).rmp │ ├── Heartland (1986).rmp │ ├── Addams Family (1991).rmp │ ├── Oh Mummy (1984).rmp │ ├── Cybernoid I-II.rmp │ ├── Samurai Warrior - The Battles of Usagi Yojimbo (1988).rmp │ ├── Techno Cop (1988).rmp │ ├── Combat School (1987).rmp │ ├── Helter Skelter (1990).rmp │ ├── J.T 37 (1990).rmp │ ├── Ramparts (1987).rmp │ ├── After Burner (1988).rmp │ ├── Arkanoid (1987).rmp │ ├── Auf Wiedersehen Monty (1987).rmp │ ├── Shinobi (1989).rmp │ ├── Vuelta al Mundo en 80 Dias (2022).rmp │ ├── Beyond the Ice Palace (1988).rmp │ ├── Rex (1989).rmp │ ├── Winter Games (1986).rmp │ ├── Italia 90 (1990).rmp │ ├── Manic Miner (1984).rmp │ ├── Turbo Girl (1988).rmp │ ├── WWF Wrestlemania (1991).rmp │ ├── Aventura Original (1989).rmp │ ├── Archon II (1989).rmp │ ├── Enchanter (1984).rmp │ ├── Infidel (1986).rmp │ ├── Suspended (1983).rmp │ ├── Xyphoes Fantasy (1991).rmp │ ├── Cutthroats (1984).rmp │ ├── Gnome Ranger (1987).rmp │ ├── Jungle Book (1989).rmp │ ├── Lancelot (1988).rmp │ ├── Planetfall (1983).rmp │ ├── Spellbreaker (1985).rmp │ ├── Wishbringer (1985).rmp │ ├── Witness, The (1984).rmp │ ├── Batman (1986).rmp │ ├── Colossus Mahjong (1987).rmp │ ├── Ivan Ironman Super Off Road (1990).rmp │ ├── Secte Noire, La (1990).rmp │ ├── Three Weeks in Paradise (1985).rmp │ ├── Hair Boy (2016).rmp │ ├── Murder on the Atlantic (1985).rmp │ ├── Sorcerer (1984)(Infocom)[CPM].rmp │ ├── Leather Goddesses of Phobos (1986).rmp │ ├── Mikie (1986).rmp │ ├── Zork II - The Wizard of Frobozz (1986).rmp │ ├── Zork III - The Dungeon Master (1986).rmp │ ├── Barbarian (Palace Software) (1987).rmp │ ├── Hustler (1985).rmp │ ├── Sol Negro (1989).rmp │ ├── Zork I - The Great Underground Empire (1986).rmp │ ├── Hitchhiker's Guide to the Galaxy, The (1984).rmp │ ├── Mutan Zone (1989).rmp │ ├── Sport (1989).rmp │ ├── Shadow Dancer (1991).rmp │ ├── Budokan - The Martial Spirit (1990).rmp │ ├── Cobra - Loriciels.rmp │ ├── Nemesis (1987).rmp │ ├── West Bank (1985).rmp │ ├── Sabre Wulf (1985).rmp │ ├── Dynamite Dan (1985).rmp │ ├── Exolon (1987).rmp │ ├── Moon Cresta (1986).rmp │ ├── Bomb Jack (1986).rmp │ ├── Rainbow Islands (1989).rmp │ ├── Shadow Maze - Celebration (2023).rmp │ ├── BMX Simulator (1987).rmp │ ├── Trivial Pursuit (1988).rmp │ ├── Warlock (1987).rmp │ ├── Classic Invaders (1986).rmp │ ├── Boloncio (1986).rmp │ ├── Chessmaster 2000 (1990).rmp │ ├── Gauntlet (1986).rmp │ ├── Silkworm (1988).rmp │ ├── Wonderboy (1987).rmp │ ├── Beach Buggy (1987).rmp │ ├── Chuckie Egg (1985).rmp │ ├── Chuckie Egg II (1985).rmp │ ├── Roland On The Ropes - Fred (1984).rmp │ ├── Vera Cruz Affair, The (1986).rmp │ ├── WEC Le Mans (1988).rmp │ ├── Blood Valley (1987).rmp │ ├── Nanako Descends to Hell (2009).rmp │ ├── Powerplay - cr (1986).rmp │ ├── Goonies (1986).rmp │ ├── Light Corridor (1990).rmp │ ├── Ice-Breaker (1990).rmp │ ├── Rygar (1987).rmp │ ├── Vendetta (1990).rmp │ ├── Skate Crazy (1988).rmp │ ├── Deathsville (1986).rmp │ ├── Desperado (1987).rmp │ ├── Zap t Balls (1992).rmp │ ├── Abu Simbel Profanation (1986).rmp │ ├── Comando Tracer (1988).rmp │ ├── Motos (1987).rmp │ ├── Aspar Grand Prix Master (1988).rmp │ ├── Donkey Kong (1986).rmp │ ├── Match Day II (1987).rmp │ ├── Stormlord II (1990).rmp │ ├── Boulder Dash (1985).rmp │ ├── Miss Input 1 (2019).rmp │ ├── Miss Input 2 (2020).rmp │ ├── Operation Wolf (1988).rmp │ ├── Phantomas Saga Infinity (2006).rmp │ ├── Renegade (1987).rmp │ ├── Clever and Smart (1987).rmp │ ├── Tres Luces de Glaurung (1986).rmp │ ├── Goody (1987).rmp │ ├── Jarlac (2018).rmp │ ├── Mad Mix Game (1988).rmp │ ├── Classic Axiens (1988).rmp │ ├── Freddy Hardest (1987).rmp │ ├── Klax (1990).rmp │ ├── Prince of Persia (1990).rmp │ ├── Asterix and the Magic Carpet (1988).rmp │ ├── Chase H.Q (1989).rmp │ ├── Commando - Space Invasion (1985).rmp │ ├── Garfield (1988).rmp │ ├── Rescate Atlantida (1989).rmp │ ├── Continental Circus (1989).rmp │ ├── Head over Hells (1986).rmp │ ├── Sir Fred (1986).rmp │ ├── Amsoft Loader (1985).rmp │ ├── Mortadelo y Filemon II (1989).rmp │ ├── Space Moves (2020).rmp │ ├── AMC - Astro Marine Corps.rmp │ ├── Legend of Steel (2018).rmp │ ├── Phantis (1989).rmp │ ├── Roland In The Caves - Pulga (1984).rmp │ ├── Tuareg (1988).rmp │ ├── 3D Grand Prix (1985).rmp │ ├── Way Of The Exploding Fist (1985).rmp │ ├── After The War (1989).rmp │ ├── Ghostbusters (1985).rmp │ ├── Tapper (1986).rmp │ ├── Beach Volley (1989).rmp │ ├── Robocop (1989).rmp │ ├── Turbo Esprit (1986).rmp │ ├── Molecule Man (1986).rmp │ ├── Jack The Nipper II (1987).rmp │ ├── Super Stuntman (1988).rmp │ ├── Victory Road (1988).rmp │ ├── Fernando Martin - Basket Master (1987).rmp │ ├── Myth (1989).rmp │ ├── Spitfire 40 (1985).rmp │ ├── Yie Ar Kung-Fu.rmp │ ├── Capitan Trueno (1989).rmp │ ├── Galactic Tomb (2018).rmp │ ├── Savage (1988).rmp │ ├── Espada Sagrada (1990).rmp │ ├── Gunfright (1985).rmp │ ├── Powerplay - org (1986).rmp │ ├── Thanatos (1986).rmp │ ├── Tyrann - es (1985).rmp │ ├── Game Over (1987).rmp │ ├── Batty (1987).rmp │ ├── Army Moves (1986).rmp │ ├── Navy Moves (1988).rmp │ ├── Satan (1989).rmp │ ├── Alien 8 (1985).rmp │ ├── Carlos Sainz (1990).rmp │ ├── Knight Lore (1984).rmp │ ├── Jack The Nipper I (1986).rmp │ ├── Tyrann (1985).rmp │ ├── Harrier Attack (1984).rmp │ ├── Teenage Mutant Hero Turtles (1990).rmp │ ├── Chibi Akuma's Episode 1 Invasion (v1.666).rmp │ ├── Target Renegade (1988).rmp │ ├── Hero Quest (1991).rmp │ ├── 1943 (1988).rmp │ ├── Cyrus II (1985).rmp │ ├── Bubble Bobble 1-2.rmp │ ├── Ikari Warriors (1986).rmp │ ├── Dark Side (1988).rmp │ ├── Dead By Dawn (2014).rmp │ ├── Golden Axe (1986).rmp │ ├── Castle Master I-II.rmp │ ├── Driller (1988).rmp │ ├── Total Eclipse I-II (1988).rmp │ ├── Abadia Del Crimen (1988).rmp │ └── Abbey Of Crime (2017).rmp ├── external └── cmocka │ ├── README │ └── cmocka-update.sh ├── .gitignore ├── utils └── zlib │ ├── inffast.h │ ├── gzclose.c │ ├── uncompr.c │ └── crc32.c ├── .travis.yml ├── cap32 ├── cart.h ├── tape.h ├── slots.h ├── retro_inline.h └── errors.h └── Makefile.common /jni/Application.mk: -------------------------------------------------------------------------------- 1 | APP_ABI := all 2 | APP_CFLAGS += -O0 3 | -------------------------------------------------------------------------------- /link.T: -------------------------------------------------------------------------------- 1 | { 2 | global: retro_*; 3 | local: *; 4 | }; 5 | 6 | -------------------------------------------------------------------------------- /libretro/link.T: -------------------------------------------------------------------------------- 1 | { 2 | global: retro_*; 3 | local: *; 4 | }; 5 | 6 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/configure: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | PACKAGE_NAME=retroarch-filters-audio -------------------------------------------------------------------------------- /contrib/font/font.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/font/font.png -------------------------------------------------------------------------------- /contrib/ui_keyboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/ui_keyboard.png -------------------------------------------------------------------------------- /contrib/ui_keyboard.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/ui_keyboard.xcf -------------------------------------------------------------------------------- /contrib/ui_keyboard_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/ui_keyboard_en.png -------------------------------------------------------------------------------- /contrib/ui_keyboard_es.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/ui_keyboard_es.png -------------------------------------------------------------------------------- /contrib/ui_keyboard_fr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/libretro/libretro-cap32/HEAD/contrib/ui_keyboard_fr.png -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/link.T: -------------------------------------------------------------------------------- 1 | { 2 | global: dspfilter_get_implementation; 3 | local: *; 4 | }; 5 | -------------------------------------------------------------------------------- /contrib/remaps/Sgrizam (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | entry_hash_1 = 0x8c8a37bd # (S) (1986) 4 | -------------------------------------------------------------------------------- /contrib/remaps/Deflektor (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "55" 2 | 3 | entry_hash_1 = 0x61a1bea2 # (UK) (1985) [tape] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Babas Palace (2017).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | 3 | entry_hash_1 = 0x9cb1e0a7 # (UK) (2017) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Island of Dr Destructo (1987).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_start = "49" 3 | 4 | entry_hash_1 = 0xaf33badf # (UK) (1987) -------------------------------------------------------------------------------- /contrib/remaps/Octoplex (1989).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0x2519a761 # (UK) (1989) 3 | 4 | entry_command = "RUN[quote]OCTOPLEX" 5 | -------------------------------------------------------------------------------- /contrib/remaps/Smash TV (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | entry_hash_1 = 0xc18a84f9 # (UK) (1991) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Xanadu (2020).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0xde97e3ab # (S) (2020) (Hack) 3 | 4 | entry_command = "RUN[quote]XANADU" 5 | -------------------------------------------------------------------------------- /contrib/remaps/Dark Fusion (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "115" 2 | 3 | entry_hash_1 = 0x1d1e61db # (UK) (1988) (CPM) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Ghouls n Ghosts (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "51" 2 | 3 | entry_hash_1 = 0xc8d7f575 # (UK) (1989) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Guerra de Gamber (2014) copy.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | 3 | entry_hash_1 = 0x3cba528d # (2014) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Arcade Flight Simulator (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "32" 2 | 3 | entry_hash_1 = 0x790a9ac2 # (UK) (1989) [tape] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Galactic Plague (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "53" 2 | 3 | entry_hash_1 = 0x674fbced # (UK) (1984) [Tape Conversion] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Ghost n Goblins (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "115" 2 | 3 | entry_hash_1 = 0x8ceb4fa3 # (UK) (1986) (v2) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Mega Phoenix (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | 3 | entry_hash_1 = 0xbd48490a # (UK) (1991) (CPM) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Trantor The Last Stormtrooper (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | entry_hash_1 = 0x3365f862 # (UK) (1987) [Original] -------------------------------------------------------------------------------- /contrib/remaps/Pro Tennis (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | 3 | entry_hash_1 = 0x25af0923 # (UK) (1986) (Spain retail version) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Red Heat (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | 3 | entry_hash_1 = 0xf2d804ab # (UK) (1989) (CPM) (UK retail version) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Red Sunset (2021).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0x3803e3fc # (UK) (128K) (2021) [Bitmat soft] [Original] 3 | 4 | entry_command = "RUN[quote]SUNSET" -------------------------------------------------------------------------------- /contrib/remaps/Shinobu (2019).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "103" 2 | input_player1_key_select = "27" 3 | 4 | entry_hash_1 = 0x37ee404f # (UK) (2019) 5 | -------------------------------------------------------------------------------- /contrib/remaps/Space Hawks - Aguilas Del Espacio (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | 3 | entry_hash_1 = 0xa041e903 # (UK) (1985) [Original] 4 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Tremolo.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = tremolo 3 | 4 | # Defaults. 5 | #tremolo_frequency = 4.0 6 | #tremolo_depth = 0.9 7 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Vibrato.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = vibrato 3 | 4 | # Defaults. 5 | #vibrato_frequency = 5.0 6 | #vibrato_depth = 0.5 7 | -------------------------------------------------------------------------------- /contrib/remaps/Camelot Warriors (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "106" 2 | 3 | entry_hash_1 = 0x2669032b # (UK) (1988) (Spain retail version) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Corsarios (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_y = "49" 2 | input_player1_key_x = "50" 3 | 4 | entry_hash_1 = 0x4dca3178 # (UK) (1989) (CPM) [Original] 5 | -------------------------------------------------------------------------------- /contrib/remaps/Freddy Hardest in South Manhattan (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | 3 | entry_hash_1 = 0x887d173f # (S) (1989) (CPM) [Original] 4 | -------------------------------------------------------------------------------- /contrib/remaps/Roland in Time (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "110" 2 | 3 | entry_hash_1 = 0xaca0e0f # (UK) (1985) [Amsoft - Gem Software] [Original] 4 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/HighShelfDampen.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = iir 3 | 4 | iir_gain = -12.0 5 | iir_type = HSH 6 | iir_frequency = 8000.0 7 | -------------------------------------------------------------------------------- /contrib/remaps/Arquimedes XXI (2011).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0x0eca7624 # (M4) (128K) (2011) (Version Basic 1.1) [Original] 3 | 4 | entry_command = "RUN[quote]AXXI" -------------------------------------------------------------------------------- /contrib/remaps/Bruce Lee (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_start_name = "Start" 3 | 4 | entry_hash_1 = 0xcf73ebd6 # (UK) (1984) [Original] 5 | 6 | -------------------------------------------------------------------------------- /contrib/remaps/Dragon Ninja (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "48" 2 | 3 | entry_hash_1 = 0x8c5e3ea2 # (UK) (1988) (CPM) (UK retail version) [Original] (Weak Sectors) 4 | -------------------------------------------------------------------------------- /contrib/remaps/Archon (1988).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_x = "276" 3 | input_player1_key_y = "275" 4 | input_player1_key_b = "32" 5 | 6 | entry_hash_1 = 0x551da885 # (UK) (1988) 7 | -------------------------------------------------------------------------------- /contrib/remaps/Emilio Butragueno Futbol (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "48" 2 | input_player1_key_select = "50" 3 | 4 | entry_hash_1 = 0x4f86b3c8 # (S) (1988) [Original] 5 | -------------------------------------------------------------------------------- /contrib/remaps/Gabrielle (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "32" 2 | input_player1_key_start_name = "Start" 3 | 4 | entry_hash_1 = 0x20dcbf76 # (F) (1987) [Original] (GAP2) 5 | -------------------------------------------------------------------------------- /contrib/remaps/Mundial de Futbol (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "13" 2 | input_player1_key_x_name = "Coach Sub" 3 | 4 | entry_hash_1 = 0x6f132709 # (S) (1990) (CPM) [Original] 5 | -------------------------------------------------------------------------------- /contrib/remaps/Xenon (1988).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_start = "50" 3 | 4 | entry_hash_1 = 0x91f26a80 # (UK) (1988) [Original] 5 | entry_hash_2 = 0x34cd836c # (S) (1988) [Original] -------------------------------------------------------------------------------- /contrib/remaps/Space Smugglers (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "51" 2 | 3 | entry_hash_1 = 0x99821ea9 # (S) (1989) (LightGun) (CPM) [Original] 4 | 5 | entry_command = "|CPM" 6 | -------------------------------------------------------------------------------- /external/cmocka/README: -------------------------------------------------------------------------------- 1 | Project: cmocka, unit testing framework for C 2 | URL: https://cmocka.org/ 3 | License: Apache License 2.0 4 | Upstream version: 1.1.5 5 | Local modifications: None -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Crystalizer.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = crystalizer 3 | # Controls dry/wet-ness of effect. 0.0 = none, 10.0 = max. 4 | crystalizer_intensity = 5.0 5 | -------------------------------------------------------------------------------- /contrib/remaps/180 (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | input_player1_key_b = "51" 4 | input_player1_key_b_name = "2 Players" 5 | 6 | entry_hash_1 = 0x90b13e33 # (UK) (1986) 7 | -------------------------------------------------------------------------------- /contrib/remaps/Gryzor (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_y = "32" 3 | input_player1_key_x = "32" 4 | 5 | entry_hash_1 = a2b01221 # (UK) (1987) (CPM) [Original] 6 | -------------------------------------------------------------------------------- /contrib/remaps/Solomons Key (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "13" 2 | input_player1_key_b_name = "Fireball" 3 | 4 | entry_hash_1 = 0x29671a87 # (UK) (1987) (UK retail version) [Original] 5 | -------------------------------------------------------------------------------- /contrib/remaps/Super Skweek (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "257" 2 | 3 | entry_hash_1 = 0x1993c727 # (UK) (1990) [Original] (GAPS) 4 | entry_hash_2 = 0x07a97eed # (F) (1990) [Original] (GAPS) -------------------------------------------------------------------------------- /contrib/remaps/Worm Slickers (1991).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_start = "32" 3 | 4 | entry_hash_1 = 0x4f36745 # (UK) (1991) [PC Amstrad International] 5 | 6 | entry_command = "RUN[quote]WORM" 7 | -------------------------------------------------------------------------------- /contrib/remaps/Defend or Die (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "32" 2 | 3 | input_player1_key_b = "9" 4 | input_player1_key_b_name = "Bomb" 5 | 6 | entry_hash_1 = 0xc147e40e # (UK) (1985) [tape] 7 | -------------------------------------------------------------------------------- /contrib/remaps/Angel Nieto Pole 500.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "32" 2 | input_player1_key_y = "274" 3 | 4 | input_player1_key_start = "13" 5 | 6 | entry_hash_1 = 0x6d278d3e # (S) (1990) (CPM) [Original] 7 | -------------------------------------------------------------------------------- /contrib/remaps/1942 (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | input_player1_key_b = "51" 4 | input_player1_key_b_name = "Roll Plane" 5 | 6 | 7 | entry_hash_1 = 0xab928e90 # (UK) (1986) [Original] 8 | -------------------------------------------------------------------------------- /contrib/remaps/Championship Sprint (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | input_player1_key_select = "49" 3 | 4 | input_player1_key_b = "32" 5 | 6 | entry_hash_1 = 0x8564c2d7 # (UK) (1988) (CPM) [Original] 7 | -------------------------------------------------------------------------------- /contrib/remaps/Heartland (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "49" 2 | input_player1_key_b_name = "Fire / Use Bed" 3 | 4 | entry_hash_1 = 0xc34b7449 # (UK) (1986) [Original] 5 | 6 | entry_command = "RUN[quote]HEART" 7 | -------------------------------------------------------------------------------- /contrib/remaps/Addams Family (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | input_player1_key_y = "52" 3 | input_player1_key_y_name = "Menu: Difficulty" 4 | 5 | entry_hash_1 = 0x4c117ec5 # (UK) (128K) (1992) [Original] 6 | -------------------------------------------------------------------------------- /contrib/remaps/Oh Mummy (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "112" 2 | input_player1_key_select = "99" 3 | 4 | entry_hash_1 = 0x2ff420da # (UK) (1984) [Tape Dump] 5 | entry_hash_2 = 0x6abd6ce2 # (S) (1984) [Nandsdoff] 6 | -------------------------------------------------------------------------------- /contrib/remaps/Cybernoid I-II.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | input_player1_key_select = "51" 3 | 4 | entry_hash_1 = 0x94d17670 # (UK) (1988) (CPM) [Original] 5 | entry_hash_2 = 0x2c70c790 # (UK) (1988) [Original] 6 | -------------------------------------------------------------------------------- /contrib/remaps/Samurai Warrior - The Battles of Usagi Yojimbo (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "51" 2 | input_player1_key_select = "49" 3 | 4 | entry_hash_1 = 0xfbd21696 # (UK) (1989) (CPM) (UK retail version) [Original] 5 | -------------------------------------------------------------------------------- /contrib/remaps/Techno Cop (1988).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_a = "49" 3 | input_player1_key_b = "122" 4 | input_player1_key_x = "96" 5 | 6 | input_player1_key_start = "32" 7 | 8 | entry_hash_1 = 0xcbdafd77 # (UK) (1988) [Original] -------------------------------------------------------------------------------- /contrib/remaps/Combat School (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_y = "13" 2 | input_player1_key_x = "13" 3 | input_player1_key_b = "32" 4 | 5 | input_player1_key_start = "49" 6 | 7 | entry_hash_1 = 0x9e263bd7 # (UK) (1987) (CPM) [Original] 8 | -------------------------------------------------------------------------------- /contrib/remaps/Helter Skelter (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_select = "100" 2 | input_player1_key_select_name = "Password" 3 | 4 | entry_hash_1 = 0x083c9554 # (UK) (2 faces) (1990) [Original] 5 | 6 | entry_command = "RUN[quote]HELTER" 7 | -------------------------------------------------------------------------------- /contrib/remaps/J.T 37 (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_select = "100" 2 | input_player1_key_select_name = "Password" 3 | 4 | entry_hash_1 = 0xa1b3336e # (UK) (1990) [Black System] [Amstar & CPC] 5 | 6 | entry_command = "RUN[quote]JT37" 7 | -------------------------------------------------------------------------------- /contrib/remaps/Ramparts (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "49" 2 | input_player1_key_x_name = "Press 1" 3 | 4 | input_player1_key_start = "115" 5 | input_player1_key_select = "49" 6 | 7 | entry_hash_1 = 0x31f0ac5b # (UK) (1987) [Original] -------------------------------------------------------------------------------- /contrib/remaps/After Burner (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "50" 2 | 3 | input_player1_key_b = "32" 4 | input_player1_key_b_name = "Change Speed" 5 | 6 | entry_hash_1 = 0x74458dd9 # (UK) (1988) (Spain retail version) [Original] 7 | -------------------------------------------------------------------------------- /contrib/remaps/Arkanoid (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "122" 2 | input_player1_key_right = "120" 3 | 4 | input_player1_key_a = "32" 5 | 6 | input_player1_key_start = "49" 7 | 8 | entry_hash_1 = 0xe4bf51 # (UK) (1987) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Auf Wiedersehen Monty (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "306" 2 | 3 | input_player1_key_start = "32" 4 | 5 | entry_hash_1 = 0x5c74e277 # (UK) (1987) (CPM) [Original] 6 | entry_hash_2 = 0xa32c19fb # (UK) (1987) (CPM) [Original] 7 | -------------------------------------------------------------------------------- /contrib/remaps/Shinobi (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "32" 2 | input_player1_key_b_name = "Magic" 3 | 4 | entry_hash_1 = 0x6f1e3eb0 # (UK) (1989) [Original] 5 | entry_hash_2 = 0xbd6c0af # (UK) (1989) [REMAKE] (clean-cpc-db fixed release) 6 | -------------------------------------------------------------------------------- /contrib/remaps/Vuelta al Mundo en 80 Dias (2022).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0x0d34f4df # (S) (2022) (Version Basic 1.1) (Hack) 3 | 4 | # [enter] => \n 5 | # [quote] => " 6 | # [wait] => wait 5 seconds 7 | entry_command = "RUN[quote]80DIAS" -------------------------------------------------------------------------------- /contrib/remaps/Beyond the Ice Palace (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_y = "121" 2 | input_player1_key_b = "32" 3 | input_player1_key_x = "112" 4 | 5 | input_player1_key_start = "121" 6 | 7 | entry_hash_1 = 0x2c2eb1e9 # (UK) (1988) (CPM) [Original] 8 | -------------------------------------------------------------------------------- /contrib/remaps/Rex (1989).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 0x6fbe410c # (UK) (1989) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]REX" 9 | -------------------------------------------------------------------------------- /contrib/remaps/Winter Games (1986).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_y = "97" 3 | 4 | input_player1_key_start = "13" 5 | input_player1_key_select = "303" 6 | 7 | entry_hash_1 = 0xba91af38 # (UK) (2 faces) (1986) (v2) [Original] 8 | entry_hash_2 = 0x4794cfb0 -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Reverb.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = reverb 3 | 4 | # Defaults. 5 | # reverb_drytime = 0.43 6 | # reverb_wettime = 0.4 7 | # reverb_damping = 0.8 8 | # reverb_roomwidth = 0.56 9 | # reverb_roomsize = 0.56 10 | -------------------------------------------------------------------------------- /contrib/remaps/Italia 90 (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "49" 2 | input_player1_key_x_name = "Press 1" 3 | 4 | input_player1_key_start = "49" 5 | input_player1_key_select = "50" 6 | 7 | entry_hash_1 = 0xaae46015 # (UK) (1990) (UK retail version) [Original] -------------------------------------------------------------------------------- /contrib/remaps/Manic Miner (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_b = "13" 3 | 4 | entry_hash_1 = 0xcd9dbf9c # (UK) (1984) (Version Basic 1.0) [Amsoft] 5 | entry_hash_2 = 0x7a60b38e # (UK) (1985) (Hack - Manic Miner 2) (fix) 6 | -------------------------------------------------------------------------------- /contrib/remaps/Turbo Girl (1988).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_b = "32" 3 | input_player1_key_b_name = "Jump" 4 | 5 | input_player1_key_start = "50" 6 | 7 | entry_hash_1 = 0x77c7c536 # (S) (1988) (CPM) [Original] 8 | entry_hash_2 = 0x1e737e6c # (UK) (1988) -------------------------------------------------------------------------------- /contrib/remaps/WWF Wrestlemania (1991).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_select = "13" 3 | input_player1_key_start = "49" 4 | 5 | input_player1_key_b = "13" 6 | input_player1_key_b_name = "Select" 7 | 8 | entry_hash_1 = 0x06533fb5 # (UK) (1991) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Aventura Original (1989).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = b0c8cc9e # (S) (1989) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "|CPM" 9 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/WahWah.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = wahwah 3 | 4 | # Defaults. 5 | # wahwah_lfo_freq = 1.5 6 | # wahwah_lfo_start_phase = 0.0 7 | # wahwah_freq_offset = 0.3 8 | # wahwah_depth = 0.7 9 | # wahwah_resonance = 2.5 10 | -------------------------------------------------------------------------------- /contrib/remaps/Archon II (1989).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_y = "51" 3 | input_player1_key_x = "52" 4 | input_player1_key_b = "32" 5 | 6 | input_player1_key_start = "53" 7 | input_player1_key_select = "48" 8 | 9 | entry_hash_1 = 0x1fae9dcb # (UK) (1989) 10 | -------------------------------------------------------------------------------- /contrib/remaps/Enchanter (1984).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = cca0759 # (1984) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "ENCHANTE" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Infidel (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = dc3c19fc # (1986) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "INFIDEL" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Suspended (1983).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 819d6ed7 # (1983) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "SUSPENDE" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Xyphoes Fantasy (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "48" 2 | 3 | entry_hash_1 = 0xdb70571b # (F) (128K) (2 faces) (1991) (CPM) [Original] 4 | entry_hash_2 = 0xf0a1468e # (S) (128K) (2 faces) (1991) (CPM) [Original] 5 | 6 | entry_command = "|CPM" 7 | -------------------------------------------------------------------------------- /contrib/remaps/Cutthroats (1984).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 5d21b329 # (1984) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "CUTTHROA" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Gnome Ranger (1987).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = b0a79287 # (1987) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]MENU" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Jungle Book (1989).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = ccc3a70b # (1989) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]JUNGLE" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Lancelot (1988).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = c5ad3e3e # (1988) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]MENU" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Planetfall (1983).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 9af2061b # (1983) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "PLANETFA" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Spellbreaker (1985).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = d519f3ce # (1985) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "SPELLBRE" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Wishbringer (1985).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 5332c3ad # (1985) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "WISHBRIN" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Witness, The (1984).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = b16409a2 # (1984) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "WITNESS" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Batman (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "257" 2 | input_player1_key_b_name = "Carry" 3 | input_player1_key_x = "32" 4 | input_player1_key_x_name = "Carry and Jump" 5 | input_player1_key_start = "13" 6 | 7 | entry_hash_1 = 0x814d462 # (UK) (1986) [Original] 8 | -------------------------------------------------------------------------------- /contrib/remaps/Colossus Mahjong (1987).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = af529a6a # (1987) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "MAHJONG" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Ivan Ironman Super Off Road (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "52" 2 | input_player1_key_x_name = "Press 4" 3 | input_player1_key_y = "49" 4 | input_player1_key_y_name = "Press 1" 5 | 6 | entry_hash_1 = 0xc3ce5121 # (UK) (1990) (UK retail version) [Original] 7 | -------------------------------------------------------------------------------- /contrib/remaps/Secte Noire, La (1990).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 95b94081 # (1990) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]SECTE" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Three Weeks in Paradise (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "50" 2 | input_player1_key_x_name = "Slot 2" 3 | input_player1_key_y = "49" 4 | input_player1_key_y_name = "Slot 1" 5 | 6 | input_player1_key_start = "97" 7 | 8 | entry_hash_1 = 0x60a4a40f # (UK) (1986) -------------------------------------------------------------------------------- /contrib/remaps/Hair Boy (2016).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_a = "32" 2 | input_player1_key_a_name = "Jump" 3 | input_player1_key_right = "275" 4 | input_player1_key_left = "276" 5 | input_player1_key_start = "32" 6 | 7 | entry_hash_1 = 0xca1ccfa9 # (2016) (cpcretrodev.byterealms) [cr] 8 | -------------------------------------------------------------------------------- /contrib/remaps/Murder on the Atlantic (1985).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = b40c5cb2 # (1985) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "RUN[quote]GAME" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Sorcerer (1984)(Infocom)[CPM].rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 636a30d8 # (1984) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "SORCERER" 9 | 10 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/BassBoost.dsp: -------------------------------------------------------------------------------- 1 | filters = 2 2 | filter0 = iir 3 | filter1 = panning 4 | 5 | iir_gain = 10.0 6 | iir_type = BBOOST 7 | iir_frequency = 200.0 8 | 9 | # Avoids clipping. 10 | panning_left_mix = "0.3 0.0" 11 | panning_right_mix = "0.0 0.3" 12 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Phaser.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = phaser 3 | 4 | # Defaults. 5 | # phaser_lfo_freq = 0.4 6 | # phaser_lfo_start_phase = 0.0 7 | # phaser_feedback = 0.0 8 | # phaser_depth = 0.4 9 | # phaser_dry_wet = 0.5 10 | # phaser_stages = 2 11 | -------------------------------------------------------------------------------- /contrib/remaps/Leather Goddesses of Phobos (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = eb127e47 # (1986) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "LEATHERG" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Mikie (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "32" 2 | input_player1_key_x_name = "Push a classmate" 3 | input_player1_key_b = "13" 4 | input_player1_key_b_name = "Catch multiple hearts" 5 | 6 | input_player1_key_start = "115" 7 | 8 | entry_hash_1 = 0x48684cf4 # (UK) (1986) 9 | -------------------------------------------------------------------------------- /contrib/remaps/Zork II - The Wizard of Frobozz (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = e0240de6 # (1986) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "ZORK2" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Zork III - The Dungeon Master (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = a3fb554f # (1986) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "ZORK3" 9 | 10 | -------------------------------------------------------------------------------- /libretro-common/crt/include/string.h: -------------------------------------------------------------------------------- 1 | #ifndef __LIBRETRO_SDK_CRT_STRING_H_ 2 | #define __LIBRETRO_SDK_CRT_STRING_H_ 3 | 4 | #include 5 | 6 | void *memcpy(void *dst, const void *src, size_t len); 7 | 8 | void *memset(void *b, int c, size_t len); 9 | 10 | #endif 11 | -------------------------------------------------------------------------------- /contrib/remaps/Barbarian (Palace Software) (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_start_name = "Start" 3 | input_player1_key_x = "32" 4 | 5 | 6 | entry_hash_1 = 0xc761e738 # (UK) (2 faces) (1987) [Palace Software] [Original] 7 | entry_hash_2 = 0x60e1f5f0 8 | 9 | -------------------------------------------------------------------------------- /contrib/remaps/Hustler (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | input_player1_key_start_name = "Game 1" 3 | input_player1_key_select = "50" 4 | input_player1_key_select_name = "Game 2" 5 | 6 | entry_hash_1 = 0xe460536c # (UK) (1985) (CPM) [Original] 7 | 8 | entry_command = "|CPM" 9 | -------------------------------------------------------------------------------- /contrib/remaps/Sol Negro (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "50" 2 | input_player1_key_x_name = "Second Stage" 3 | input_player1_key_y = "49" 4 | input_player1_key_y_name = "First Stage" 5 | 6 | input_player1_key_start = "13" 7 | 8 | entry_hash_1 = 0xb0540671 # (S) (1988) (CPM) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Zork I - The Great Underground Empire (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = a02c3758 # (1986) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "ZORK1" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Hitchhiker's Guide to the Galaxy, The (1984).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = a523527c # (1984) (CPM) [Original] 2 | 3 | # game load command 4 | # special commands: 5 | # [enter] => \n 6 | # [quote] => " 7 | # [wait] => wait 5 seconds 8 | entry_command = "HITCHHIK" 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/Mutan Zone (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "50" 2 | input_player1_key_x_name = "Second Stage" 3 | input_player1_key_y = "49" 4 | input_player1_key_y_name = "First Stage" 5 | 6 | input_player1_key_start = "13" 7 | 8 | entry_hash_1 = 0x62a4deae # (S) (1988) (v2) (CPM) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Sport (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_a = "307" 2 | input_player1_key_a_name = "Action" 3 | input_player1_key_b = "32" 4 | input_player1_key_b_name = "Throw Shot or Jump" 5 | 6 | entry_hash_1 = 0xabd24f9a # (UK) (1989) [Black System] [Amstar & CPC] 7 | 8 | entry_command = "RUN[quote]SPORT" -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/EchoReverb.dsp: -------------------------------------------------------------------------------- 1 | filters = 2 2 | filter0 = echo 3 | filter1 = reverb 4 | 5 | echo_delay = "200" 6 | echo_feedback = "0.6" 7 | echo_amp = "0.25" 8 | 9 | reverb_roomwidth = 0.75 10 | reverb_roomsize = 0.75 11 | reverb_damping = 1.0 12 | reverb_wettime = 0.3 13 | -------------------------------------------------------------------------------- /contrib/remaps/Shadow Dancer (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "32" 2 | input_player1_key_b_name = "Dog Attack" 3 | input_player1_key_x = "13" 4 | input_player1_key_x_name = "Magic" 5 | 6 | input_player1_key_start = "48" 7 | 8 | entry_hash_1 = 0x20e80d12 # (UK) (1991) (Spain retail version) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Budokan - The Martial Spirit (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "49" 2 | input_player1_key_x_name = "Key 1" 3 | input_player1_key_y = "50" 4 | input_player1_key_y_name = "Key 2" 5 | 6 | input_player1_key_start = "32" 7 | 8 | entry_hash_1 = 0x480c9e65 # (UK) (2 faces) (1990) (CPM) [Original] 9 | -------------------------------------------------------------------------------- /contrib/remaps/Cobra - Loriciels.rmp: -------------------------------------------------------------------------------- 1 | # Fix bad original catalogue 2 | entry_hash_1 = 0x504d8d95 # (FR) (1987) [Original] 3 | 4 | 5 | # game load command 6 | # special commands: 7 | # [enter] => \n 8 | # [quote] => " 9 | # [wait] => wait 5 seconds 10 | entry_command = "RUN[QUOTE]COBRA." 11 | -------------------------------------------------------------------------------- /contrib/remaps/Nemesis (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_y = "109" 2 | input_player1_key_y_name = "Music Toggle" 3 | input_player1_key_b = "13" 4 | input_player1_key_b_name = "Select Weapon" 5 | entry_map_type = "keep" # default 6 | 7 | entry_hash_1 = 0xb35ed50 # (UK) (1987) (CPM) [Original] 8 | 9 | 10 | -------------------------------------------------------------------------------- /contrib/remaps/West Bank (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "49" 2 | input_player1_key_right = "51" 3 | 4 | input_player1_key_a = "50" 5 | input_player1_key_b = "50" 6 | 7 | input_player1_key_start = "48" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 0x361c4a1e # (S) (1986) [Original] 12 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Mono.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = panning 3 | 4 | # Gains are linear. 5 | 6 | # Stereo Mono: 7 | panning_left_mix = "0.5 0.5" 8 | panning_right_mix = "0.5 0.5" 9 | 10 | # Mono on one speaker: 11 | # panning_left_mix = "0.5 0.5" 12 | # panning_right_mix = "0.0 0.0" 13 | -------------------------------------------------------------------------------- /contrib/remaps/Sabre Wulf (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "114" 2 | input_player1_key_down = "101" 3 | input_player1_key_left = "113" 4 | input_player1_key_right = "119" 5 | 6 | input_player1_key_a = "32" 7 | input_player1_key_start = "48" 8 | 9 | entry_hash_1 = 0x36596d2c # (UK) (1985) [Tape Conversion] 10 | -------------------------------------------------------------------------------- /contrib/remaps/Dynamite Dan (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "97" 2 | input_player1_key_right = "115" 3 | 4 | input_player1_key_start = "13" 5 | 6 | input_player1_key_a = "32" 7 | input_player1_key_a_name = "Jump" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 0x550ac9f9 # (UK) (1985) [tape] 12 | -------------------------------------------------------------------------------- /contrib/remaps/Exolon (1987).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "113" 8 | 9 | input_player1_key_start = "49" 10 | 11 | entry_hash_1 = 0x69219b4f # (UK) (1989) (CPM) [Original] -------------------------------------------------------------------------------- /contrib/remaps/Moon Cresta (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "120" 2 | input_player1_key_left = "122" 3 | 4 | input_player1_key_a = "303" 5 | input_player1_key_a_name = "Fire" 6 | 7 | input_player1_key_start = "54" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 0x6abcc9b6 # (UK) (1986) [Original] 12 | -------------------------------------------------------------------------------- /contrib/remaps/Bomb Jack (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "110" 4 | input_player1_key_right = "109" 5 | 6 | input_player1_key_a = "120" 7 | input_player1_key_start = "49" 8 | 9 | entry_hash_1 = 0x4bf042ca # (UK) (1986) (Spain retail version) [Original] 10 | -------------------------------------------------------------------------------- /contrib/remaps/Rainbow Islands (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "97" 2 | 3 | input_player1_key_a = "32" 4 | input_player1_key_b = "97" 5 | 6 | input_player1_key_left = "107" 7 | input_player1_key_right = "108" 8 | 9 | entry_hash_1 = 0xd11aa568 # (UK) (1989) (CPM) [EDOS] [Original] 10 | 11 | entry_map_type = "clean" 12 | -------------------------------------------------------------------------------- /contrib/remaps/Shadow Maze - Celebration (2023).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | 9 | entry_hash_1 = 0x82d52c01 # (UK) (2023) 10 | 11 | entry_command = "RUN[quote]INTRO" 12 | -------------------------------------------------------------------------------- /contrib/remaps/BMX Simulator (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "102" 2 | input_player1_key_down = "99" 3 | input_player1_key_left = "122" 4 | input_player1_key_right = "120" 5 | 6 | input_player1_key_a = "102" 7 | input_player1_key_b = "32" 8 | 9 | input_player1_key_start = "115" 10 | 11 | entry_hash_1 = 0x6cf1612c # (UK) (1987) 12 | -------------------------------------------------------------------------------- /contrib/remaps/Trivial Pursuit (1988).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0xc46c46de # A New Beginning (UK) (2 faces) (1988) (CPM) [Original] 3 | entry_hash_2 = 0x23c7634e # Nouvelle Generation (F) (2 faces) (1988) (CPM) [Original] 4 | entry_hash_3 = 0x668247d3 # La Revolution Francaise (F) (2 faces) (1989) (CPM) [Original] 5 | 6 | entry_command = "|CPM" -------------------------------------------------------------------------------- /contrib/remaps/Warlock (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "273" 2 | input_player1_key_down = "274" 3 | input_player1_key_left = "276" 4 | input_player1_key_right = "275" 5 | 6 | input_player1_key_a = "307" 7 | 8 | input_player1_key_start = "304" 9 | 10 | entry_map_type = "clean" 11 | 12 | entry_hash_1 = 0xa1b83838 # (UK) (1987) [Original] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Classic Invaders (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "122" 2 | input_player1_key_right = "120" 3 | 4 | input_player1_key_a = "13" 5 | input_player1_key_b = "97" 6 | input_player1_key_start = "13" 7 | 8 | entry_map_type = "clean" 9 | entry_command = "|CPM" 10 | 11 | entry_hash_1 = 0xe698b5f6 # (UK) (1986) (CPM) (v2) [Original] 12 | -------------------------------------------------------------------------------- /contrib/remaps/Boloncio (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "257" 2 | input_player1_key_right = "259" 3 | input_player1_key_a = "32" 4 | input_player1_key_a_name = "Jump" 5 | input_player1_key_start = "115" 6 | input_player1_key_start_name = "S / Start" 7 | 8 | entry_hash_1 = 0x5fc8032d # (S) (1986) [Tape Dump - Kukulcan] 9 | 10 | entry_map_type = "clean" 11 | -------------------------------------------------------------------------------- /contrib/remaps/Chessmaster 2000 (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "110" 2 | input_player1_key_x_name = "No" 3 | input_player1_key_y = "121" 4 | input_player1_key_y_name = "Yes" 5 | 6 | 7 | entry_hash_1 = 0x87cce8 # (UK) (1990) [Original] 8 | 9 | # [enter] => \n 10 | # [quote] => " 11 | # [wait] => wait 5 seconds 12 | entry_command = "RUN[quote]CHESS" -------------------------------------------------------------------------------- /contrib/remaps/Gauntlet (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "259" 2 | input_player1_key_start = "32" 3 | 4 | # Player 2 5 | input_player2_key_up = "9" 6 | input_player2_key_down = "301" 7 | input_player2_key_left = "100" 8 | input_player2_key_right = "102" 9 | input_player2_key_a = "303" 10 | 11 | entry_hash_1 = 0x7c16d340 # (UK) (1986) (CPM) [Original] (fix) 12 | 13 | -------------------------------------------------------------------------------- /contrib/remaps/Silkworm (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "48" 2 | 3 | # Player 2 4 | # QAOP 5 | input_player2_key_up = "113" 6 | input_player2_key_down = "97" 7 | input_player2_key_left = "111" 8 | input_player2_key_right = "112" 9 | input_player2_key_a = "32" # SPACE 10 | 11 | input_player2_key_start = "48" 12 | 13 | entry_hash_1 = 0x75b52a3b # [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Wonderboy (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_y = "8" 2 | input_player1_key_y_name = "Music Toggle" 3 | input_player1_key_up = "$DB_CLEAN" 4 | input_player1_key_start = "49" 5 | input_player1_key_select = "27" 6 | input_player1_key_b = "$204" # JOY FIRE1 7 | input_player1_key_a = "$200" # JOY UP 8 | 9 | entry_hash_1 = 0xb1026135 # (UK) (1987) (CPM) [Original] 10 | -------------------------------------------------------------------------------- /contrib/remaps/Beach Buggy (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "$DB_CLEAN" 2 | input_player1_key_b = "$204" 3 | input_player1_key_b_name = "Fire" 4 | input_player1_key_a = "$200" 5 | input_player1_key_a_name = "Jump" 6 | input_player1_key_start = "50" 7 | input_player1_key_select_name = "Start" 8 | 9 | entry_hash_1 = 0x10bd9015 # (UK) (1987) (clean-cpc-db fixed release) 10 | 11 | -------------------------------------------------------------------------------- /contrib/remaps/Chuckie Egg (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "97" 2 | input_player1_key_down = "122" 3 | input_player1_key_left = "44" 4 | input_player1_key_right = "46" 5 | 6 | input_player1_key_a = "32" 7 | input_player1_key_y = "49" 8 | input_player1_key_x = "50" 9 | 10 | input_player1_key_start = "115" 11 | 12 | entry_hash_1 = 0x12354538 # (UK) (1985) [Tape conversion] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Chuckie Egg II (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "97" 2 | input_player1_key_down = "122" 3 | input_player1_key_left = "44" 4 | input_player1_key_right = "46" 5 | 6 | input_player1_key_a = "32" 7 | input_player1_key_y = "49" 8 | input_player1_key_x = "50" 9 | 10 | input_player1_key_start = "112" 11 | 12 | entry_hash_1 = 0x11b9e71d # (UK) (1985) [Tape conversion] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Roland On The Ropes - Fred (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "273" 2 | input_player1_key_down = "274" 3 | input_player1_key_left = "276" 4 | input_player1_key_right = "275" 5 | 6 | input_player1_key_a = "307" 7 | 8 | input_player1_key_start = "53" 9 | 10 | entry_hash_1 = 0x324cfc6 # (UK) (1984) [Original] 11 | entry_hash_2 = 0xc3997a3d # (S) (1984) [clean-cpc-db] 12 | -------------------------------------------------------------------------------- /contrib/remaps/Vera Cruz Affair, The (1986).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = d5a4c3f2 # (1985) (fr) (CPM) [Original] 2 | entry_hash_2 = 4f6b8ae6 # (1986) (CPM) [Original] 3 | entry_hash_3 = d276b5bc # (1987) (de) (CPM) [Original] 4 | 5 | # game load command 6 | # special commands: 7 | # [enter] => \n 8 | # [quote] => " 9 | # [wait] => wait 5 seconds 10 | entry_command = "|CPM" 11 | 12 | -------------------------------------------------------------------------------- /contrib/remaps/WEC Le Mans (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "111" 4 | input_player1_key_right = "112" 5 | 6 | input_player1_key_a = "113" 7 | input_player1_key_b = "32" 8 | 9 | input_player1_key_start = "50" 10 | 11 | entry_map_type = "clean" 12 | 13 | entry_hash_1 = 0x54c40e54 # (UK) (1988) (CPM) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Blood Valley (1987).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_x = "106" 3 | input_player1_key_x_name = "Joystick Select" 4 | 5 | 6 | input_player1_key_start = "49" 7 | input_player1_key_select = "106" 8 | 9 | entry_hash_1 = 0x7724c437 # (UK,F,G) (1987) [Original] 10 | 11 | # [enter] => \n 12 | # [quote] => " 13 | # [wait] => wait 5 seconds 14 | entry_command = "RUN[quote]BLOOD" -------------------------------------------------------------------------------- /contrib/remaps/Nanako Descends to Hell (2009).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_right = "112" 4 | input_player1_key_left = "111" 5 | input_player1_key_a = "32" 6 | input_player1_key_a_name = "Use" 7 | input_player1_key_start = "32" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 0x6c2cdcea # (UK) (2009) (site download) 12 | -------------------------------------------------------------------------------- /contrib/remaps/Powerplay - cr (1986).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_b = "13" 3 | input_player1_key_b_name = "Return" 4 | 5 | input_player1_key_x = "27" 6 | input_player1_key_x_name = "Esc" 7 | input_player1_key_y = "32" 8 | input_player1_key_y_name = "Space" 9 | 10 | input_player1_key_start = "108" 11 | input_player1_key_select = "50" 12 | 13 | entry_hash_1 = 0xf49d6612 # (UK) (1986) 14 | -------------------------------------------------------------------------------- /contrib/remaps/Goonies (1986).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "303" 8 | input_player1_key_a_name = "Change Character" 9 | 10 | input_player1_key_start = "53" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0xb6e80000 # (UK) (1986) 15 | -------------------------------------------------------------------------------- /contrib/remaps/Light Corridor (1990).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | 12 | 13 | entry_hash_1 = 0xb5dd9b44 # (UK) (1990) (CPM) [MCM Software] [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Ice-Breaker (1990).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "115" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0x55b67795 # (S) (1990) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Rygar (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | 12 | entry_hash_1 = 0x558abe44 # (UK) (1987) (v2) [Original] 13 | 14 | entry_map_type = "clean" 15 | -------------------------------------------------------------------------------- /contrib/remaps/Vendetta (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "32" 2 | input_player1_key_y_name = "Select Object" 3 | 4 | input_player1_key_y = "32" 5 | input_player1_key_y_name = "Select Object" 6 | 7 | input_player1_key_b = "13" 8 | input_player1_key_b_name = "Select Weapon" 9 | 10 | input_player1_key_start = "115" 11 | 12 | entry_hash_1 = 0xdfb023f8 # (UK) (1990) (UK retail version) [Original] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Skate Crazy (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "32" 2 | 3 | input_player1_key_x = "50" 4 | input_player1_key_x_name = "Press 2" 5 | input_player1_key_y = "49" 6 | input_player1_key_y_name = "Press 1" 7 | 8 | input_player1_key_start = "112" 9 | input_player1_key_start_name = "Pause" 10 | 11 | entry_hash_1 = 0xef7871dc # (UK) (2 faces) (1988) (CPM) [Original] 12 | entry_hash_2 = 0x5ac9f3f4 -------------------------------------------------------------------------------- /contrib/remaps/Deathsville (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "120" 2 | input_player1_key_left = "122" 3 | input_player1_key_a = "13" 4 | input_player1_key_a_name = "Jump / Enter Room" 5 | input_player1_key_b = "32" 6 | input_player1_key_b_name = "Pick-up/Drop Object" 7 | input_player1_key_start = "13" 8 | 9 | entry_map_type = "clean" 10 | entry_hash_1 = 0xb0dd3611 # (UK) (1986) (CPM) (v2) [Original] 11 | -------------------------------------------------------------------------------- /contrib/remaps/Desperado (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0xcb00cc73 # (S) (2 faces) (1987) [clean-cpc-db] 15 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.so 2 | *.o 3 | *.dll 4 | *.a 5 | *.gch 6 | *.orig 7 | *.rej 8 | *.log 9 | *.hex 10 | *.diff 11 | *.off 12 | # gimp dumps 13 | *.raw 14 | # editors 15 | .vscode 16 | .venv 17 | 18 | # rom assets 19 | *.dsk 20 | *.sna 21 | *.cdt 22 | *.m3u 23 | 24 | # external libs 25 | external/cmocka/cmocka-lib 26 | 27 | # tests files 28 | tests/ 29 | tests-db/ 30 | unit-tests/test-db 31 | unit-tests/autorun 32 | -------------------------------------------------------------------------------- /contrib/remaps/Zap t Balls (1992).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "32" 2 | input_player1_key_x = "120" 3 | input_player1_key_y = "121" 4 | 5 | 6 | input_player1_key_start = "49" 7 | 8 | entry_hash_1 = 0xe434e0db # (UK) (128K) (2 faces) (1992) (Serial 0058 - Qwerty) (CPM) [Original] 9 | entry_hash_2 = 0x8559909a # (UK) (128K) (2 faces) (1992) (Serial 0999 - Azerty) (CPM) [Original] 10 | 11 | entry_command = "|CPM" 12 | -------------------------------------------------------------------------------- /contrib/remaps/Abu Simbel Profanation (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "112" 2 | input_player1_key_left = "111" 3 | input_player1_key_a = "97" 4 | input_player1_key_a_name = "Short Jump" 5 | input_player1_key_b = "113" 6 | input_player1_key_b_name = "Long Jump" 7 | input_player1_key_start = "50" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 0x7037c06c # (S) (1984) [Tape Dump - Pablo Forcen Soler] 12 | -------------------------------------------------------------------------------- /contrib/remaps/Comando Tracer (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_down_name = "Down / Use" 5 | input_player1_key_left = "111" 6 | input_player1_key_right = "112" 7 | 8 | input_player1_key_start = "48" 9 | 10 | input_player1_key_a = "32" 11 | input_player1_key_a_name = "Shoot" 12 | 13 | entry_hash_1 = 0x261b785 # (S) (1988) (CPM) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Motos (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Jump" 9 | 10 | input_player1_key_start = "48" 11 | input_player1_key_select = "49" 12 | 13 | entry_map_type = "clean" 14 | 15 | entry_hash_1 = 0x148447dc # (UK) (1987) 16 | -------------------------------------------------------------------------------- /contrib/remaps/Aspar Grand Prix Master (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_start = "49" 9 | 10 | entry_hash_1 = 0x8714bccc # (S) (1988) [Original] 11 | entry_hash_2 = 0x36c70444 # (UK) (1988) (CPM) [Original] 12 | 13 | entry_map_type = "clean" 14 | -------------------------------------------------------------------------------- /contrib/remaps/Donkey Kong (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_right = "93" 4 | input_player1_key_left = "91" 5 | input_player1_key_a = "32" 6 | input_player1_key_a_name = "Jump" 7 | input_player1_key_start = "49" 8 | input_player1_key_select_name = "Start One Player" 9 | 10 | entry_map_type = "clean" 11 | 12 | entry_hash_1 = 0x9b7c1f2 # (UK) (1986) [Original] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Match Day II (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_b = "13" 3 | 4 | input_player2_key_up = "97" 5 | input_player2_key_down = "122" 6 | input_player2_key_left = "111" 7 | input_player2_key_right = "112" 8 | input_player2_key_a = "32" 9 | input_player2_key_a_name = "Kick" 10 | 11 | input_player2_key_start = "50" 12 | 13 | entry_hash_1 = 0x35c029d5 # (UK) (1987) (CPM) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Stormlord II (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "113" 2 | input_player1_key_b_name = "Jump" 3 | 4 | input_player1_key_x = "50" 5 | input_player1_key_x_name = "Press 2" 6 | input_player1_key_y = "49" 7 | input_player1_key_y_name = "Press 1" 8 | 9 | input_player1_key_start = "308" 10 | input_player1_key_start_name = "Pause" 11 | 12 | entry_hash_1 = 0x375d4353 # (UK) (1990) (UK retail version) [Original] 13 | -------------------------------------------------------------------------------- /contrib/remaps/Boulder Dash (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_start_name = "Start" 3 | input_player1_key_b = "49" 4 | 5 | entry_hash_1 = 0x46b5fe2c # (UK) (1985) [Original] 6 | entry_hash_2 = 0xfed514e8 # 2 (UK) (1985) (Hack) 7 | entry_hash_3 = 0x474a9722 # 2 (F) (1985) (Hack) 8 | entry_hash_4 = 0x5ebc61a1 # 3 (UK) (1986) [Ozisoft] [Original] 9 | entry_hash_5 = 0x48fcdc1e # 6 (UK) (1986) (Hack) 10 | -------------------------------------------------------------------------------- /contrib/remaps/Miss Input 1 (2019).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "112" 2 | input_player1_key_left = "111" 3 | 4 | input_player1_key_a = "113" 5 | input_player1_key_a_name = "Jump" 6 | 7 | input_player1_key_y = "109" 8 | input_player1_key_y_name = "Music Toggle" 9 | 10 | input_player1_key_start = "49" 11 | input_player1_key_select = "50" 12 | 13 | entry_map_type = "clean" 14 | 15 | entry_hash_1 = 0xe8d15029 # (UK) (2019) 16 | -------------------------------------------------------------------------------- /contrib/remaps/Miss Input 2 (2020).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "101" 2 | input_player1_key_left = "119" 3 | 4 | input_player1_key_a = "113" 5 | input_player1_key_a_name = "Jump" 6 | 7 | input_player1_key_y = "109" 8 | input_player1_key_y_name = "Music Toggle" 9 | 10 | input_player1_key_start = "49" 11 | input_player1_key_select = "50" 12 | 13 | entry_map_type = "clean" 14 | 15 | entry_hash_1 = 0x7c096b33 # (UK) (2020) 16 | -------------------------------------------------------------------------------- /contrib/remaps/Operation Wolf (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0x7c6c1e2e # (UK) (1988) (Spain retail version) [Original] 15 | 16 | -------------------------------------------------------------------------------- /contrib/remaps/Phantomas Saga Infinity (2006).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_left = "276" 3 | input_player1_key_right = "275" 4 | 5 | input_player1_key_a = "273" 6 | input_player1_key_a_name = "Long Jump" 7 | input_player1_key_b = "274" 8 | input_player1_key_b_name = "Short Jump" 9 | 10 | input_player1_key_start = "115" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0x73d96734 # (UK) (2006) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Renegade (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "119" 2 | input_player1_key_down = "32" 3 | input_player1_key_left = "97" 4 | input_player1_key_right = "100" 5 | 6 | input_player1_key_a = "275" 7 | input_player1_key_b = "276" 8 | input_player1_key_y = "274" 9 | input_player1_key_x = "274" 10 | 11 | input_player1_key_start = "32" 12 | 13 | entry_hash_1 = 0xdf16b5d3 # (UK) (1987) [Imagine Software] [Original] (Fix) 14 | -------------------------------------------------------------------------------- /contrib/remaps/Clever and Smart (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "109" 10 | input_player1_key_a_name = "Fire" 11 | input_player1_key_b = "110" 12 | input_player1_key_b_name = "Select" 13 | 14 | entry_hash_1 = 0x3a5242b9 # (S) (1986) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Tres Luces de Glaurung (1986).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "109" 10 | input_player1_key_a_name = "Fire" 11 | input_player1_key_b = "110" 12 | input_player1_key_b_name = "Select" 13 | 14 | entry_hash_1 = 0x3a5242b9 # (S) (1986) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Goody (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_b = "13" 9 | input_player1_key_start = "32" 10 | input_player1_key_select = "127" 11 | 12 | entry_hash_1 = 0xbc911bd9 # (S) (1987) (CPM) [SyX FIX] 13 | entry_hash_2 = 0x795638dc # (S) (1987) (CPM) [Original - Bug] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Jarlac (2018).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "51" 8 | 9 | input_player1_key_a = "113" 10 | input_player1_key_a_name = "Jump" 11 | input_player1_key_b = "32" 12 | input_player1_key_b_name = "Fire" 13 | 14 | entry_map_type = "clean" 15 | 16 | entry_hash_1 = 0x3b4ddeb5 # (2018) 17 | -------------------------------------------------------------------------------- /contrib/remaps/Mad Mix Game (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0xc36d1efd # (S) (1988) (v1) 15 | entry_hash_2 = 0x97b8b3a9 # (UK) (1988) [Original] 16 | -------------------------------------------------------------------------------- /contrib/remaps/Classic Axiens (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "122" 2 | input_player1_key_right = "120" 3 | 4 | input_player1_key_a = "109" 5 | input_player1_key_a_name = "Fire" 6 | 7 | input_player1_key_start = "49" 8 | 9 | entry_hash_1 = 0x84e1c9fe # (UK) (1986) [Original] (CPM) 10 | 11 | # [enter] => \n 12 | # [quote] => " 13 | # [wait] => wait 5 seconds 14 | entry_command = "RUN[quote]HIRISE" 15 | 16 | entry_map_type = "clean" 17 | -------------------------------------------------------------------------------- /contrib/remaps/Freddy Hardest (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | 12 | entry_map_type = "clean" 13 | 14 | entry_hash_1 = 0x7a8fe41d # (UK) (1987) [Original] 15 | entry_hash_2 = 0x874e9bb6 # (S) (1987) (CPM) [Original] 16 | -------------------------------------------------------------------------------- /contrib/remaps/Klax (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "112" 2 | input_player1_key_left = "111" 3 | input_player1_key_a = "32" 4 | input_player1_key_a_name = "Throw piece" 5 | input_player1_key_b = "97" 6 | input_player1_key_b_name = "Drop piece" 7 | input_player1_key_x = "113" 8 | input_player1_key_x_name = "Speed up" 9 | input_player1_key_start = "48" 10 | 11 | entry_map_type = "clean" 12 | 13 | entry_hash_1 = 0x96b53a41 # (UK) (1990) (CPM) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Prince of Persia (1990).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_x = "32" 2 | input_player1_key_x_name = "Time Left" 3 | input_player1_key_start = "27" 4 | input_player1_key_start_name = "Pause" 5 | 6 | entry_hash_1 = f964db5d # (UK) (1990) (Spain retail version) [Original] - no codes 7 | entry_hash_2 = a14a1e0f # (UK) (1990) (UK retail version) [Original] 8 | entry_hash_3 = b9d14a6d # (F) (1990) (v2) [Original] 9 | entry_hash_4 = 18d230b1 # (F) (1990) (v3) [Original] 10 | -------------------------------------------------------------------------------- /contrib/remaps/Asterix and the Magic Carpet (1988).rmp: -------------------------------------------------------------------------------- 1 | entry_hash_1 = 0x392fbb50 # (S) (2 faces) (1988) (CPM) [Original] 2 | entry_hash_2 = 0x33e38c87 # (F) (2 faces) (1988) (CPM) [Original] (Weak Sectors) 3 | entry_hash_3 = 0x31d37ba2 # (G) (2 faces) (1988) (CPM) [Original] (Weak Sectors) 4 | 5 | # game load command 6 | # special commands: 7 | # [enter] => \n 8 | # [quote] => " 9 | # [wait] => wait 5 seconds 10 | entry_command = "|CPM[enter][wait][wait]LOADER" 11 | -------------------------------------------------------------------------------- /contrib/remaps/Chase H.Q (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "107" 2 | input_player1_key_right = "108" 3 | 4 | input_player1_key_a = "97" 5 | input_player1_key_b = "110" 6 | input_player1_key_b_name = "Gear" 7 | input_player1_key_y = "122" 8 | input_player1_key_y_name = "Break" 9 | input_player1_key_x = "32" 10 | input_player1_key_x_name = "Turbo" 11 | 12 | input_player1_key_start = "32" 13 | 14 | entry_hash_1 = 0xac748c5b # (UK) (1989) (Spain retail version) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Commando - Space Invasion (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "50" 2 | input_player1_key_down = "119" 3 | input_player1_key_left = "57" 4 | input_player1_key_right = "48" 5 | 6 | input_player1_key_a = "122" 7 | input_player1_key_a_name = "Shoot" 8 | input_player1_key_b = "32" 9 | input_player1_key_b_name = "Bomb" 10 | 11 | input_player1_key_start = "115" 12 | 13 | entry_hash_1 = 0x791eae64 # (UK) (1985) [Original] 14 | entry_hash_2 = 0x03b5ab32 # (UK) (1985) 15 | -------------------------------------------------------------------------------- /contrib/remaps/Garfield (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "111" 4 | input_player1_key_right = "112" 5 | 6 | input_player1_key_a = "113" 7 | input_player1_key_a_name = "Jump" 8 | input_player1_key_b = "32" 9 | input_player1_key_b_name = "Kick / Action" 10 | 11 | input_player1_key_start = "113" 12 | 13 | entry_hash_1 = 0x51e77955 # (UK) (1988) (CPM) [Original] 14 | 15 | entry_command = "RUN[quote]GARFIELD" 16 | 17 | entry_map_type = "clean" -------------------------------------------------------------------------------- /contrib/remaps/Rescate Atlantida (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "111" 4 | input_player1_key_right = "112" 5 | 6 | input_player1_key_b = "109" 7 | input_player1_key_y = "49" 8 | input_player1_key_a = "32" 9 | input_player1_key_x = "50" 10 | 11 | input_player1_key_start = "13" 12 | 13 | entry_hash_1 = 0x39e92a63 # (S) (1989) (CPM) [Original] 14 | entry_hash_2 = 0x10712a0c # (UK) (128K) (1988) (Version Basic 1.1) 15 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Chorus.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = chorus 3 | 4 | # Controls the base delay of the chorus (milliseconds). 5 | # chorus_delay_ms = 25.0 6 | # 7 | # Controls the depth of the delay. The delay will vary between delay_ms +/- depth_ms. 8 | # chorus_depth_ms = 1.0 9 | # 10 | # Frequency of LFO which controls delay. 11 | # chorus_lfo_freq = 0.5 12 | # 13 | # Controls dry/wet-ness of effect. 1.0 = full chorus, 0.0 = no chorus. 14 | # chorus_drywet = 0.8 15 | -------------------------------------------------------------------------------- /utils/zlib/inffast.h: -------------------------------------------------------------------------------- 1 | /* inffast.h -- header to use inffast.c 2 | * Copyright (C) 1995-2003, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* WARNING: this file should *not* be used by applications. It is 7 | part of the implementation of the compression library and is 8 | subject to change. Applications should only use zlib.h. 9 | */ 10 | 11 | void ZLIB_INTERNAL inflate_fast OF((z_streamp strm, unsigned start)); 12 | -------------------------------------------------------------------------------- /contrib/remaps/Continental Circus (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "122" 2 | input_player1_key_right = "120" 3 | 4 | input_player1_key_a = "111" 5 | input_player1_key_a_name = "Speed Up" 6 | input_player1_key_b = "32" 7 | input_player1_key_b_name = "Gear" 8 | input_player1_key_y = "107" 9 | input_player1_key_y_name = "Slow Down" 10 | input_player1_key_x = "107" 11 | input_player1_key_y_name = "Slow Down" 12 | 13 | entry_hash_1 = 0x7b2efe8b # (UK) (1989) (UK Retail Release) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Head over Hells (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "257" 2 | input_player1_key_b_name = "Carry" 3 | input_player1_key_y = "261" 4 | input_player1_key_y_name = "Fire" 5 | input_player1_key_x = "264" 6 | input_player1_key_x_name = "Swop" 7 | input_player1_key_l = "32" 8 | input_player1_key_l_name = "Get and Jump" 9 | input_player1_key_r = "32" 10 | input_player1_key_r_name = "Get and Jump" 11 | input_player1_key_start = "13" 12 | 13 | entry_hash_1 = 0xc613efa0 # (UK) (1986) [Original] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Sir Fred (1986).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "109" 8 | input_player1_key_a_name = "Use Object" 9 | input_player1_key_b = "122" 10 | input_player1_key_b_name = "Take/Select Object" 11 | 12 | 13 | input_player1_key_start = "52" 14 | 15 | entry_map_type = "clean" 16 | 17 | entry_hash_1 = 0x92345cde # (S) (1986) [Mister Chip] [Original] 18 | -------------------------------------------------------------------------------- /libretro-common/include/libchdr/coretypes.h: -------------------------------------------------------------------------------- 1 | #ifndef __CORETYPES_H__ 2 | #define __CORETYPES_H__ 3 | 4 | #include 5 | #include 6 | #include 7 | 8 | typedef uint64_t UINT64; 9 | #ifndef OSD_CPU_H 10 | typedef uint32_t UINT32; 11 | typedef uint16_t UINT16; 12 | typedef uint8_t UINT8; 13 | #endif 14 | 15 | typedef int64_t INT64; 16 | #ifndef OSD_CPU_H 17 | typedef int32_t INT32; 18 | typedef int16_t INT16; 19 | typedef int8_t INT8; 20 | #endif 21 | 22 | #endif 23 | -------------------------------------------------------------------------------- /contrib/remaps/Amsoft Loader (1985).rmp: -------------------------------------------------------------------------------- 1 | 2 | entry_hash_1 = 0xeebfb943 # Raid (UK) (1985) [Amsoft] [Original] 3 | entry_hash_2 = 0xf2a3ca3e # Sorcery+ (G) (1985) [Amsoft] [Original] 4 | entry_hash_3 = 0xe0111415 # Sorcery+ (F) (1985) [Amsoft] [Original] 5 | entry_hash_4 = 0x50f59666 # Assault On Port Stanley (UK) (1985) [Original] 6 | entry_hash_5 = 0xb49849a5 # Glen Hoddle Soccer (UK) (1985) [Original] 7 | entry_hash_6 = 0xc48122b1 # Tombstowne (UK) (1986) [Original] 8 | 9 | entry_command = "RUN[quote]DISC" 10 | -------------------------------------------------------------------------------- /contrib/remaps/Mortadelo y Filemon II (1989).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | input_player1_key_x = "49" 12 | input_player1_key_x_name = "1" 13 | input_player1_key_y = "50" 14 | input_player1_key_y_name = "2" 15 | 16 | 17 | entry_hash_1 = 0x0eeae24a # (S) (1989) [Original] 18 | -------------------------------------------------------------------------------- /contrib/remaps/Space Moves (2020).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Fire" 9 | 10 | input_player1_key_start = "51" 11 | 12 | input_player1_key_x = "49" 13 | input_player1_key_x_name = "Phase 1" 14 | input_player1_key_y = "50" 15 | input_player1_key_y_name = "Phase 2" 16 | 17 | 18 | entry_hash_1 = 0x49586e15 # (2020) [Original] 19 | -------------------------------------------------------------------------------- /contrib/remaps/AMC - Astro Marine Corps.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "111" 4 | input_player1_key_right = "112" 5 | 6 | input_player1_key_a = "109" 7 | input_player1_key_b = "32" 8 | input_player1_key_x = "113" 9 | input_player1_key_y = "113" 10 | 11 | input_player1_key_start = "49" 12 | 13 | entry_map_type = "clean" 14 | 15 | entry_hash_1 = 0xbee977b4 # (S) (1989) (CPM) [Original] 16 | entry_hash_2 = 0x8b94c44c # (UK) (1989) (CPM) [Original] 17 | -------------------------------------------------------------------------------- /contrib/remaps/Legend of Steel (2018).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "114" 8 | input_player1_key_start_name = "Restart" 9 | 10 | input_player1_key_a = "32" 11 | input_player1_key_a_name = "Fire" 12 | 13 | input_player1_key_b = "99" 14 | input_player1_key_b_name = "Checkpoint" 15 | 16 | 17 | entry_map_type = "clean" 18 | 19 | entry_hash_1 = 0x56701a62 # (2018) 20 | -------------------------------------------------------------------------------- /contrib/remaps/Phantis (1989).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Fire" 9 | 10 | input_player1_key_x = "50" 11 | input_player1_key_x_name = "Second Stage" 12 | input_player1_key_y = "49" 13 | input_player1_key_y_name = "First Stage" 14 | 15 | input_player1_key_start = "101" 16 | 17 | entry_hash_1 = 0xa60eba03 # (S) (1987) (CPM) [Original] 18 | -------------------------------------------------------------------------------- /contrib/remaps/Roland In The Caves - Pulga (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "273" 2 | input_player1_key_down = "274" 3 | input_player1_key_left = "276" 4 | input_player1_key_right = "275" 5 | 6 | input_player1_key_a = "122" 7 | input_player1_key_a_name = "Jump Left" 8 | input_player1_key_b = "96" 9 | input_player1_key_b = "Jump Right" 10 | 11 | input_player1_key_start = "103" 12 | input_player1_key_select = "97" 13 | 14 | entry_hash_1 = 0x371eaac1 # (UK) (1984) [Original] 15 | entry_hash_2 = 0xf81c4337 # (S) (1984) 16 | -------------------------------------------------------------------------------- /contrib/remaps/Tuareg (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | 12 | input_player1_key_x = "101" 13 | input_player1_key_x_name = "Buy" 14 | input_player1_key_y = "53" 15 | input_player1_key_y_name = "Choose" 16 | 17 | entry_hash_1 = 0x5665d718 # (S) (1988) (Version Basic 1.1) [Original] 18 | -------------------------------------------------------------------------------- /contrib/remaps/3D Grand Prix (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "33" 2 | input_player1_key_down = "33" 3 | input_player1_key_a = "39" 4 | input_player1_key_a_name = "Accelerate" 5 | input_player1_key_b = "47" 6 | input_player1_key_b_name = "Break" 7 | input_player1_key_y = "32" 8 | input_player1_key_y_name = "Gear" 9 | input_player1_key_x = "32" 10 | input_player1_key_x_name = "Gear" 11 | 12 | input_player1_key_start = "32" 13 | 14 | entry_hash_1 = 0xe1e61287 # (UK) (1986) [Exopal] [Original] 15 | 16 | entry_map_type = "keep" 17 | -------------------------------------------------------------------------------- /contrib/remaps/Way Of The Exploding Fist (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_select = "301" 2 | input_player1_key_select_name = "Change Players" 3 | input_player1_key_x = "9" 4 | input_player1_key_x_name = "Change Control" 5 | 6 | entry_hash_1 = 0x6fda459c # (UK) (1985) (v1) [Tape Conversion] 7 | 8 | # Player 2 9 | # input_player2_key_up = "261" 10 | # input_player2_key_down = "266" 11 | # input_player2_key_left = "257" 12 | # input_player2_key_right = "259" 13 | # 14 | # input_player2_key_a = "305" 15 | # input_player2_key_b = "266" 16 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/IIR.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = iir 3 | 4 | # Defaults. 5 | #iir_frequency = 1024.0 6 | #iir_quality = 0.707 7 | #iir_gain = 0.0 8 | #iir_type = LPF 9 | 10 | # Filter types: 11 | # LPF: Low-pass 12 | # HPF: High-pass 13 | # BPCSGF: Band-pass #1 14 | # BPZPGF: Band-pass #2 15 | # APF: Allpass 16 | # NOTCH: Notch filter 17 | # RIAA_phono: RIAA record/tape deemphasis 18 | # PEQ: peaking band EQ 19 | # BBOOST: Bassboost 20 | # LSH: Low-shelf 21 | # HSH: High-shelf 22 | # RIAA_CD: CD de-emphasis 23 | -------------------------------------------------------------------------------- /contrib/remaps/After The War (1989).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Punch" 11 | input_player1_key_b = "307" 12 | input_player1_key_b_name = "Kick" 13 | 14 | entry_map_type = "clean" 15 | 16 | entry_hash_1 = 0x8b94c44c # (S) (1989) (CPM) [Original] 17 | entry_hash_2 = 0x62d17d76 # (UK) (1989) (CPM) [Original] 18 | -------------------------------------------------------------------------------- /contrib/remaps/Ghostbusters (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "13" 2 | input_player1_key_start_name = "Return / Confirm" 3 | input_player1_key_b = "101" 4 | input_player1_key_b_name = "Key E" 5 | input_player1_key_y = "49" 6 | input_player1_key_y_name = "Key 1" 7 | input_player1_key_x = "50" 8 | input_player1_key_x_name = "Key 2" 9 | input_player1_key_select = "51" 10 | input_player1_key_select_name = "Key 3" 11 | 12 | entry_hash_1 = 0xc8149ef6 # (UK) (1985) [Original - Multiload] 13 | entry_hash_2 = 0xe71162a4 # (UK) (1985) [v2] 14 | -------------------------------------------------------------------------------- /contrib/remaps/Tapper (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "111" 2 | input_player1_key_down = "107" 3 | input_player1_key_left = "122" 4 | input_player1_key_right = "120" 5 | 6 | input_player1_key_a = "112" 7 | input_player1_key_a_name = "Fire" 8 | 9 | input_player1_key_x = "101" 10 | input_player1_key_x_name = "Menu: Expert" 11 | input_player1_key_y = "97" 12 | input_player1_key_y_name = "Menu: Arcade" 13 | 14 | input_player1_key_start = "115" 15 | 16 | entry_map_type = "clean" 17 | 18 | entry_hash_1 = 0xb699edb3 # (UK) (1986) 19 | -------------------------------------------------------------------------------- /contrib/remaps/Beach Volley (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "105" 2 | input_player1_key_down = "107" 3 | input_player1_key_left = "106" 4 | input_player1_key_right = "108" 5 | 6 | input_player1_key_a = "112" 7 | 8 | input_player1_key_start = "112" 9 | 10 | entry_hash_1 = 0xb25430db # (UK) (1989) (UK retail version) [Original] 11 | 12 | # Player 2 13 | # input_player2_key_up = "101" 14 | # input_player2_key_down = "100" 15 | # input_player2_key_left = "115" 16 | # input_player2_key_right = "102" 17 | # input_player2_key_a = "113" 18 | -------------------------------------------------------------------------------- /contrib/remaps/Robocop (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_left = "107" 4 | input_player1_key_right = "108" 5 | input_player1_key_a = "120" 6 | input_player1_key_b = "32" 7 | 8 | input_player1_key_start = "49" 9 | 10 | entry_hash_1 = b6017864 # (UK) (1989) (Spain retail version) [Original] 11 | entry_hash_2 = da1142c4 # (UK) (1989) (v2) (French retail version) (CPM) [Original] 12 | entry_hash_3 = f70eee66 # (UK) (1989) (French retail version) (CPM) [Original] (Weak Sectors) 13 | -------------------------------------------------------------------------------- /contrib/remaps/Turbo Esprit (1986).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "115" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "106" 5 | input_player1_key_right = "108" 6 | 7 | input_player1_key_start = "53" 8 | 9 | input_player1_key_a = "107" 10 | input_player1_key_a_name = "Fire" 11 | input_player1_key_b = "109" 12 | input_player1_key_b_name = "Map" 13 | input_player1_key_x = "49" 14 | input_player1_key_x_name = "1" 15 | 16 | entry_hash_1 = 0x37c07361 # (UK) (1986) [Original] 17 | entry_hash_2 = 0x8a357ad3 # (S) (1986) 18 | -------------------------------------------------------------------------------- /contrib/remaps/Molecule Man (1986).rmp: -------------------------------------------------------------------------------- 1 | # AZNM 2 | input_player1_key_up = "97" 3 | input_player1_key_down = "122" 4 | input_player1_key_left = "110" 5 | input_player1_key_right = "109" 6 | 7 | input_player1_key_start = "32" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Pick Up" 11 | input_player1_key_b = "98" 12 | input_player1_key_b_name = "Buy" 13 | input_player1_key_x = "120" 14 | input_player1_key_x_name = "Throw Bomb" 15 | 16 | 17 | entry_hash_1 = 0x532f7930 # (UK) (1986) 18 | 19 | entry_command = "RUN[quote]MOLECULE" 20 | -------------------------------------------------------------------------------- /contrib/remaps/Jack The Nipper II (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "111" 2 | input_player1_key_down = "107" 3 | input_player1_key_down_name = "Down/Take" 4 | input_player1_key_left = "122" 5 | input_player1_key_right = "120" 6 | 7 | input_player1_key_start = "32" 8 | input_player1_key_select = "109" 9 | input_player1_key_select_name = "Switch Music" 10 | 11 | input_player1_key_a = "48" 12 | input_player1_key_a_name = "Shoot" 13 | input_player1_key_b = "111" 14 | input_player1_key_b_name = "Jump" 15 | 16 | entry_hash_1 = 0x2bec9bd # (UK) (1987) (CPM) [Original] 17 | -------------------------------------------------------------------------------- /contrib/remaps/Super Stuntman (1988).rmp: -------------------------------------------------------------------------------- 1 | # OP 2 | input_player1_key_left = "111" 3 | input_player1_key_right = "112" 4 | 5 | input_player1_key_a = "113" 6 | input_player1_key_a_name = "Accelerate" 7 | input_player1_key_b = "97" 8 | input_player1_key_b_name = "Brake" 9 | 10 | input_player1_key_x = "32" 11 | input_player1_key_x_name = "Fire" 12 | input_player1_key_y = "32" 13 | input_player1_key_y_name = "Fire" 14 | 15 | input_player1_key_start = "49" 16 | input_player1_key_select = "42" 17 | 18 | entry_hash_1 = 0x1115c8c8 # (UK) (1987) 19 | 20 | entry_map_type = "clean" -------------------------------------------------------------------------------- /contrib/remaps/Victory Road (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Fire" 9 | input_player1_key_b = "122" 10 | input_player1_key_b_name = "Toggle" 11 | 12 | input_player1_key_y = "50" 13 | input_player1_key_y_name = "Press 2" 14 | 15 | input_player1_key_start = "49" 16 | 17 | entry_map_type = "clean" 18 | 19 | entry_hash_1 = 0xaf4b1161 # (UK) (1988) (CPM) [Original] (Weak Sectors) 20 | -------------------------------------------------------------------------------- /contrib/remaps/Fernando Martin - Basket Master (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | input_player1_key_b = "51" 3 | input_player1_key_x = "32" 4 | 5 | # Player 2 6 | input_player2_key_up = "263" # KP 7 7 | input_player2_key_down = "260" # KP 4 8 | input_player2_key_left = "258" # KP 2 9 | input_player2_key_right = "259" # KP 3 10 | input_player2_key_a = "256" # KP 0 11 | 12 | input_player2_key_start = "50" 13 | 14 | 15 | entry_hash_1 = 0x708351db # (S) (1987) [Original] - Fernando Martin 16 | entry_hash_2 = 0x471c5eac # (UK) (1987) [Original] - Basket Master 17 | -------------------------------------------------------------------------------- /contrib/remaps/Myth (1989).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "119" 2 | input_player1_key_left = "113" 3 | input_player1_key_a = "111" 4 | input_player1_key_a_name = "Action / Combo" 5 | input_player1_key_b = "106" 6 | input_player1_key_b_name = "Small Jump / Kick" 7 | input_player1_key_y = "105" 8 | input_player1_key_x = "105" 9 | input_player1_key_x_name = "Long Jump / Punch" 10 | 11 | input_player1_key_start = "32" 12 | input_player1_key_start_name = "Start / Select Icon" 13 | 14 | entry_hash_1 = 0x4d8464d3 # (UK) (1987) (CPM) [Original] 15 | 16 | entry_map_type = "clean" 17 | -------------------------------------------------------------------------------- /contrib/remaps/Spitfire 40 (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_b = "98" 2 | input_player1_key_b_name = "Brakes" 3 | 4 | input_player1_key_x = "113" 5 | input_player1_key_x_name = "Throttle Increase" 6 | input_player1_key_y = "119" 7 | input_player1_key_y_name = "Throttle Decrease" 8 | 9 | input_player1_key_start = "32" 10 | input_player1_key_start_name = "Cockpick View" 11 | input_player1_key_select = "109" 12 | input_player1_key_select_name = "Map" 13 | 14 | 15 | entry_hash_1 = 0xdf6b3ee6 # (UK) (1985) [Mirrorsoft] [Original] 16 | 17 | entry_command = "RUN[quote]SPITFIRE" 18 | -------------------------------------------------------------------------------- /contrib/remaps/Yie Ar Kung-Fu.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "264" 2 | input_player1_key_down = "258" 3 | input_player1_key_left = "260" 4 | input_player1_key_right = "262" 5 | 6 | input_player1_key_a = "256" 7 | input_player1_key_a_name = "Attack" 8 | input_player1_key_b = "256" 9 | input_player1_key_b_name = "Attack" 10 | input_player1_key_x = "265" 11 | input_player1_key_x_name = "Diagonal Jump" 12 | input_player1_key_y = "263" 13 | input_player1_key_y_name = "Diagonal Jump" 14 | 15 | input_player1_key_start = "49" 16 | 17 | entry_hash_1 = 0x651cd158 # (UK) (1985) [Original] -------------------------------------------------------------------------------- /libretro/db/database.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #define DB_CLEAN 0xfff 5 | #define DB_KEEP 0xffff 6 | #define COMMAND_EMPTY 0 7 | 8 | typedef struct { 9 | int btn_map[MAX_BUTTONS]; 10 | int btn_name[MAX_BUTTONS]; 11 | } t_player_btn; 12 | 13 | typedef struct { 14 | uint32_t hash_list[16]; 15 | t_player_btn player_1; 16 | t_player_btn player_2; 17 | int loader_command; 18 | } t_file_entry; 19 | 20 | bool db_info(const uint32_t hash); 21 | bool db_fail(const uint32_t hash); 22 | bool db_clean(const uint32_t hash); 23 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Panning.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = panning 3 | 4 | # Gains are linear. 5 | 6 | # The default. Left and right channels map to each other. 7 | panning_left_mix = "1.0 0.0" 8 | panning_right_mix = "0.0 1.0" 9 | 10 | # Some examples: 11 | # 12 | # Mono: 13 | # panning_left_mix = "0.5 0.5" 14 | # panning_right_mix = "0.5 0.5" 15 | 16 | # Swap left and right channels: 17 | # panning_left_mix = "0.0 1.0" 18 | # panning_right_mix = "1.0 0.0" 19 | # 20 | # Mono on one speaker: 21 | # panning_left_mix = "0.5 0.5" 22 | # panning_right_mix = "0.0 0.0" 23 | -------------------------------------------------------------------------------- /contrib/remaps/Capitan Trueno (1989).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | input_player1_key_b = "53" 12 | input_player1_key_b_name = "Captain" 13 | input_player1_key_x = "54" 14 | input_player1_key_x_name = "Crispin" 15 | input_player1_key_y = "55" 16 | input_player1_key_y_name = "Goliat" 17 | 18 | entry_hash_1 = 0x0823ac51 # (S) (1989) (CPM) [Original] 19 | -------------------------------------------------------------------------------- /contrib/remaps/Galactic Tomb (2018).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "273" 10 | input_player1_key_a_name = "Jump" 11 | input_player1_key_b = "122" 12 | input_player1_key_b_name = "Fire" 13 | input_player1_key_x = "121" 14 | input_player1_key_x_name = "Fire 2" 15 | input_player1_key_y = "115" 16 | input_player1_key_y_name = "Music / Sfx" 17 | 18 | entry_hash_1 = 0xfe13c50 # (S) (2018) v1.4 [Original] 19 | -------------------------------------------------------------------------------- /contrib/remaps/Savage (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Fire" 9 | 10 | input_player1_key_x = "50" 11 | input_player1_key_x_name = "Press 2" 12 | input_player1_key_y = "49" 13 | input_player1_key_y_name = "Press 1" 14 | 15 | entry_map_type = "clean" 16 | 17 | entry_hash_1 = 0xca6ffd7a # (UK) (face a - lvl 1) (1988) [Original] 18 | entry_hash_2 = 0xae64ea1d # (UK) (face b - lvl 2,3) (1988) [Original] 19 | -------------------------------------------------------------------------------- /contrib/remaps/Espada Sagrada (1990).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "48" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Attack" 11 | input_player1_key_b = "98" 12 | input_player1_key_b_name = "Get/Drop Object" 13 | input_player1_key_x = "120" 14 | input_player1_key_x_name = "Object Left" 15 | input_player1_key_y = "109" 16 | input_player1_key_y_name = "Object Right" 17 | 18 | entry_hash_1 = 0x5795493d # (S) (1990) [Original] 19 | -------------------------------------------------------------------------------- /libretro-common/include/libchdr/minmax.h: -------------------------------------------------------------------------------- 1 | /* license:BSD-3-Clause 2 | * copyright-holders:Aaron Giles 3 | *************************************************************************** 4 | 5 | minmax.h 6 | 7 | ***************************************************************************/ 8 | 9 | #pragma once 10 | 11 | #ifndef __MINMAX_H__ 12 | #define __MINMAX_H__ 13 | 14 | #if defined(RARCH_INTERNAL) || defined(__LIBRETRO__) 15 | #include 16 | #else 17 | #define MAX(x, y) (((x) > (y)) ? (x) : (y)) 18 | #define MIN(x, y) ((x) < (y) ? (x) : (y)) 19 | #endif 20 | 21 | #endif 22 | -------------------------------------------------------------------------------- /contrib/remaps/Gunfright (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "51" 2 | input_player1_key_x = "118" 3 | 4 | input_player1_key_a = "113" 5 | input_player1_key_a_name = "Move forward" 6 | input_player1_key_b = "32" 7 | input_player1_key_b_name = "Shoot" 8 | input_player1_key_left = "111" 9 | input_player1_key_left_name = "Turn Counterclockwise" 10 | input_player1_key_right = "112" 11 | input_player1_key_right_name = "Turn Clockwise" 12 | 13 | input_player1_key_up = "113" 14 | input_player1_key_down = "97" 15 | 16 | entry_hash_1 = 0xfe56bf61 # (UK) (1985) [Tape Conversion] 17 | 18 | entry_map_type = "clean" 19 | -------------------------------------------------------------------------------- /contrib/remaps/Powerplay - org (1986).rmp: -------------------------------------------------------------------------------- 1 | 2 | input_player1_key_b = "13" 3 | input_player1_key_b_name = "Return" 4 | 5 | input_player1_key_x = "27" 6 | input_player1_key_x_name = "Esc" 7 | input_player1_key_y = "32" 8 | input_player1_key_y_name = "Space" 9 | 10 | input_player1_key_start = "50" 11 | input_player1_key_select = "51" 12 | 13 | entry_hash_1 = 0x3ea9bb91 # (S) (1986) [Original] 14 | 15 | # [enter] => \n 16 | # [quote] => " 17 | # [wait] => wait 5 seconds 18 | entry_command = "RUN[quote]ARCANA[enter][wait][wait][wait][wait][wait][wait][wait][wait][wait][wait][wait][wait][wait]L[wait]QUIZ1[end]" -------------------------------------------------------------------------------- /contrib/remaps/Thanatos (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "97" 2 | input_player1_key_down = "122" 3 | input_player1_key_right = "109" 4 | input_player1_key_left = "110" 5 | input_player1_key_a = "32" 6 | input_player1_key_a_name = "Flame" 7 | input_player1_key_start = "52" 8 | 9 | entry_map_type = "clean" 10 | 11 | entry_hash_1 = 827e83ac # (UK) (1986) (UK retail version) [Ubi Soft] [Original] 12 | entry_hash_2 = 8d64a322 # (UK) (1986) [Durell Software] [Original] 13 | entry_hash_3 = f9fce391 # (UK) (1986) [Durell Software] (v2) [Original] 14 | entry_hash_4 = 59d6aef1 # (UK) (1986) (Spain retail version) [Original] 15 | -------------------------------------------------------------------------------- /contrib/remaps/Tyrann - es (1985).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_right = "275" 5 | input_player1_key_left = "276" 6 | 7 | input_player1_key_a = "308" 8 | input_player1_key_a_name = "Open Door" 9 | input_player1_key_b = "99" 10 | input_player1_key_b_name = "Camp" 11 | 12 | input_player1_key_x = "110" 13 | input_player1_key_x_name = "No" 14 | input_player1_key_y = "115" 15 | input_player1_key_y_name = "Si" 16 | 17 | input_player1_key_start = "32" 18 | 19 | entry_hash_1 = 0x9ba80f9d # (S) (1985) (Hack) 20 | 21 | entry_command = "RUN[quote]TYRANN" 22 | -------------------------------------------------------------------------------- /contrib/remaps/Game Over (1987).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "51" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Shoot" 11 | input_player1_key_b = "307" 12 | input_player1_key_b_name = "Throw Bombs" 13 | input_player1_key_x = "49" 14 | input_player1_key_x_name = "Key 1" 15 | input_player1_key_y = "50" 16 | input_player1_key_y_name = "Key 2" 17 | 18 | entry_hash_1 = 0x4d723f39 # (S) (1986) [Original] 19 | entry_hash_2 = 0x8d8e3122 # (UK) (1987) [Original] 20 | -------------------------------------------------------------------------------- /external/cmocka/cmocka-update.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # put here the version you want to use 4 | VERSION=cmocka-1.1.5 5 | 6 | echo "*** cmocka git update ($VERSION)" 7 | 8 | # get the latest revision from repository. 9 | git clone https://git.cryptomilk.org/projects/cmocka.git cmocka.git 10 | if [ -d cmocka.git ] 11 | then 12 | rm -rf cmocka-lib 13 | cd cmocka.git 14 | git checkout $VERSION 15 | mkdir ../cmocka-lib 16 | cp -r include src AUTHORS COPYING README.md ../cmocka-lib/ 17 | cd .. 18 | rm -rf cmocka.git 19 | 20 | echo "cmocka: ready." 21 | else 22 | echo "Did you install Git?" 23 | fi 24 | -------------------------------------------------------------------------------- /contrib/remaps/Batty (1987).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "97" 2 | input_player1_key_right = "115" 3 | input_player1_key_start = "115" 4 | input_player1_key_start_name = "Start" 5 | input_player1_key_a = "13" 6 | input_player1_key_a_name = "Release / Fire" 7 | 8 | 9 | input_player2_key_right = "275" # CURSOR RIGHT 10 | input_player2_key_left = "276" # CURSOR LEFT 11 | input_player2_key_a = "32" # SPACE 12 | input_player2_key_a_name = "Release / Fire" 13 | 14 | input_player2_key_start = "50" 15 | input_player2_key_start_name = "Select Two Players" 16 | 17 | entry_map_type = "clean" 18 | 19 | entry_hash_1 = 0x9beae974 # (UK) (1987) 20 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/ChipTuneEnhance.dsp: -------------------------------------------------------------------------------- 1 | filters = 4 2 | filter0 = eq 3 | filter1 = reverb 4 | filter2 = iir 5 | filter3 = panning 6 | 7 | eq_frequencies = "32 64 125 250 500 1000 2000 4000 8000 16000 20000" 8 | eq_gains = "6 9 12 7 6 5 7 9 11 6 0" 9 | 10 | # Reverb - slight reverb 11 | reverb_drytime = 0.5 12 | reverb_wettime = 0.15 13 | reverb_damping = 0.8 14 | reverb_roomwidth = 0.25 15 | reverb_roomsize = 0.25 16 | 17 | # IIR - filters out some harsh sounds on the upper end 18 | iir_type = RIAA_CD 19 | 20 | # Panning - cut the volume a bit 21 | panning_left_mix = "0.75 0.0" 22 | panning_right_mix = "0.0 0.75" 23 | -------------------------------------------------------------------------------- /contrib/remaps/Army Moves (1986).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "51" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Missile Air" 11 | input_player1_key_b = "307" 12 | input_player1_key_b_name = "Missile Ground" 13 | input_player1_key_x = "49" 14 | input_player1_key_x_name = "Key 1" 15 | input_player1_key_y = "50" 16 | input_player1_key_y_name = "Key 2" 17 | 18 | entry_hash_1 = 0xe49fc694 # (S) (1986) [Original] 19 | entry_hash_2 = 0x3db8fc89 # (UK) (1986) [Original] 20 | -------------------------------------------------------------------------------- /contrib/remaps/Navy Moves (1988).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "51" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | input_player1_key_b = "109" 12 | input_player1_key_b_name = "Change Weapon" 13 | input_player1_key_x = "49" 14 | input_player1_key_x_name = "Key 1" 15 | input_player1_key_y = "50" 16 | input_player1_key_y_name = "Key 2" 17 | 18 | entry_hash_1 = 0xacf62400 # (S) (1988) (CPM) (Hack/Fix) 19 | entry_hash_2 = 0x9299697c # (UK) (1988) (CPM) [Original] 20 | -------------------------------------------------------------------------------- /contrib/remaps/Satan (1989).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_a = "32" 8 | input_player1_key_a_name = "Fire" 9 | 10 | input_player1_key_x = "50" 11 | input_player1_key_x_name = "Second Stage" 12 | input_player1_key_y = "49" 13 | input_player1_key_y_name = "First Stage" 14 | 15 | input_player1_key_start = "49" 16 | input_player1_key_select = "50" 17 | 18 | entry_map_type = "clean" 19 | 20 | entry_hash_1 = 0xd66de504 # (S) (1989) (CPM) [Original] 21 | entry_hash_2 = 0xae64ea1d # (UK) (1989) (CPM) [Original] 22 | -------------------------------------------------------------------------------- /contrib/remaps/Alien 8 (1985).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "120" 2 | input_player1_key_right_name = "Turn Clockwise" 3 | input_player1_key_left = "122" 4 | input_player1_key_left_name = "Turn Counterclockwise" 5 | input_player1_key_a = "97" 6 | input_player1_key_a_name = "Move forward" 7 | input_player1_key_b = "113" 8 | input_player1_key_b_name = "Jump" 9 | input_player1_key_x = "49" 10 | input_player1_key_x_name = "Carry" 11 | input_player1_key_y = "50" 12 | input_player1_key_y_name = "Carry" 13 | input_player1_key_select = "51" 14 | input_player1_key_start = "48" 15 | 16 | entry_map_type = "clean" 17 | 18 | entry_hash_1 = 0x160644e9 # (UK) (1985) [Tape Dump] 19 | -------------------------------------------------------------------------------- /contrib/remaps/Carlos Sainz (1990).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | input_player1_key_select = "50" 9 | 10 | input_player1_key_a = "113" 11 | input_player1_key_a_name = "Speed Up" 12 | input_player1_key_b = "97" 13 | input_player1_key_b_name = "Speed Down" 14 | input_player1_key_x = "32" 15 | input_player1_key_x_name = "Hand Brake" 16 | input_player1_key_y = "32" 17 | input_player1_key_y_name = "Hand Brake" 18 | 19 | entry_hash_1 = 0x1913117d # (S) (1990) (CPM) [Original] 20 | 21 | entry_map_type = "clean" 22 | -------------------------------------------------------------------------------- /contrib/remaps/Knight Lore (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_right = "120" 2 | input_player1_key_right_name = "Turn Clockwise" 3 | input_player1_key_left = "122" 4 | input_player1_key_left_name = "Turn Counterclockwise" 5 | input_player1_key_a = "97" 6 | input_player1_key_a_name = "Move forward" 7 | input_player1_key_b = "113" 8 | input_player1_key_b_name = "Jump" 9 | input_player1_key_x = "49" 10 | input_player1_key_x_name = "Carry" 11 | input_player1_key_y = "50" 12 | input_player1_key_y_name = "Carry" 13 | input_player1_key_select = "51" 14 | input_player1_key_start = "48" 15 | 16 | entry_map_type = "clean" 17 | 18 | entry_hash_1 = 0xa2d5c9db # (UK) (1984) [Maxit TAPE DUMP] -------------------------------------------------------------------------------- /jni/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | CORE_DIR := $(LOCAL_PATH)/.. 4 | 5 | include $(CORE_DIR)/Makefile.common 6 | 7 | COREFLAGS := -D__LIBRETRO__ -DFRONTEND_SUPPORTS_RGB565 -DANDROID -DINLINE="inline" $(INCFLAGS) 8 | 9 | GIT_VERSION ?= " $(shell git rev-parse --short HEAD || echo unknown)" 10 | ifneq ($(GIT_VERSION)," unknown") 11 | COREFLAGS += -DGIT_VERSION=\"$(GIT_VERSION)\" 12 | endif 13 | 14 | include $(CLEAR_VARS) 15 | LOCAL_MODULE := retro 16 | LOCAL_SRC_FILES := $(SOURCES_C) 17 | LOCAL_CFLAGS := $(COREFLAGS) 18 | LOCAL_LDFLAGS := -Wl,-version-script=$(CORE_DIR)/link.T 19 | LOCAL_LDLIBS := -llog 20 | include $(BUILD_SHARED_LIBRARY) 21 | -------------------------------------------------------------------------------- /contrib/remaps/Jack The Nipper I (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "111" 2 | input_player1_key_down = "107" 3 | input_player1_key_left = "122" 4 | input_player1_key_right = "120" 5 | 6 | input_player1_key_start = "32" 7 | input_player1_key_select = "109" 8 | input_player1_key_select_name = "Switch Music" 9 | 10 | input_player1_key_a = "48" 11 | input_player1_key_a_name = "Shoot" 12 | input_player1_key_b = "13" 13 | input_player1_key_b_name = "Open Door" 14 | input_player1_key_x = "49" 15 | input_player1_key_x_name = "Take Slot 1" 16 | input_player1_key_y = "50" 17 | input_player1_key_y_name = "Take Slot 2" 18 | 19 | entry_hash_1 = 0xb06159a2 # (UK) (1986) (CPM) [Original] 20 | -------------------------------------------------------------------------------- /contrib/remaps/Tyrann (1985).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_right = "275" 5 | input_player1_key_left = "276" 6 | 7 | input_player1_key_a = "308" 8 | input_player1_key_a_name = "Open Door" 9 | input_player1_key_b = "99" 10 | input_player1_key_b_name = "Camp / Rest" 11 | 12 | input_player1_key_x = "110" 13 | input_player1_key_x_name = "No" 14 | input_player1_key_y = "111" 15 | input_player1_key_y_name = "Oui / Yes" 16 | 17 | input_player1_key_start = "13" 18 | input_player1_key_select = "32" 19 | 20 | entry_hash_1 = 0x1a6f0fff # (F) (2 faces) (1986) [Original] 21 | 22 | entry_command = "RUN[quote]TYRANN" 23 | -------------------------------------------------------------------------------- /contrib/remaps/Harrier Attack (1984).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "266" 2 | input_player1_key_down = "271" 3 | input_player1_key_left = "122" 4 | input_player1_key_left_name = "Slow" 5 | input_player1_key_right = "120" 6 | input_player1_key_right_name = "Fast" 7 | input_player1_key_start = "50" 8 | input_player1_key_start_name = "Key 2" 9 | input_player1_key_select = "51" 10 | input_player1_key_select_name = "Key 3" 11 | input_player1_key_a = "256" 12 | input_player1_key_a_name = "Fire Rocket" 13 | input_player1_key_b = "32" 14 | input_player1_key_b_name = "Drop Bomb" 15 | input_player1_key_y = "13" 16 | input_player1_key_y_name = "Return / Confirm" 17 | 18 | entry_hash_1 = 0x762a657 # (UK) (1984) [Original] 19 | -------------------------------------------------------------------------------- /contrib/remaps/Teenage Mutant Hero Turtles (1990).rmp: -------------------------------------------------------------------------------- 1 | # QAOP 2 | input_player1_key_up = "113" 3 | input_player1_key_down = "97" 4 | input_player1_key_left = "111" 5 | input_player1_key_right = "112" 6 | 7 | input_player1_key_start = "49" 8 | 9 | input_player1_key_a = "32" 10 | input_player1_key_a_name = "Fire" 11 | input_player1_key_b = "115" 12 | input_player1_key_b_name = "Select Weapon" 13 | input_player1_key_x = "13" 14 | input_player1_key_x_name = "Special Features" 15 | input_player1_key_y = "303" 16 | input_player1_key_y_name = "Enter Wagon" 17 | 18 | entry_hash_1 = 0xca4f0b5 # (UK) (1990) (UK retail version) [Original - Codes] 19 | entry_hash_2 = 0x8dd0cf27 # (UK) (1990) (UK retail version) [Clean Crack] 20 | -------------------------------------------------------------------------------- /contrib/remaps/Chibi Akuma's Episode 1 Invasion (v1.666).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_right = "275" 5 | input_player1_key_left = "276" 6 | 7 | input_player1_key_b = "105" 8 | input_player1_key_b_name = "Fire Left" 9 | input_player1_key_a = "111" 10 | input_player1_key_a_name = "Fire Right" 11 | input_player1_key_y = "13" 12 | input_player1_key_y_name = "Bomb" 13 | input_player1_key_select = "112" 14 | input_player1_key_select_name = "Pause" 15 | 16 | entry_map_type = "clean" 17 | 18 | entry_hash_1 = 0xd851fde0 # (UK) (128K) (2 faces) (2016) [CPC CPC+] (site download) 19 | entry_hash_2 = 0x5c3cfc2c # (UK) (128K) (2 faces) (2016) [CPC CPC+] (site download) 20 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/Echo.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = echo 3 | 4 | # Somewhat fancy Echo filter. Can take any number of echo channels with varying delays (ms) and feedback factors. 5 | # Echo output from all channels can be fed back into each other to create a somewhat reverb-like effect if desired. 6 | 7 | # Defaults, 200 ms delay echo with feedback: 8 | # Delay in ms. Takes an array with multiple channels. 9 | # echo_delay = "200" 10 | # Feedback factor for echo. 11 | # echo_feedback = "0.5" 12 | # Overall echo amplification. If too high, the echo becomes unstable due to feedback. 13 | # echo_amp = "0.2" 14 | 15 | # Reverby preset. 16 | # echo_delay = " 60 80 120 172 200 320 380" 17 | # echo_feedback = "0.5 0.5 0.4 0.3 0.5 0.3 0.2" 18 | 19 | # echo_amp = "0.12" 20 | -------------------------------------------------------------------------------- /utils/zlib/gzclose.c: -------------------------------------------------------------------------------- 1 | /* gzclose.c -- zlib gzclose() function 2 | * Copyright (C) 2004, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | #include "gzguts.h" 7 | 8 | /* gzclose() is in a separate file so that it is linked in only if it is used. 9 | That way the other gzclose functions can be used instead to avoid linking in 10 | unneeded compression or decompression routines. */ 11 | int ZEXPORT gzclose(file) 12 | gzFile file; 13 | { 14 | #ifndef NO_GZCOMPRESS 15 | gz_statep state; 16 | 17 | if (file == NULL) 18 | return Z_STREAM_ERROR; 19 | state = (gz_statep)file; 20 | 21 | return state->mode == GZ_READ ? gzclose_r(file) : gzclose_w(file); 22 | #else 23 | return gzclose_r(file); 24 | #endif 25 | } 26 | -------------------------------------------------------------------------------- /libretro-common/crt/string.c: -------------------------------------------------------------------------------- 1 | #ifdef _MSC_VER 2 | #include 3 | #endif 4 | #include 5 | #include 6 | 7 | void *memset(void *dst, int val, size_t count) 8 | { 9 | void *start = dst; 10 | 11 | #if defined(_M_IA64) || defined (_M_AMD64) || defined(_M_ALPHA) || defined (_M_PPC) 12 | extern void RtlFillMemory(void *, size_t count, char); 13 | 14 | RtlFillMemory(dst, count, (char)val); 15 | #else 16 | while (count--) 17 | { 18 | *(char*)dst = (char)val; 19 | dst = (char*)dst + 1; 20 | } 21 | #endif 22 | 23 | return start; 24 | } 25 | 26 | void *memcpy(void *dst, const void *src, size_t len) 27 | { 28 | size_t i; 29 | 30 | for (i = 0; i < len; i++) 31 | ((unsigned char *)dst)[i] = ((unsigned char *)src)[i]; 32 | 33 | return dst; 34 | } 35 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: generic 2 | os: linux 3 | dist: trusty 4 | sudo: required 5 | addons: 6 | apt: 7 | packages: 8 | - g++-7 9 | sources: 10 | - ubuntu-toolchain-r-test 11 | env: 12 | global: 13 | - CORE=cap32 14 | - COMPILER_NAME=gcc CXX=g++-7 CC=gcc-7 15 | matrix: 16 | - PLATFORM=linux_x64 17 | - PLATFORM=3ds 18 | - PLATFORM=wii 19 | before_script: 20 | - pwd 21 | - mkdir -p ~/bin 22 | - ln -s /usr/bin/gcc-7 ~/bin/gcc 23 | - ln -s /usr/bin/g++-7 ~/bin/g++ 24 | - ln -s /usr/bin/cpp-7 ~/bin/cpp 25 | - export PATH=~/bin:$PATH 26 | - ls -l ~/bin 27 | - echo $PATH 28 | - g++-7 --version 29 | - g++ --version 30 | script: 31 | - cd ~/ 32 | - git clone --depth=50 https://github.com/libretro/libretro-super 33 | - cd libretro-super/travis 34 | - ./build.sh 35 | -------------------------------------------------------------------------------- /contrib/remaps/Target Renegade (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "113" 2 | input_player1_key_down = "97" 3 | input_player1_key_right = "108" 4 | input_player1_key_left = "107" 5 | input_player1_key_a = "32" 6 | input_player1_key_a_name = "Fire" 7 | input_player1_key_start = "49" 8 | input_player1_key_start_name = "Start One Player" 9 | input_player1_key_select = "27" 10 | input_player1_key_select_name = "Pause" 11 | 12 | input_player2_key_up = "$200" # JOY UP 13 | input_player2_key_down = "$201" # JOY DOWN 14 | input_player2_key_right = "$202" # JOY RIGHT 15 | input_player2_key_left = "$203" # JOY LEFT 16 | input_player2_key_a = "$204" # JOY FIRE 17 | input_player2_key_a_name = "Fire" 18 | input_player2_key_start = "50" 19 | input_player2_key_start_name = "Start Two Players" 20 | 21 | 22 | entry_hash_1 = 0xe4154a1f # (UK) (1988) (CPM) [Original] (Weak Sectors) 23 | -------------------------------------------------------------------------------- /contrib/remaps/Hero Quest (1991).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_up = "111" 2 | input_player1_key_down = "107" 3 | input_player1_key_left = "122" 4 | input_player1_key_right = "120" 5 | 6 | input_player1_key_start = "32" 7 | 8 | input_player1_key_a = "32" 9 | input_player1_key_a_name = "Action" 10 | input_player1_key_x = "51" 11 | input_player1_key_x_name = "Key 3 / Menu" 12 | input_player1_key_y = "48" 13 | input_player1_key_y_name = "Key 0 / Menu" 14 | 15 | entry_hash_1 = 0xec279622 # (UK) (128K) (1991) (CPM) [Original] 16 | entry_hash_2 = 0x257af370 # (S) (128K) (1991) (CPM) [Original] [Bugs] 17 | entry_hash_3 = 0xafe22434 # (F) (128K) (1991) (CPM) [Original] 18 | entry_hash_4 = 0x386ab47d # Extension - (S) (128K) (1991) (CPM) [Original] 19 | # no bootable 20 | # 0xf1fff06c (UK) (1991) (Extension) [Original] 21 | # 0x52f69491 (F) (1991) (Extension) [Original] 22 | 23 | entry_map_type = "clean" 24 | -------------------------------------------------------------------------------- /contrib/remaps/1943 (1988).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | # input_player1_key_select = "50" # Two Players same time 3 | input_player1_key_b = "303" 4 | input_player1_key_b_name = "Roll Plane" 5 | input_player1_key_y = "13" 6 | input_player1_key_y_name = "Bomb" 7 | input_player1_key_x = "13" 8 | input_player1_key_x_name = "Bomb" 9 | 10 | 11 | input_player2_key_up = "113" # Q 12 | input_player2_key_down = "97" # A 13 | input_player2_key_right = "46" # COMMA 14 | input_player2_key_left = "44" # DOT 15 | input_player2_key_a = "32" # SPACE 16 | input_player2_key_b = "306" # CTRL 17 | input_player2_key_b_name = "Roll Plane" 18 | input_player2_key_y = "9" 19 | input_player2_key_y_name = "Bomb" 20 | input_player2_key_x = "9" 21 | input_player2_key_x_name = "Bomb" 22 | 23 | input_player2_key_start = "50" 24 | input_player2_key_start_name = "Select Two Players" 25 | 26 | entry_hash_1 = 0x8769d0b1 # (UK) (1988) [Original] 27 | -------------------------------------------------------------------------------- /contrib/remaps/Cyrus II (1985).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_right = "275" 5 | input_player1_key_left = "276" 6 | 7 | 8 | input_player1_key_a = "13" 9 | input_player1_key_a_name = "Select / Place" 10 | input_player1_key_b = "98" 11 | input_player1_key_b_name = "Back" 12 | 13 | input_player1_key_x = "27" 14 | input_player1_key_x_name = "2D / 3D" 15 | input_player1_key_y = "105" 16 | input_player1_key_y_name = "Invert Board" 17 | 18 | input_player1_key_start = "32" 19 | input_player1_key_start_name = "Menu" 20 | 21 | input_player1_key_select = "109" 22 | input_player1_key_select_name = "Move First - Black Pieces" 23 | 24 | entry_hash_1 = 0xe894c4e9 # (UK) (1990) [Original] 25 | entry_hash_1 = 0x859433b0 # (F) (1985) [Original] 26 | entry_hash_1 = 0xe480fbec # (G) (1985) [Original] 27 | 28 | # [enter] => \n 29 | # [quote] => " 30 | # [wait] => wait 5 seconds 31 | entry_command = "RUN[quote]DISC" -------------------------------------------------------------------------------- /contrib/remaps/Bubble Bobble 1-2.rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_left = "111" 2 | input_player1_key_right = "112" 3 | input_player1_key_start = "49" 4 | input_player1_key_start_name = "Start One Player" 5 | input_player1_key_a = "113" 6 | input_player1_key_a_name = "Jump" 7 | input_player1_key_b = "32" 8 | input_player1_key_b_name = "Bubble" 9 | input_player1_key_x = "97" 10 | input_player1_key_x_name = "[A]" 11 | 12 | 13 | input_player2_key_down = "$201" # JOY DOWN 14 | input_player2_key_right = "$202" # JOY RIGHT 15 | input_player2_key_left = "$203" # JOY LEFT 16 | input_player2_key_a = "$200" # JOY UP 17 | input_player2_key_a_name = "Jump" 18 | input_player2_key_b = "$204" # JOY FIRE 19 | input_player2_key_b_name = "Bubble" 20 | input_player2_key_x = "98" 21 | input_player2_key_x_name = "[B]" 22 | 23 | input_player2_key_start = "50" 24 | input_player2_key_start_name = "Start Two Players" 25 | 26 | entry_map_type = "clean" 27 | 28 | entry_hash_1 = 95d9f222 # (UK) (1987) [Original] 29 | entry_hash_2 = dc214555 # (UK) (1988) (Hack) 30 | -------------------------------------------------------------------------------- /contrib/remaps/Ikari Warriors (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | input_player1_key_start_name = "Start One Player" 3 | input_player1_key_select = "50" 4 | input_player1_key_select_name = "Joystick 1 Select" 5 | input_player1_key_b = "105" 6 | input_player1_key_b_name = "[I] Toggle" 7 | 8 | input_player2_key_start = "50" 9 | input_player2_key_start_name = "Start Two Players" 10 | input_player2_key_select = "51" 11 | input_player2_key_select_name = "Joystick 2 Select" 12 | input_player2_key_up = "$206" # JOY2 UP [6] 13 | input_player2_key_down = "$207" # JOY2 DOWN [5] 14 | input_player2_key_right = "$208" # JOY2 RIGHT [R] 15 | input_player2_key_left = "$209" # JOY2 LEFT [T] 16 | input_player2_key_a = "$210" # JOY2 FIRE1 [G] 17 | input_player2_key_a_name = "Fire / Bomb" 18 | input_player2_key_b = "107" 19 | input_player2_key_b_name = "[K] Toggle" 20 | 21 | entry_hash_1 = 36d943ea # (UK) (1986) (v2) [Original] 22 | entry_hash_2 = e7df0e60 # (UK) (1986) (Spain retail version) [Original] 23 | entry_hash_3 = 3e88f3f7 # (UK) (1986) [Original] 24 | -------------------------------------------------------------------------------- /contrib/remaps/Dark Side (1988).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "106" 8 | input_player1_key_start_name = "Jet Pack" 9 | input_player1_key_select = "105" 10 | input_player1_key_select_name = "Information Load/Save" 11 | 12 | input_player1_key_a = "48" 13 | input_player1_key_a_name = "Fire" 14 | input_player1_key_b = "32" 15 | input_player1_key_b_name = "Change Pointer/Movement" 16 | input_player1_key_x = "115" 17 | input_player1_key_x_name = "Increase Step" 18 | input_player1_key_y = "120" 19 | input_player1_key_y_name = "Decrease Step" 20 | 21 | input_player1_key_l = "112" 22 | input_player1_key_l_name = "Look Up" 23 | input_player1_key_r = "108" 24 | input_player1_key_r_name = "Look Down" 25 | input_player1_key_l2 = "114" 26 | input_player1_key_l2_name = "Rise" 27 | input_player1_key_r2 = "102" 28 | input_player1_key_r2_name = "Fall/Crouch" 29 | 30 | entry_hash_1 = 0x596a99e0 # (UK) (1988) [Original] 31 | -------------------------------------------------------------------------------- /contrib/remaps/Dead By Dawn (2014).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "32" 8 | input_player1_key_start_name = "Change Pointer/Movement" 9 | input_player1_key_select = "105" 10 | input_player1_key_select_name = "Center View" 11 | 12 | input_player1_key_a = "98" 13 | input_player1_key_a_name = "Fire" 14 | input_player1_key_b = "97" 15 | input_player1_key_b_name = "Activate" 16 | input_player1_key_x = "306" 17 | input_player1_key_x_name = "Run" 18 | input_player1_key_y = "117" 19 | input_player1_key_y_name = "Turn Around" 20 | 21 | input_player1_key_l = "112" 22 | input_player1_key_l_name = "Look Up" 23 | input_player1_key_r = "108" 24 | input_player1_key_r_name = "Look Down" 25 | input_player1_key_l2 = "114" 26 | input_player1_key_l2_name = "Rise" 27 | input_player1_key_r2 = "102" 28 | input_player1_key_r2_name = "Fall/Crouch" 29 | 30 | entry_hash_1 = 0xaa88f4b9 # (S) (2014) [Original] 31 | 32 | entry_command = "RUN[quote]DEAD" -------------------------------------------------------------------------------- /contrib/remaps/Golden Axe (1986).rmp: -------------------------------------------------------------------------------- 1 | input_player1_key_start = "49" 2 | input_player1_key_start_name = "Start One Player" 3 | 4 | input_player1_key_select = "50" 5 | input_player1_key_select_name = "Joystick 1 Select" 6 | 7 | input_player1_key_b = "105" 8 | input_player1_key_b_name = "Magic" 9 | input_player1_key_x = "121" 10 | input_player1_key_x_name = "[Y]" # YES 11 | input_player1_key_y = "121" 12 | input_player1_key_y_name = "[Y]" # YES 13 | 14 | input_player2_key_start = "50" 15 | input_player2_key_start_name = "Start Two Players" 16 | 17 | input_player2_key_select = "51" 18 | input_player2_key_select_name = "Joystick 2 Select" 19 | 20 | input_player2_key_up = "$206" # JOY2 UP [6] 21 | input_player2_key_down = "$207" # JOY2 DOWN [5] 22 | input_player2_key_right = "$208" # JOY2 RIGHT [R] 23 | input_player2_key_left = "$209" # JOY2 LEFT [T] 24 | input_player2_key_a = "$210" # JOY2 FIRE1 [G] 25 | input_player2_key_a_name = "Slash" 26 | input_player2_key_b = "$211" # JOY2 FIRE2 [F] 27 | input_player2_key_b_name = "Magic" 28 | 29 | entry_hash_1 = 0xad37a08f # (UK) (1986) [Original] 30 | -------------------------------------------------------------------------------- /contrib/remaps/Castle Master I-II.rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "13" 8 | input_player1_key_select = "105" 9 | input_player1_key_select_name = "Information Load/Save" 10 | 11 | input_player1_key_a = "48" 12 | input_player1_key_a_name = "Fire" 13 | input_player1_key_b = "32" 14 | input_player1_key_b_name = "Change Pointer/Movement" 15 | input_player1_key_x = "97" 16 | input_player1_key_x_name = "Action/Press" 17 | input_player1_key_y = "99" 18 | input_player1_key_y_name = "Crouch" 19 | 20 | input_player1_key_l = "112" 21 | input_player1_key_l_name = "Look Up" 22 | input_player1_key_r = "108" 23 | input_player1_key_r_name = "Look Down" 24 | input_player1_key_l2 = "114" 25 | input_player1_key_l2_name = "Run" 26 | input_player1_key_r2 = "119" 27 | input_player1_key_r2_name = "Walk" 28 | 29 | entry_hash_1 = 0x276db46d # (S) (1990) [Original] 30 | entry_hash_2 = 0x680a8d67 # (UK,F,G) (1990) [Original] 31 | entry_hash_3 = 0xd415b403 # (UK) (1990) [Tape conversion] 32 | -------------------------------------------------------------------------------- /contrib/remaps/Driller (1988).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "117" 8 | input_player1_key_start_name = "U Turn" 9 | input_player1_key_select = "105" 10 | input_player1_key_select_name = "Information Load/Save" 11 | 12 | input_player1_key_a = "48" 13 | input_player1_key_a_name = "Fire" 14 | input_player1_key_b = "32" 15 | input_player1_key_b_name = "Change Pointer/Movement" 16 | input_player1_key_x = "100" 17 | input_player1_key_x_name = "Drill" 18 | input_player1_key_y = "99" 19 | input_player1_key_y_name = "Cancel Drill" 20 | 21 | input_player1_key_l = "112" 22 | input_player1_key_l_name = "Look Up" 23 | input_player1_key_r = "108" 24 | input_player1_key_r_name = "Look Down" 25 | input_player1_key_l2 = "114" 26 | input_player1_key_l2_name = "Rise" 27 | input_player1_key_r2 = "102" 28 | input_player1_key_r2_name = "Fall/Crouch" 29 | 30 | entry_hash_1 = 0x24a54215 # (UK) (1987) (CPM) [Original - Codes] 31 | entry_hash_2 = 0x73cff695 # (UK) (1988) [Clean Crack] 32 | -------------------------------------------------------------------------------- /contrib/remaps/Total Eclipse I-II (1988).rmp: -------------------------------------------------------------------------------- 1 | # CURSORS 2 | input_player1_key_up = "273" 3 | input_player1_key_down = "274" 4 | input_player1_key_left = "276" 5 | input_player1_key_right = "275" 6 | 7 | input_player1_key_start = "117" 8 | input_player1_key_start_name = "U Turn" 9 | input_player1_key_select = "105" 10 | input_player1_key_select_name = "Information Load/Save" 11 | 12 | input_player1_key_a = "48" 13 | input_player1_key_a_name = "Fire" 14 | input_player1_key_b = "32" 15 | input_player1_key_b_name = "Change Pointer/Movement" 16 | input_player1_key_x = "114" 17 | input_player1_key_x_name = "Rest" 18 | input_player1_key_y = "104" 19 | input_player1_key_y_name = "Crouch/Walk" 20 | 21 | input_player1_key_l = "112" 22 | input_player1_key_l_name = "Look Up" 23 | input_player1_key_r = "108" 24 | input_player1_key_r_name = "Look Down" 25 | input_player1_key_l2 = "115" 26 | input_player1_key_l2_name = "Change Step" 27 | input_player1_key_r2 = "97" 28 | input_player1_key_r2_name = "Change Angle" 29 | 30 | entry_hash_1 = 0x41f8051c # I - (UK) (1988) (Spain retail version) [Original] 31 | entry_hash_2 = 0xd8e6113b # II - (UK) (1989) 32 | -------------------------------------------------------------------------------- /cap32/cart.h: -------------------------------------------------------------------------------- 1 | /* Caprice32 - Amstrad CPC Emulator 2 | (c) Copyright 1997-2004 Ulrich Doewich 3 | 4 | This program is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This program is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this program; if not, write to the Free Software 16 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 17 | */ 18 | 19 | #ifndef CART_H 20 | #define CART_H 21 | 22 | #include "cap32.h" 23 | 24 | extern uint8_t *pbCartridgeImage; 25 | extern uint8_t *pbCartridgePages[]; 26 | 27 | void cpr_eject (void); 28 | int cpr_fload (const char* pchFileName); 29 | int cpr_load (const uint8_t* pbCtBuffer); 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /contrib/remaps/Abadia Del Crimen (1988).rmp: -------------------------------------------------------------------------------- 1 | # start input mapping 2 | input_player1_key_a = "97" 3 | input_player1_key_a_name = "Avanzar" 4 | input_player1_key_b = "122" 5 | input_player1_key_b_name = "Mover Adso" 6 | input_player1_key_left = "107" 7 | input_player1_key_left_name = "Girar Izquierda" 8 | input_player1_key_right = "108" 9 | input_player1_key_right_name = "Girar Derecha" 10 | input_player1_key_start = "32" 11 | input_player1_key_start_name = "Start / Dejar Objeto" 12 | input_player1_key_x = "110" 13 | input_player1_key_x_name = "Decir No" 14 | input_player1_key_y = "115" 15 | input_player1_key_y_name = "Decir Si" 16 | 17 | # game hashes 18 | entry_hash_1 = "0xaa05ed4a" # (S) (128K) (1988) (CPM) [Original] 19 | entry_hash_2 = "0xd37cf8e7" # (S) (128K) (1988) (CPM) (cpcrulez) 20 | 21 | # game load command 22 | # special commands: 23 | # [enter] => \n 24 | # [quote] => " 25 | # [wait] => wait 5 seconds 26 | entry_command = "|CPM" 27 | 28 | # map type (clean/keep) 29 | # keep: use joystick as base and add/changes inputs given above 30 | # clean: clear all default binds and only uses the given above 31 | entry_map_type = "clean" 32 | -------------------------------------------------------------------------------- /cap32/tape.h: -------------------------------------------------------------------------------- 1 | /* Caprice32 - Amstrad CPC Emulator 2 | (c) Copyright 1997-2004 Ulrich Doewich 3 | 4 | This program is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This program is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this program; if not, write to the Free Software 16 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 17 | */ 18 | 19 | #ifndef TAPE_H 20 | #define TAPE_H 21 | 22 | #define TAPE_LEVEL_LOW 0 23 | #define TAPE_LEVEL_HIGH 0x80 24 | 25 | #ifdef __cplusplus 26 | extern "C" { 27 | #endif 28 | 29 | void Tape_UpdateLevel(void); 30 | void Tape_Rewind(void); 31 | 32 | #ifdef __cplusplus 33 | } 34 | #endif 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /contrib/remaps/Abbey Of Crime (2017).rmp: -------------------------------------------------------------------------------- 1 | # ignored 2 | input_libretro_device_p1 = "259" 3 | input_libretro_device_p2 = "1" 4 | input_player1_analog_dpad_mode = "1" 5 | input_player2_analog_dpad_mode = "1" 6 | input_remap_port_p1 = "0" 7 | input_remap_port_p2 = "1" 8 | 9 | # start mapping 10 | input_player1_key_a = "97" 11 | input_player1_key_a_name = "Move forward" 12 | input_player1_key_b = "122" 13 | input_player1_key_b_name = "Send adso Forward" 14 | input_player1_key_left = "107" 15 | input_player1_key_left_name = "Turn Counterclockwise" 16 | input_player1_key_right = "108" 17 | input_player1_key_right_name = "Turn Clockwise" 18 | input_player1_key_start = "32" 19 | input_player1_key_start_name = "Start / Drop Object" 20 | input_player1_key_x = "110" 21 | input_player1_key_x_name = "Answer No" 22 | input_player1_key_y = "121" 23 | input_player1_key_y_name = "answer yes" 24 | 25 | # game load command 26 | # special commands: 27 | # [enter] => \n 28 | # [quote] => " 29 | # [wait] => wait 5 seconds 30 | entry_command = "|CPM" 31 | 32 | # game hashes 33 | entry_hash_1 = "0xbf188ce3" # (UK) (128K) (2017) (CPM) 34 | entry_hash_2 = "0x6e5f98ff" # (UK) (128K) (2017) (cpcrulez) 35 | 36 | # map type (clean/keep) 37 | # keep: use joystick as base and add/changes inputs given above 38 | # clean: clear all default binds and only uses the given above 39 | entry_map_type = "clean" 40 | -------------------------------------------------------------------------------- /libretro-common/include/libchdr/bitstream.h: -------------------------------------------------------------------------------- 1 | /* license:BSD-3-Clause 2 | * copyright-holders:Aaron Giles 3 | *************************************************************************** 4 | 5 | bitstream.h 6 | 7 | Helper classes for reading/writing at the bit level. 8 | 9 | ***************************************************************************/ 10 | 11 | #pragma once 12 | 13 | #ifndef __BITSTREAM_H__ 14 | #define __BITSTREAM_H__ 15 | 16 | #include 17 | 18 | /*************************************************************************** 19 | * TYPE DEFINITIONS 20 | *************************************************************************** 21 | */ 22 | 23 | /* helper class for reading from a bit buffer */ 24 | struct bitstream 25 | { 26 | uint32_t buffer; /* current bit accumulator */ 27 | int bits; /* number of bits in the accumulator */ 28 | const uint8_t * read; /* read pointer */ 29 | uint32_t doffset; /* byte offset within the data */ 30 | uint32_t dlength; /* length of the data */ 31 | }; 32 | 33 | struct bitstream* create_bitstream(const void *src, uint32_t srclength); 34 | int bitstream_overflow(struct bitstream* bitstream); 35 | uint32_t bitstream_read_offset(struct bitstream* bitstream); 36 | 37 | uint32_t bitstream_read(struct bitstream* bitstream, int numbits); 38 | uint32_t bitstream_peek(struct bitstream* bitstream, int numbits); 39 | void bitstream_remove(struct bitstream* bitstream, int numbits); 40 | uint32_t bitstream_flush(struct bitstream* bitstream); 41 | 42 | #endif 43 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/EQ.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = eq 3 | 4 | # Defaults 5 | 6 | # Beta factor for Kaiser window. 7 | # Lower values will allow better frequency resolution, but more ripple. 8 | # eq_window_beta = 4.0 9 | 10 | # The block size on which FFT is done. 11 | # Too high value requires more processing as well as longer latency but 12 | # allows finer-grained control over the spectrum. 13 | # eq_block_size_log2 = 8 14 | 15 | # An array of which frequencies to control. 16 | # You can create an arbitrary amount of these sampling points. 17 | # The EQ will try to create a frequency response which fits well to these points. 18 | # The filter response is linearly interpolated between sampling points here. 19 | # 20 | # It is implied that 0 Hz (DC) and Nyquist have predefined gains of 0 dB which are interpolated against. 21 | # If you want a "peak" in the spectrum or similar, you have to define close points to say, 0 dB. 22 | # 23 | # E.g.: A boost of 3 dB at 1 kHz can be expressed as. 24 | # eq_frequencies = "500 1000 2000" 25 | # eq_gains = "0 3 0" 26 | # Due to frequency domain smearing, you will not get exactly +3 dB at 1 kHz. 27 | 28 | # By default, this filter has a flat frequency response. 29 | 30 | # Dumps the impulse response generated by the EQ as a plain-text file 31 | # with one coefficient per line. 32 | # eq_impulse_response_output = "eq_impulse.txt" 33 | # 34 | # Using GNU Octave or Matlab, you can plot the response with: 35 | # 36 | # f = fopen('/path/to/eq_impulse.txt'); 37 | # l = textscan(f, '%f'); 38 | # res = l{1}; 39 | # freqz(res, 1, 4096, 48000); 40 | # 41 | # It will give the response in Hz; 48000 is the default Output Rate of RetroArch 42 | -------------------------------------------------------------------------------- /libretro-common/include/compat/fnmatch.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (fnmatch.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_COMPAT_FNMATCH_H__ 24 | #define __LIBRETRO_SDK_COMPAT_FNMATCH_H__ 25 | 26 | #define FNM_NOMATCH 1 27 | 28 | int rl_fnmatch(const char *pattern, const char *string, int flags); 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /libretro-common/include/utils/md5.h: -------------------------------------------------------------------------------- 1 | /* 2 | * This is an OpenSSL-compatible implementation of the RSA Data Security, Inc. 3 | * MD5 Message-Digest Algorithm (RFC 1321). 4 | * 5 | * Homepage: 6 | * http://openwall.info/wiki/people/solar/software/public-domain-source-code/md5 7 | * 8 | * Author: 9 | * Alexander Peslyak, better known as Solar Designer 10 | * 11 | * This software was written by Alexander Peslyak in 2001. No copyright is 12 | * claimed, and the software is hereby placed in the public domain. 13 | * In case this attempt to disclaim copyright and place the software in the 14 | * public domain is deemed null and void, then the software is 15 | * Copyright (c) 2001 Alexander Peslyak and it is hereby released to the 16 | * general public under the following terms: 17 | * 18 | * Redistribution and use in source and binary forms, with or without 19 | * modification, are permitted. 20 | * 21 | * There's ABSOLUTELY NO WARRANTY, express or implied. 22 | * 23 | * See md5.c for more information. 24 | */ 25 | 26 | #ifdef HAVE_OPENSSL 27 | #include 28 | #elif !defined(_MD5_H) 29 | #define _MD5_H 30 | 31 | #include 32 | 33 | RETRO_BEGIN_DECLS 34 | 35 | /* Any 32-bit or wider unsigned integer data type will do */ 36 | typedef unsigned int MD5_u32plus; 37 | 38 | typedef struct { 39 | MD5_u32plus lo, hi; 40 | MD5_u32plus a, b, c, d; 41 | unsigned char buffer[64]; 42 | MD5_u32plus block[16]; 43 | } MD5_CTX; 44 | 45 | extern void MD5_Init(MD5_CTX *ctx); 46 | extern void MD5_Update(MD5_CTX *ctx, const void *data, unsigned long size); 47 | extern void MD5_Final(unsigned char *result, MD5_CTX *ctx); 48 | 49 | RETRO_END_DECLS 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /cap32/slots.h: -------------------------------------------------------------------------------- 1 | /* Caprice32 - Amstrad CPC Emulator 2 | (c) Copyright 1997-2004 Ulrich Doewich 3 | 4 | This program is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This program is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this program; if not, write to the Free Software 16 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 17 | */ 18 | 19 | #ifndef SLOTS_H 20 | #define SLOTS_H 21 | 22 | #include 23 | #include 24 | 25 | #include "cap32.h" 26 | 27 | int cpm_boot (char * comfile); 28 | 29 | int snapshot_load_mem (uint8_t *sna_buffer, uint32_t buffer_size); 30 | int snapshot_save_mem (uint8_t *sna_buffer, uint32_t buffer_size); 31 | int snapshot_load (char *pchFileName); 32 | int snapshot_save (char *pchFileName); 33 | 34 | void dsk_eject (t_drive *drive); 35 | int dsk_load (char *pchFileName, t_drive *drive, char chID); 36 | int dsk_save (char *pchFileName, t_drive *drive, char chID); 37 | int dsk_format (t_drive *drive, int iFormat); 38 | int dsk_diff (char *pchFileName, t_drive *altered, t_drive *org); 39 | int dsk_diff_load (char *pchFileName, t_drive *drive); 40 | 41 | void tape_eject (void); 42 | void play_tape(void); 43 | void stop_tape(void); 44 | int tape_insert (char *pchFileName); 45 | int tape_insert_voc (char *pchFileName); 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /libretro-common/include/gfx/scaler/filter.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (filter.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_SCALER_FILTER_H__ 24 | #define __LIBRETRO_SDK_SCALER_FILTER_H__ 25 | 26 | #include 27 | 28 | RETRO_BEGIN_DECLS 29 | 30 | #include 31 | #include 32 | 33 | bool scaler_gen_filter(struct scaler_ctx *ctx); 34 | 35 | RETRO_END_DECLS 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /libretro-common/include/retro_assert.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (retro_assert.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __RETRO_ASSERT_H 24 | #define __RETRO_ASSERT_H 25 | 26 | #include 27 | 28 | #ifdef RARCH_INTERNAL 29 | #include 30 | #define retro_assert(cond) ((void)( (cond) || (printf("Assertion failed at %s:%d.\n", __FILE__, __LINE__), abort(), 0) )) 31 | #else 32 | #define retro_assert(cond) assert(cond) 33 | #endif 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /libretro-common/include/memalign.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (memalign.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef _LIBRETRO_MEMALIGN_H 24 | #define _LIBRETRO_MEMALIGN_H 25 | 26 | #include 27 | 28 | #include 29 | 30 | RETRO_BEGIN_DECLS 31 | 32 | void *memalign_alloc(size_t boundary, size_t size); 33 | 34 | void *memalign_alloc_aligned(size_t size); 35 | 36 | void memalign_free(void *ptr); 37 | 38 | RETRO_END_DECLS 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /libretro-common/include/streams/stdin_stream.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (stdin_stream.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef LIBRETRO_SDK_STDIN_STREAM_H__ 24 | #define LIBRETRO_SDK_STDIN_STREAM_H__ 25 | 26 | #include 27 | #include 28 | 29 | #include 30 | 31 | #include 32 | 33 | RETRO_BEGIN_DECLS 34 | 35 | size_t read_stdin(char *buf, size_t size); 36 | 37 | RETRO_END_DECLS 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /libretro-common/include/encodings/crc32.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (crc32.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef _LIBRETRO_ENCODINGS_CRC32_H 24 | #define _LIBRETRO_ENCODINGS_CRC32_H 25 | 26 | #include 27 | #include 28 | 29 | #include 30 | 31 | RETRO_BEGIN_DECLS 32 | 33 | uint32_t encoding_crc32(uint32_t crc, const uint8_t *buf, size_t len); 34 | uint32_t file_crc32(uint32_t crc, const char *path); 35 | 36 | RETRO_END_DECLS 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /cap32/retro_inline.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (retro_inline.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_INLINE_H 24 | #define __LIBRETRO_SDK_INLINE_H 25 | 26 | #ifndef INLINE 27 | 28 | #if defined(_WIN32) || defined(__INTEL_COMPILER) 29 | #define INLINE __inline 30 | #elif defined(__STDC_VERSION__) && __STDC_VERSION__>=199901L 31 | #define INLINE inline 32 | #elif defined(__GNUC__) 33 | #define INLINE __inline__ 34 | #else 35 | #define INLINE 36 | #endif 37 | 38 | #endif 39 | #endif 40 | -------------------------------------------------------------------------------- /libretro-common/include/rthreads/async_job.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (async_job.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_ASYNC_JOB_H 24 | #define __LIBRETRO_SDK_ASYNC_JOB_H 25 | 26 | typedef struct async_job async_job_t; 27 | typedef void (*async_task_t)(void *payload); 28 | 29 | async_job_t *async_job_new(void); 30 | 31 | void async_job_free(async_job_t *ajob); 32 | 33 | int async_job_add(async_job_t *ajob, async_task_t task, void *payload); 34 | 35 | #endif /* __LIBRETRO_SDK_ASYNC_JOB_H */ 36 | -------------------------------------------------------------------------------- /libretro-common/include/retro_inline.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (retro_inline.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_INLINE_H 24 | #define __LIBRETRO_SDK_INLINE_H 25 | 26 | #ifndef INLINE 27 | 28 | #if defined(_WIN32) || defined(__INTEL_COMPILER) 29 | #define INLINE __inline 30 | #elif defined(__STDC_VERSION__) && __STDC_VERSION__>=199901L 31 | #define INLINE inline 32 | #elif defined(__GNUC__) 33 | #define INLINE __inline__ 34 | #else 35 | #define INLINE 36 | #endif 37 | 38 | #endif 39 | #endif 40 | -------------------------------------------------------------------------------- /libretro-common/include/boolean.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (boolean.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_BOOLEAN_H 24 | #define __LIBRETRO_SDK_BOOLEAN_H 25 | 26 | #ifndef __cplusplus 27 | 28 | #if defined(_MSC_VER) && _MSC_VER < 1800 && !defined(SN_TARGET_PS3) 29 | /* Hack applied for MSVC when compiling in C89 mode as it isn't C99 compliant. */ 30 | #define bool unsigned char 31 | #define true 1 32 | #define false 0 33 | #else 34 | #include 35 | #endif 36 | 37 | #endif 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /libretro-common/include/compat/fopen_utf8.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (fopen_utf8.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_COMPAT_FOPEN_UTF8_H 24 | #define __LIBRETRO_SDK_COMPAT_FOPEN_UTF8_H 25 | 26 | #ifdef _WIN32 27 | /* Defined to error rather than fopen_utf8, to make it clear to everyone reading the code that not worrying about utf16 is fine */ 28 | /* TODO: enable */ 29 | /* #define fopen (use fopen_utf8 instead) */ 30 | void *fopen_utf8(const char * filename, const char * mode); 31 | #else 32 | #define fopen_utf8 fopen 33 | #endif 34 | #endif 35 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/LowPassCPS.dsp: -------------------------------------------------------------------------------- 1 | filters = 1 2 | filter0 = eq 3 | 4 | eq_frequencies = "8000 10000 12500 16000 20000" 5 | eq_gains = "0 -30 -30 -30 -30" 6 | 7 | # Low pass filter for the QSound chip from CPS-1/2. 8 | # Some games have aliasing due low quality samples, so you can hear some annoying noisy near 11 kHz 9 | 10 | # Defaults 11 | 12 | # Beta factor for Kaiser window. 13 | # Lower values will allow better frequency resolution, but more ripple. 14 | # eq_window_beta = 4.0 15 | 16 | # The block size on which FFT is done. 17 | # Too high value requires more processing as well as longer latency but 18 | # allows finer-grained control over the spectrum. 19 | # eq_block_size_log2 = 8 20 | 21 | # An array of which frequencies to control. 22 | # You can create an arbitrary amount of these sampling points. 23 | # The EQ will try to create a frequency response which fits well to these points. 24 | # The filter response is linearly interpolated between sampling points here. 25 | # 26 | # It is implied that 0 Hz (DC) and Nyquist have predefined gains of 0 dB which are interpolated against. 27 | # If you want a "peak" in the spectrum or similar, you have to define close points to say, 0 dB. 28 | # 29 | # E.g.: A boost of 3 dB at 1 kHz can be expressed as. 30 | # eq_frequencies = "500 1000 2000" 31 | # eq_gains = "0 3 0" 32 | # Due to frequency domain smearing, you will not get exactly +3 dB at 1 kHz. 33 | 34 | # By default, this filter has a low pass response with cuttof frequency at ~8600 Hz. 35 | 36 | # Dumps the impulse response generated by the EQ as a plain-text file 37 | # with one coefficient per line. 38 | # eq_impulse_response_output = "eq_impulse.txt" 39 | # 40 | # Using GNU Octave or Matlab, you can plot the response with: 41 | # 42 | # f = fopen('/path/to/eq_impulse.txt'); 43 | # l = textscan(f, '%f'); 44 | # res = l{1}; 45 | # freqz(res, 1, 4096, 48000); 46 | # 47 | # It will give the response in Hz; 48000 is the default Output Rate of RetroArch 48 | -------------------------------------------------------------------------------- /libretro-common/include/encodings/base64.h: -------------------------------------------------------------------------------- 1 | #ifndef _LIBRETRO_ENCODINGS_BASE64_H 2 | #define _LIBRETRO_ENCODINGS_BASE64_H 3 | 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | RETRO_BEGIN_DECLS 10 | 11 | const static char* b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; 12 | 13 | /* maps A=>0,B=>1.. */ 14 | const static unsigned char unb64[]={ 15 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 17 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19 | 0, 0, 0, 62, 0, 0, 0, 63, 52, 53, 20 | 54, 55, 56, 57, 58, 59, 60, 61, 0, 0, 21 | 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 22 | 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 23 | 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 24 | 25, 0, 0, 0, 0, 0, 0, 26, 27, 28, 25 | 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 26 | 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 27 | 49, 50, 51, 0, 0, 0, 0, 0, 0, 0, 28 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 29 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 31 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 33 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 34 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 35 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 36 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 37 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 38 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 39 | 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40 | 0, 0, 0, 0, 0, 0, 41 | }; /* This array has 256 elements */ 42 | 43 | char* base64(const void* binaryData, int len, int *flen); 44 | unsigned char* unbase64(const char* ascii, int len, int *flen); 45 | 46 | RETRO_END_DECLS 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /libretro-common/include/libchdr/libchdr_zlib.h: -------------------------------------------------------------------------------- 1 | /* license:BSD-3-Clause 2 | * copyright-holders:Aaron Giles 3 | *************************************************************************** 4 | 5 | libchr_zlib.h 6 | 7 | Zlib compression wrappers 8 | 9 | ***************************************************************************/ 10 | 11 | #pragma once 12 | 13 | #ifndef __LIBCHDR_ZLIB_H__ 14 | #define __LIBCHDR_ZLIB_H__ 15 | 16 | #include 17 | 18 | #include 19 | #include "coretypes.h" 20 | #include "chd.h" 21 | 22 | #define MAX_ZLIB_ALLOCS 64 23 | 24 | /* codec-private data for the ZLIB codec */ 25 | 26 | typedef struct _zlib_allocator zlib_allocator; 27 | struct _zlib_allocator 28 | { 29 | UINT32 * allocptr[MAX_ZLIB_ALLOCS]; 30 | UINT32 * allocptr2[MAX_ZLIB_ALLOCS]; 31 | }; 32 | 33 | typedef struct _zlib_codec_data zlib_codec_data; 34 | struct _zlib_codec_data 35 | { 36 | z_stream inflater; 37 | zlib_allocator allocator; 38 | }; 39 | 40 | /* codec-private data for the CDZL codec */ 41 | typedef struct _cdzl_codec_data cdzl_codec_data; 42 | struct _cdzl_codec_data { 43 | /* internal state */ 44 | zlib_codec_data base_decompressor; 45 | #ifdef WANT_SUBCODE 46 | zlib_codec_data subcode_decompressor; 47 | #endif 48 | uint8_t* buffer; 49 | }; 50 | 51 | /* zlib compression codec */ 52 | chd_error zlib_codec_init(void *codec, uint32_t hunkbytes); 53 | 54 | void zlib_codec_free(void *codec); 55 | 56 | chd_error zlib_codec_decompress(void *codec, const uint8_t *src, uint32_t complen, uint8_t *dest, uint32_t destlen); 57 | 58 | voidpf zlib_fast_alloc(voidpf opaque, uInt items, uInt size); 59 | 60 | void zlib_fast_free(voidpf opaque, voidpf address); 61 | 62 | /* cdzl compression codec */ 63 | chd_error cdzl_codec_init(void* codec, uint32_t hunkbytes); 64 | 65 | void cdzl_codec_free(void* codec); 66 | 67 | chd_error cdzl_codec_decompress(void *codec, const uint8_t *src, uint32_t complen, uint8_t *dest, uint32_t destlen); 68 | 69 | #endif /* __LIBCHDR_ZLIB_H__ */ 70 | -------------------------------------------------------------------------------- /libretro-common/include/retro_common.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (retro_common.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef _LIBRETRO_COMMON_RETRO_COMMON_H 24 | #define _LIBRETRO_COMMON_RETRO_COMMON_H 25 | 26 | /* 27 | This file is designed to normalize the libretro-common compiling environment. 28 | It is not to be used in public API headers, as they should be designed as leanly as possible. 29 | Nonetheless.. in the meantime, if you do something like use ssize_t, which is not fully portable, 30 | in a public API, you may need this. 31 | */ 32 | 33 | /* conditional compilation is handled inside here */ 34 | #include 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /libretro-common/compat/compat_vscprintf.c: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (compat_snprintf.c). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | /* THIS FILE HAS NOT BEEN VALIDATED ON PLATFORMS BESIDES MSVC */ 24 | #ifdef _MSC_VER 25 | 26 | #include 27 | 28 | #include 29 | #include 30 | 31 | #if defined(_MSC_VER) && _MSC_VER < 1800 32 | #define va_copy(dst, src) ((dst) = (src)) 33 | #endif 34 | 35 | int c89_vscprintf_retro__(const char *format, va_list pargs) 36 | { 37 | int retval; 38 | va_list argcopy; 39 | va_copy(argcopy, pargs); 40 | retval = vsnprintf(NULL, 0, format, argcopy); 41 | va_end(argcopy); 42 | return retval; 43 | } 44 | #endif 45 | -------------------------------------------------------------------------------- /contrib/font/convert.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | # -*- coding: utf-8 -*- 3 | 4 | """ 5 | Simple PNG to bit-font converter 6 | 7 | Copyright (C) 2020 David Colmenero - D_Skywalk 8 | http://david.dantoine.org 9 | 10 | This program is free software; you can redistribute it and/or modify 11 | it under the terms of the GNU General Public License as published by 12 | the Free Software Foundation; either version 3 of the License, or 13 | higher any later version. 14 | 15 | This program is distributed in the hope that it will be useful, 16 | but WITHOUT ANY WARRANTY; without even the implied warranty of 17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 | GNU General Public License for more details. 19 | 20 | You should have received a copy of the GNU General Public License 21 | along with this program; if not, write to the Free Software Foundation, 22 | Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 23 | """ 24 | import sys 25 | from PIL import Image 26 | import numpy as np 27 | 28 | BLACK = [0, 0, 0] 29 | 30 | def is_black(data, mode): 31 | if mode == "RGBA": 32 | (r, g, b, a) = data 33 | return [r, g, b] == BLACK 34 | else: 35 | (r, g, b) = data 36 | return [r, g, b] == BLACK 37 | 38 | 39 | def open(filename): 40 | img = Image.open(filename) 41 | im_array = np.array(img) 42 | (width, height) = img.size 43 | mode = img.mode 44 | # print("pix", is_black(im_array[0][0], mode)) 45 | 46 | print ("static unsigned char bFont[] = {") 47 | 48 | for y in range(0, height): 49 | data = 0 50 | for x in range(0, width): 51 | if not is_black(im_array[y][x], mode): 52 | data |= 1 53 | data <<= 1 54 | data >>= 1 55 | print("0x%02X, " % data, end='') 56 | if y % 16 == 0: 57 | print("") 58 | 59 | if __name__ == '__main__': 60 | if len(sys.argv) != 2: 61 | print("error $> convert.py image.png") 62 | else: 63 | open(sys.argv[1]) 64 | 65 | 66 | -------------------------------------------------------------------------------- /libretro-common/audio/dsp_filters/fft/fft.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (fft.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef RARCH_FFT_H__ 24 | #define RARCH_FFT_H__ 25 | 26 | #include 27 | #include 28 | 29 | typedef struct fft fft_t; 30 | 31 | fft_t *fft_new(unsigned block_size_log2); 32 | 33 | void fft_free(fft_t *fft); 34 | 35 | void fft_process_forward_complex(fft_t *fft, 36 | fft_complex_t *out, const fft_complex_t *in, unsigned step); 37 | 38 | void fft_process_forward(fft_t *fft, 39 | fft_complex_t *out, const float *in, unsigned step); 40 | 41 | void fft_process_inverse(fft_t *fft, 42 | float *out, const fft_complex_t *in, unsigned step); 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /libretro-common/include/compat/ifaddrs.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1995, 1999 3 | * Berkeley Software Design, Inc. All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 11 | * THIS SOFTWARE IS PROVIDED BY Berkeley Software Design, Inc. ``AS IS'' AND 12 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 13 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 14 | * ARE DISCLAIMED. IN NO EVENT SHALL Berkeley Software Design, Inc. BE LIABLE 15 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 16 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 17 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 18 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 19 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 20 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 21 | * SUCH DAMAGE. 22 | * 23 | * BSDI ifaddrs.h,v 2.5 2000/02/23 14:51:59 dab Exp 24 | */ 25 | 26 | #ifndef _IFADDRS_H_ 27 | #define _IFADDRS_H_ 28 | 29 | struct ifaddrs 30 | { 31 | struct ifaddrs *ifa_next; 32 | char *ifa_name; 33 | unsigned int ifa_flags; 34 | struct sockaddr *ifa_addr; 35 | struct sockaddr *ifa_netmask; 36 | struct sockaddr *ifa_dstaddr; 37 | void *ifa_data; 38 | }; 39 | 40 | /* 41 | * This may have been defined in . Note that if is 42 | * to be included it must be included before this header file. 43 | */ 44 | #ifndef ifa_broadaddr 45 | #define ifa_broadaddr ifa_dstaddr /* broadcast address interface */ 46 | #endif 47 | 48 | #include 49 | 50 | extern int getifaddrs(struct ifaddrs **ifap); 51 | extern void freeifaddrs(struct ifaddrs *ifa); 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /libretro-common/include/time/rtime.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (rtime.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_RTIME_H__ 24 | #define __LIBRETRO_SDK_RTIME_H__ 25 | 26 | #include 27 | 28 | #include 29 | #include 30 | #include 31 | 32 | RETRO_BEGIN_DECLS 33 | 34 | /* TODO/FIXME: Move all generic time handling functions 35 | * to this file */ 36 | 37 | /* Must be called before using rtime_localtime() */ 38 | void rtime_init(void); 39 | 40 | /* Must be called upon program termination */ 41 | void rtime_deinit(void); 42 | 43 | /* Thread-safe wrapper for localtime() */ 44 | struct tm *rtime_localtime(const time_t *timep, struct tm *result); 45 | 46 | RETRO_END_DECLS 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /libretro-common/include/compat/strcasestr.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (strcasestr.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_COMPAT_STRCASESTR_H 24 | #define __LIBRETRO_SDK_COMPAT_STRCASESTR_H 25 | 26 | #include 27 | 28 | #if defined(RARCH_INTERNAL) && defined(HAVE_CONFIG_H) 29 | #include "../../../config.h" 30 | #endif 31 | 32 | #ifndef HAVE_STRCASESTR 33 | 34 | #include 35 | 36 | RETRO_BEGIN_DECLS 37 | 38 | /* Avoid possible naming collisions during link 39 | * since we prefer to use the actual name. */ 40 | #define strcasestr(haystack, needle) strcasestr_retro__(haystack, needle) 41 | 42 | char *strcasestr(const char *haystack, const char *needle); 43 | 44 | RETRO_END_DECLS 45 | 46 | #endif 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /libretro-common/include/gfx/scaler/scaler_int.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (scaler_int.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_SCALER_INT_H__ 24 | #define __LIBRETRO_SDK_SCALER_INT_H__ 25 | 26 | #include 27 | 28 | #include 29 | 30 | RETRO_BEGIN_DECLS 31 | 32 | void scaler_argb8888_vert(const struct scaler_ctx *ctx, 33 | void *output, int stride); 34 | 35 | void scaler_argb8888_horiz(const struct scaler_ctx *ctx, 36 | const void *input, int stride); 37 | 38 | void scaler_argb8888_point_special(const struct scaler_ctx *ctx, 39 | void *output, const void *input, 40 | int out_width, int out_height, 41 | int in_width, int in_height, 42 | int out_stride, int in_stride); 43 | 44 | RETRO_END_DECLS 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /libretro-common/include/libchdr/lzma.h: -------------------------------------------------------------------------------- 1 | /* license:BSD-3-Clause 2 | * copyright-holders:Aaron Giles 3 | *************************************************************************** 4 | 5 | lzma.h 6 | 7 | LZMA compression wrappers 8 | 9 | ***************************************************************************/ 10 | 11 | #pragma once 12 | 13 | #ifndef __LIBCHDR_LZMA_H__ 14 | #define __LIBCHDR_LZMA_H__ 15 | 16 | #include 17 | 18 | #include 19 | #include 20 | 21 | #include 22 | 23 | /* codec-private data for the LZMA codec */ 24 | #define MAX_LZMA_ALLOCS 64 25 | 26 | typedef struct _lzma_allocator lzma_allocator; 27 | struct _lzma_allocator 28 | { 29 | void *(*Alloc)(void *p, size_t size); 30 | void (*Free)(void *p, void *address); /* address can be 0 */ 31 | void (*FreeSz)(void *p, void *address, size_t size); /* address can be 0 */ 32 | uint32_t* allocptr[MAX_LZMA_ALLOCS]; 33 | uint32_t* allocptr2[MAX_LZMA_ALLOCS]; 34 | }; 35 | 36 | typedef struct _lzma_codec_data lzma_codec_data; 37 | struct _lzma_codec_data 38 | { 39 | CLzmaDec decoder; 40 | lzma_allocator allocator; 41 | }; 42 | 43 | /* codec-private data for the CDLZ codec */ 44 | typedef struct _cdlz_codec_data cdlz_codec_data; 45 | struct _cdlz_codec_data { 46 | /* internal state */ 47 | lzma_codec_data base_decompressor; 48 | #ifdef WANT_SUBCODE 49 | zlib_codec_data subcode_decompressor; 50 | #endif 51 | uint8_t* buffer; 52 | }; 53 | 54 | chd_error lzma_codec_init(void* codec, uint32_t hunkbytes); 55 | 56 | void lzma_codec_free(void* codec); 57 | 58 | /*------------------------------------------------- 59 | * decompress - decompress data using the LZMA 60 | * codec 61 | *------------------------------------------------- 62 | */ 63 | 64 | chd_error lzma_codec_decompress(void* codec, const uint8_t *src, 65 | uint32_t complen, uint8_t *dest, uint32_t destlen); 66 | 67 | chd_error cdlz_codec_init(void* codec, uint32_t hunkbytes); 68 | 69 | void cdlz_codec_free(void* codec); 70 | 71 | chd_error cdlz_codec_decompress(void *codec, const uint8_t *src, uint32_t complen, uint8_t *dest, uint32_t destlen); 72 | 73 | #endif /* __LIBCHDR_LZMA_H__ */ 74 | -------------------------------------------------------------------------------- /cap32/errors.h: -------------------------------------------------------------------------------- 1 | /* Caprice32 - Amstrad CPC Emulator 2 | (c) Copyright 1997-2004 Ulrich Doewich 3 | 4 | This program is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This program is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this program; if not, write to the Free Software 16 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 17 | */ 18 | 19 | #ifndef ERROR_H 20 | #define ERROR_H 21 | 22 | #define ERR_INPUT_INIT 1 23 | #define ERR_VIDEO_INIT 2 24 | #define ERR_VIDEO_SET_MODE 3 25 | #define ERR_VIDEO_SURFACE 4 26 | #define ERR_VIDEO_PALETTE 5 27 | #define ERR_VIDEO_COLOUR_DEPTH 6 28 | #define ERR_AUDIO_INIT 7 29 | #define ERR_AUDIO_RATE 8 30 | #define ERR_OUT_OF_MEMORY 9 31 | #define ERR_CPC_ROM_MISSING 10 32 | #define ERR_NOT_A_CPC_ROM 11 33 | #define ERR_ROM_NOT_FOUND 12 34 | #define ERR_FILE_NOT_FOUND 13 35 | #define ERR_FILE_BAD_ZIP 14 36 | #define ERR_FILE_EMPTY_ZIP 15 37 | #define ERR_FILE_UNZIP_FAILED 16 38 | #define ERR_SNA_INVALID 17 39 | #define ERR_SNA_SIZE 18 40 | #define ERR_SNA_CPC_TYPE 19 41 | #define ERR_SNA_WRITE 20 42 | #define ERR_DSK_INVALID 21 43 | #define ERR_DSK_SIDES 22 44 | #define ERR_DSK_SECTORS 23 45 | #define ERR_DSK_WRITE 24 46 | #define MSG_DSK_ALTERED 25 47 | #define ERR_TAP_INVALID 26 48 | #define ERR_TAP_UNSUPPORTED 27 49 | #define ERR_TAP_BAD_VOC 28 50 | #define ERR_PRINTER 29 51 | #define ERR_BAD_MF2_ROM 30 52 | #define ERR_SDUMP 31 53 | 54 | #define ERR_CPR_INVALID 32 55 | #define ERR_CPR_INVALID_SIZE 33 56 | 57 | #endif 58 | -------------------------------------------------------------------------------- /utils/zlib/uncompr.c: -------------------------------------------------------------------------------- 1 | /* uncompr.c -- decompress a memory buffer 2 | * Copyright (C) 1995-2003, 2010 Jean-loup Gailly. 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* @(#) $Id$ */ 7 | 8 | #define ZLIB_INTERNAL 9 | #include "zlib.h" 10 | 11 | /* =========================================================================== 12 | Decompresses the source buffer into the destination buffer. sourceLen is 13 | the byte length of the source buffer. Upon entry, destLen is the total 14 | size of the destination buffer, which must be large enough to hold the 15 | entire uncompressed data. (The size of the uncompressed data must have 16 | been saved previously by the compressor and transmitted to the decompressor 17 | by some mechanism outside the scope of this compression library.) 18 | Upon exit, destLen is the actual size of the compressed buffer. 19 | 20 | uncompress returns Z_OK if success, Z_MEM_ERROR if there was not 21 | enough memory, Z_BUF_ERROR if there was not enough room in the output 22 | buffer, or Z_DATA_ERROR if the input data was corrupted. 23 | */ 24 | int ZEXPORT uncompress (dest, destLen, source, sourceLen) 25 | Bytef *dest; 26 | uLongf *destLen; 27 | const Bytef *source; 28 | uLong sourceLen; 29 | { 30 | z_stream stream; 31 | int err; 32 | 33 | stream.next_in = (Bytef*)source; 34 | stream.avail_in = (uInt)sourceLen; 35 | /* Check for source > 64K on 16-bit machine: */ 36 | if ((uLong)stream.avail_in != sourceLen) return Z_BUF_ERROR; 37 | 38 | stream.next_out = dest; 39 | stream.avail_out = (uInt)*destLen; 40 | if ((uLong)stream.avail_out != *destLen) return Z_BUF_ERROR; 41 | 42 | stream.zalloc = (alloc_func)0; 43 | stream.zfree = (free_func)0; 44 | 45 | err = inflateInit(&stream); 46 | if (err != Z_OK) return err; 47 | 48 | err = inflate(&stream, Z_FINISH); 49 | if (err != Z_STREAM_END) { 50 | inflateEnd(&stream); 51 | if (err == Z_NEED_DICT || (err == Z_BUF_ERROR && stream.avail_in == 0)) 52 | return Z_DATA_ERROR; 53 | return err; 54 | } 55 | *destLen = stream.total_out; 56 | 57 | err = inflateEnd(&stream); 58 | return err; 59 | } 60 | -------------------------------------------------------------------------------- /libretro-common/include/audio/dsp_filter.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (dsp_filter.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_AUDIO_DSP_FILTER_H 24 | #define __LIBRETRO_SDK_AUDIO_DSP_FILTER_H 25 | 26 | #include 27 | 28 | RETRO_BEGIN_DECLS 29 | 30 | typedef struct retro_dsp_filter retro_dsp_filter_t; 31 | 32 | retro_dsp_filter_t *retro_dsp_filter_new(const char *filter_config, 33 | void *string_data, float sample_rate); 34 | 35 | void retro_dsp_filter_free(retro_dsp_filter_t *dsp); 36 | 37 | struct retro_dsp_data 38 | { 39 | float *input; 40 | unsigned input_frames; 41 | 42 | /* Set by retro_dsp_filter_process(). */ 43 | float *output; 44 | unsigned output_frames; 45 | }; 46 | 47 | void retro_dsp_filter_process(retro_dsp_filter_t *dsp, 48 | struct retro_dsp_data *data); 49 | 50 | RETRO_END_DECLS 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /Makefile.common: -------------------------------------------------------------------------------- 1 | DEPS = $(CORE_DIR)/utils \ 2 | /libretro/db/entries.h 3 | 4 | LIBRETRO_COMM_DIR := $(CORE_DIR)/libretro-common 5 | 6 | INCFLAGS := \ 7 | -I$(CORE_DIR) \ 8 | -I$(CORE_DIR)/cap32 \ 9 | -I$(CORE_DIR)/libretro \ 10 | -I$(CORE_DIR)/libretro/microui \ 11 | -I$(LIBRETRO_COMM_DIR)/include 12 | 13 | SOURCES_C := \ 14 | $(CORE_DIR)/libretro/libretro-core.c \ 15 | $(CORE_DIR)/cap32/cap32.c \ 16 | $(CORE_DIR)/cap32/slots.c \ 17 | $(CORE_DIR)/cap32/crtc.c \ 18 | $(CORE_DIR)/cap32/fdc.c \ 19 | $(CORE_DIR)/cap32/psg.c \ 20 | $(CORE_DIR)/cap32/tape.c \ 21 | $(CORE_DIR)/cap32/cart.c \ 22 | $(CORE_DIR)/cap32/asic.c \ 23 | $(CORE_DIR)/cap32/z80.c \ 24 | $(CORE_DIR)/cap32/kbdauto.c \ 25 | $(CORE_DIR)/cap32/lightgun/gunstick.c \ 26 | $(CORE_DIR)/cap32/lightgun/phaser.c \ 27 | $(CORE_DIR)/libretro/microui/microui.c \ 28 | $(CORE_DIR)/libretro/db/database.c \ 29 | $(CORE_DIR)/libretro/dsk/loader.c \ 30 | $(CORE_DIR)/libretro/dsk/format.c \ 31 | $(CORE_DIR)/libretro/dsk/amsdos_catalog.c \ 32 | $(CORE_DIR)/libretro/gfx/software.c \ 33 | $(CORE_DIR)/libretro/gfx/video.c \ 34 | $(CORE_DIR)/libretro/gfx/video8bpp.c \ 35 | $(CORE_DIR)/libretro/gfx/video16bpp.c \ 36 | $(CORE_DIR)/libretro/gfx/video24bpp.c \ 37 | $(CORE_DIR)/libretro/assets/ui_keyboard_bg_crop.c \ 38 | $(CORE_DIR)/libretro/assets/ui_keyboard_bg.c \ 39 | $(CORE_DIR)/libretro/assets/ui_keyboard_en.c \ 40 | $(CORE_DIR)/libretro/assets/ui_keyboard_es.c \ 41 | $(CORE_DIR)/libretro/assets/ui_keyboard_fr.c \ 42 | $(CORE_DIR)/libretro/assets/font.c \ 43 | $(CORE_DIR)/libretro/retro_strings.c \ 44 | $(CORE_DIR)/libretro/retro_utils.c \ 45 | $(CORE_DIR)/libretro/retro_disk_control.c \ 46 | $(CORE_DIR)/libretro/retro_events.c \ 47 | $(CORE_DIR)/libretro/retro_snd.c \ 48 | $(CORE_DIR)/libretro/retro_render.c \ 49 | $(CORE_DIR)/libretro/retro_ui.c \ 50 | $(CORE_DIR)/libretro/retro_gun.c \ 51 | $(CORE_DIR)/libretro/retro_keyboard.c 52 | 53 | ifneq ($(STATIC_LINKING), 1) 54 | SOURCES_C += \ 55 | $(LIBRETRO_COMM_DIR)/file/file_path.c \ 56 | $(LIBRETRO_COMM_DIR)/string/stdstring.c \ 57 | $(LIBRETRO_COMM_DIR)/compat/compat_strl.c \ 58 | $(LIBRETRO_COMM_DIR)/encodings/encoding_utf.c \ 59 | $(LIBRETRO_COMM_DIR)/time/rtime.c \ 60 | $(LIBRETRO_COMM_DIR)/memmap/memalign.c 61 | endif 62 | -------------------------------------------------------------------------------- /libretro-common/include/math/fxp.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (fxp.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_MATH_FXP_H__ 24 | #define __LIBRETRO_SDK_MATH_FXP_H__ 25 | 26 | #include 27 | 28 | #ifdef _MSC_VER 29 | #include 30 | #endif 31 | 32 | #include 33 | 34 | static INLINE int64_t fx32_mul(const int32_t a, const int32_t b) 35 | { 36 | #ifdef _MSC_VER 37 | return __emul(a, b); 38 | #else 39 | return ((int64_t)a) * ((int64_t)b); 40 | #endif 41 | } 42 | 43 | static INLINE int32_t fx32_shiftdown(const int64_t a) 44 | { 45 | #ifdef _MSC_VER 46 | return (int32_t)__ll_rshift(a, 12); 47 | #else 48 | return (int32_t)(a >> 12); 49 | #endif 50 | } 51 | 52 | static INLINE int64_t fx32_shiftup(const int32_t a) 53 | { 54 | #ifdef _MSC_VER 55 | return __ll_lshift(a, 12); 56 | #else 57 | return ((int64_t)a) << 12; 58 | #endif 59 | } 60 | 61 | #endif 62 | -------------------------------------------------------------------------------- /utils/zlib/crc32.c: -------------------------------------------------------------------------------- 1 | /* crc32.c -- compute the CRC-32 of a data stream 2 | * Copyright (C) 1995-2006, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | * 5 | * Thanks to Rodney Brown for his contribution of faster 6 | * CRC methods: exclusive-oring 32 bits of data at a time, and pre-computing 7 | * tables for updating the shift register in one step with three exclusive-ors 8 | * instead of four steps with four exclusive-ors. This results in about a 9 | * factor of two increase in speed on a Power PC G4 (PPC7455) using gcc -O3. 10 | */ 11 | 12 | /* @(#) $Id$ */ 13 | 14 | #include "zutil.h" /* for STDC and FAR definitions */ 15 | 16 | #define local static 17 | 18 | #define TBLS 1 19 | 20 | /* Local functions for crc concatenation */ 21 | local unsigned long gf2_matrix_times OF((unsigned long *mat, 22 | unsigned long vec)); 23 | local void gf2_matrix_square OF((unsigned long *square, unsigned long *mat)); 24 | local uLong crc32_combine_(uLong crc1, uLong crc2, z_off64_t len2); 25 | 26 | 27 | /* ======================================================================== 28 | * Tables of CRC-32s of all single-byte values, made by make_crc_table(). 29 | */ 30 | #include "crc32.h" 31 | 32 | /* ========================================================================= 33 | * This function can be used by asm versions of crc32() 34 | */ 35 | const unsigned long FAR * ZEXPORT get_crc_table() 36 | { 37 | return (const unsigned long FAR *)crc_table; 38 | } 39 | 40 | /* ========================================================================= */ 41 | #define DO1 crc = crc_table[0][((int)crc ^ (*buf++)) & 0xff] ^ (crc >> 8) 42 | #define DO8 DO1; DO1; DO1; DO1; DO1; DO1; DO1; DO1 43 | 44 | /* ========================================================================= */ 45 | unsigned long ZEXPORT crc32(crc, buf, len) 46 | unsigned long crc; 47 | const unsigned char FAR *buf; 48 | uInt len; 49 | { 50 | if (buf == Z_NULL) return 0UL; 51 | crc = crc ^ 0xffffffffUL; 52 | while (len >= 8) { 53 | DO8; 54 | len -= 8; 55 | } 56 | if (len) do { 57 | DO1; 58 | } while (--len); 59 | return crc ^ 0xffffffffUL; 60 | } 61 | -------------------------------------------------------------------------------- /libretro/dsk/loader.h: -------------------------------------------------------------------------------- 1 | /**************************************************************************** 2 | * Caprice32 libretro port 3 | * 4 | * David Colmenero - D_Skywalk (2019-2021) 5 | * 6 | * Redistribution and use of this code or any derivative works are permitted 7 | * provided that the following conditions are met: 8 | * 9 | * - Redistributions may not be sold, nor may they be used in a commercial 10 | * product or activity. 11 | * 12 | * - Redistributions that are modified from the original source must include the 13 | * complete source code, including the source code for all components used by a 14 | * binary built from the modified sources. However, as a special exception, the 15 | * source code distributed need not include anything that is normally distributed 16 | * (in either source or binary form) with the major components (compiler, kernel, 17 | * and so on) of the operating system on which the executable runs, unless that 18 | * component itself accompanies the executable. 19 | * 20 | * - Redistributions must reproduce the above copyright notice, this list of 21 | * conditions and the following disclaimer in the documentation and/or other 22 | * materials provided with the distribution. 23 | * 24 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 25 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 26 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 27 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 28 | * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 29 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 30 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 31 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 32 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 33 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 34 | * POSSIBILITY OF SUCH DAMAGE. 35 | * 36 | ****************************************************************************************/ 37 | #ifndef GFX_LOADER_H__ 38 | #define GFX_LOADER_H__ 39 | 40 | void loader_run (char * text); 41 | 42 | #endif -------------------------------------------------------------------------------- /libretro-common/include/audio/conversion/float_to_s16.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2021 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (float_to_s16.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_CONVERSION_FLOAT_TO_S16_H__ 24 | #define __LIBRETRO_SDK_CONVERSION_FLOAT_TO_S16_H__ 25 | 26 | #include 27 | 28 | RETRO_BEGIN_DECLS 29 | 30 | #include 31 | #include 32 | 33 | /** 34 | * convert_float_to_s16: 35 | * @out : output buffer 36 | * @in : input buffer 37 | * @samples : size of samples to be converted 38 | * 39 | * Converts floating point 40 | * to signed integer 16-bit. 41 | **/ 42 | void convert_float_to_s16(int16_t *out, 43 | const float *in, size_t samples); 44 | 45 | /** 46 | * convert_float_to_s16_init_simd: 47 | * 48 | * Sets up function pointers for conversion 49 | * functions based on CPU features. 50 | **/ 51 | void convert_float_to_s16_init_simd(void); 52 | 53 | RETRO_END_DECLS 54 | 55 | #endif 56 | -------------------------------------------------------------------------------- /libretro-common/include/gfx/math/vector_4.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (vector_4.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_GFX_MATH_VECTOR_4_H__ 24 | #define __LIBRETRO_SDK_GFX_MATH_VECTOR_4_H__ 25 | 26 | #include 27 | #include 28 | 29 | #include 30 | 31 | RETRO_BEGIN_DECLS 32 | 33 | typedef float vec4_t[4]; 34 | 35 | #define vec4_add(dst, src) \ 36 | dst[0] += src[0]; \ 37 | dst[1] += src[1]; \ 38 | dst[2] += src[2]; \ 39 | dst[3] += src[3] 40 | 41 | #define vec4_subtract(dst, src) \ 42 | dst[0] -= src[0]; \ 43 | dst[1] -= src[1]; \ 44 | dst[2] -= src[2]; \ 45 | dst[3] -= src[3] 46 | 47 | #define vec4_scale(dst, scale) \ 48 | dst[0] *= scale; \ 49 | dst[1] *= scale; \ 50 | dst[2] *= scale; \ 51 | dst[3] *= scale 52 | 53 | #define vec4_copy(dst, src) \ 54 | dst[0] = src[0]; \ 55 | dst[1] = src[1]; \ 56 | dst[2] = src[2]; \ 57 | dst[3] = src[3] 58 | 59 | RETRO_END_DECLS 60 | 61 | #endif 62 | -------------------------------------------------------------------------------- /libretro-common/rthreads/xenon_sdl_threads.c: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (xenon_sdl_threads.c). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | /* libSDLxenon doesn't implement this yet :[. Implement it very stupidly for now. ;) */ 24 | 25 | #include "SDL_thread.h" 26 | #include "SDL_mutex.h" 27 | #include 28 | #include 29 | 30 | SDL_cond *SDL_CreateCond(void) 31 | { 32 | bool *sleeping = calloc(1, sizeof(*sleeping)); 33 | return (SDL_cond*)sleeping; 34 | } 35 | 36 | void SDL_DestroyCond(SDL_cond *sleeping) 37 | { 38 | free(sleeping); 39 | } 40 | 41 | int SDL_CondWait(SDL_cond *cond, SDL_mutex *lock) 42 | { 43 | (void)lock; 44 | volatile bool *sleeping = (volatile bool*)cond; 45 | 46 | SDL_mutexV(lock); 47 | *sleeping = true; 48 | while (*sleeping); /* Yeah, we all love busyloops don't we? ._. */ 49 | SDL_mutexP(lock); 50 | 51 | return 0; 52 | } 53 | 54 | int SDL_CondSignal(SDL_cond *cond) 55 | { 56 | *(volatile bool*)cond = false; 57 | return 0; 58 | } 59 | -------------------------------------------------------------------------------- /libretro-common/include/memmap.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (memmap.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef _LIBRETRO_MEMMAP_H 24 | #define _LIBRETRO_MEMMAP_H 25 | 26 | #include 27 | #include 28 | 29 | #if defined(PSP) || defined(PS2) || defined(GEKKO) || defined(VITA) || defined(_XBOX) || defined(_3DS) || defined(WIIU) || defined(SWITCH) || defined(HAVE_LIBNX) || defined(__PS3__) || defined(__PSL1GHT__) 30 | /* No mman available */ 31 | #elif defined(_WIN32) && !defined(_XBOX) 32 | #include 33 | #include 34 | #include 35 | #else 36 | #define HAVE_MMAN 37 | #include 38 | #endif 39 | 40 | #if !defined(HAVE_MMAN) || defined(_WIN32) 41 | void* mmap(void *addr, size_t len, int mmap_prot, int mmap_flags, int fildes, size_t off); 42 | 43 | int munmap(void *addr, size_t len); 44 | 45 | int mprotect(void *addr, size_t len, int prot); 46 | #endif 47 | 48 | int memsync(void *start, void *end); 49 | 50 | int memprotect(void *addr, size_t len); 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /libretro-common/include/compat/strl.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (strl.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #ifndef __LIBRETRO_SDK_COMPAT_STRL_H 24 | #define __LIBRETRO_SDK_COMPAT_STRL_H 25 | 26 | #include 27 | #include 28 | 29 | #if defined(RARCH_INTERNAL) && defined(HAVE_CONFIG_H) 30 | #include "../../../config.h" 31 | #endif 32 | 33 | #include 34 | 35 | RETRO_BEGIN_DECLS 36 | 37 | #ifdef __MACH__ 38 | #ifndef HAVE_STRL 39 | #define HAVE_STRL 40 | #endif 41 | #endif 42 | 43 | #ifndef HAVE_STRL 44 | /* Avoid possible naming collisions during link since 45 | * we prefer to use the actual name. */ 46 | #define strlcpy(dst, src, size) strlcpy_retro__(dst, src, size) 47 | 48 | #define strlcat(dst, src, size) strlcat_retro__(dst, src, size) 49 | 50 | size_t strlcpy(char *dest, const char *source, size_t size); 51 | size_t strlcat(char *dest, const char *source, size_t size); 52 | 53 | #endif 54 | 55 | char *strldup(const char *s, size_t n); 56 | 57 | RETRO_END_DECLS 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /libretro-common/compat/compat_strcasestr.c: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2020 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (compat_strcasestr.c). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | 23 | #include 24 | 25 | #include 26 | 27 | /* Pretty much strncasecmp. */ 28 | static int casencmp(const char *a, const char *b, size_t n) 29 | { 30 | size_t i; 31 | 32 | for (i = 0; i < n; i++) 33 | { 34 | int a_lower = tolower(a[i]); 35 | int b_lower = tolower(b[i]); 36 | if (a_lower != b_lower) 37 | return a_lower - b_lower; 38 | } 39 | 40 | return 0; 41 | } 42 | 43 | char *strcasestr_retro__(const char *haystack, const char *needle) 44 | { 45 | size_t i, search_off; 46 | size_t hay_len = strlen(haystack); 47 | size_t needle_len = strlen(needle); 48 | 49 | if (needle_len > hay_len) 50 | return NULL; 51 | 52 | search_off = hay_len - needle_len; 53 | for (i = 0; i <= search_off; i++) 54 | if (!casencmp(haystack + i, needle, needle_len)) 55 | return (char*)haystack + i; 56 | 57 | return NULL; 58 | } 59 | -------------------------------------------------------------------------------- /libretro-common/include/audio/conversion/s16_to_float.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2021 The RetroArch team 2 | * 3 | * --------------------------------------------------------------------------------------- 4 | * The following license statement only applies to this file (s16_to_float.h). 5 | * --------------------------------------------------------------------------------------- 6 | * 7 | * Permission is hereby granted, free of charge, 8 | * to any person obtaining a copy of this software and associated documentation files (the "Software"), 9 | * to deal in the Software without restriction, including without limitation the rights to 10 | * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, 11 | * and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 16 | * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 18 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 19 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | */ 22 | #ifndef __LIBRETRO_SDK_CONVERSION_S16_TO_FLOAT_H__ 23 | #define __LIBRETRO_SDK_CONVERSION_S16_TO_FLOAT_H__ 24 | 25 | #include 26 | #include 27 | 28 | #include 29 | 30 | RETRO_BEGIN_DECLS 31 | 32 | /** 33 | * convert_s16_to_float: 34 | * @out : output buffer 35 | * @in : input buffer 36 | * @samples : size of samples to be converted 37 | * @gain : gain applied (.e.g. audio volume) 38 | * 39 | * Converts from signed integer 16-bit 40 | * to floating point. 41 | **/ 42 | void convert_s16_to_float(float *out, 43 | const int16_t *in, size_t samples, float gain); 44 | 45 | /** 46 | * convert_s16_to_float_init_simd: 47 | * 48 | * Sets up function pointers for conversion 49 | * functions based on CPU features. 50 | **/ 51 | void convert_s16_to_float_init_simd(void); 52 | 53 | RETRO_END_DECLS 54 | 55 | #endif 56 | --------------------------------------------------------------------------------