introduce fractional framerates
[pcsx_rearmed.git] / frontend / libretro_core_options.h
CommitLineData
919cac88 1#ifndef LIBRETRO_CORE_OPTIONS_H__
2#define LIBRETRO_CORE_OPTIONS_H__
3
4#include <stdlib.h>
5#include <string.h>
6
7#include <libretro.h>
8#include <retro_inline.h>
9
fbe06628 10#ifndef HAVE_NO_LANGEXTRA
11#include "libretro_core_options_intl.h"
12#endif
13
14/*
15 ********************************
f3c6ae10 16 * VERSION: 2.0
fbe06628 17 ********************************
18 *
f3c6ae10 19 * - 2.0: Add support for core options v2 interface
fbe06628 20 * - 1.3: Move translations to libretro_core_options_intl.h
21 * - libretro_core_options_intl.h includes BOM and utf-8
22 * fix for MSVC 2010-2013
23 * - Added HAVE_NO_LANGEXTRA flag to disable translations
24 * on platforms/compilers without BOM support
25 * - 1.2: Use core options v1 interface when
26 * RETRO_ENVIRONMENT_GET_CORE_OPTIONS_VERSION is >= 1
27 * (previously required RETRO_ENVIRONMENT_GET_CORE_OPTIONS_VERSION == 1)
28 * - 1.1: Support generation of core options v0 retro_core_option_value
29 * arrays containing options with a single value
30 * - 1.0: First commit
31*/
32
919cac88 33#ifdef __cplusplus
34extern "C" {
35#endif
36
37/*
38 ********************************
39 * Core Option Definitions
40 ********************************
41*/
42
43/* RETRO_LANGUAGE_ENGLISH */
44
45/* Default language:
46 * - All other languages must include the same keys and values
47 * - Will be used as a fallback in the event that frontend language
48 * is not available
49 * - Will be used as a fallback for any missing entries in
50 * frontend language definition
51 */
52
f3c6ae10 53struct retro_core_option_v2_category option_cats_us[] = {
5201e92f 54 {
f3c6ae10 55 "system",
56 "System",
57 "Configure base hardware parameters: region, BIOS selection, memory cards, etc."
5eaa13f1
A
58 },
59 {
f3c6ae10 60 "video",
61 "Video",
62 "Configure base display parameters."
5eaa13f1 63 },
f3c6ae10 64#ifdef GPU_NEON
5eaa13f1 65 {
f3c6ae10 66 "gpu_neon",
67 "GPU Plugin",
68 "Configure low-level settings of the NEON GPU plugin."
919cac88 69 },
f3c6ae10 70#endif
71#ifdef GPU_PEOPS
919cac88 72 {
f3c6ae10 73 "gpu_peops",
74 "GPU Plugin (Advanced)",
75 "Configure low-level settings of the P.E.Op.S. GPU plugin."
919cac88 76 },
f3c6ae10 77#endif
78#ifdef GPU_UNAI
919cac88 79 {
f3c6ae10 80 "gpu_unai",
81 "GPU Plugin (Advanced)",
82 "Configure low-level settings of the UNAI GPU plugin."
919cac88 83 },
f3c6ae10 84#endif
919cac88 85 {
f3c6ae10 86 "audio",
87 "Audio",
88 "Configure sound emulation: reverb, interpolation, CD audio decoding."
ce239f4a 89 },
90 {
f3c6ae10 91 "input",
92 "Input",
93 "Configure input devices: analog response, haptic feedback, Multitaps, light guns, etc."
919cac88 94 },
399a33fe 95 {
f3c6ae10 96 "compat_hack",
97 "Compatibility Fixes",
98 "Configure settings/workarounds required for correct operation of specific games."
919cac88 99 },
f3c6ae10 100#if !defined(DRC_DISABLE) && !defined(LIGHTREC)
919cac88 101 {
f3c6ae10 102 "speed_hack",
103 "Speed Hacks (Advanced)",
104 "Configure hacks that may improve performance at the expense of decreased accuracy/stability."
919cac88 105 },
f3c6ae10 106#endif
107 { NULL, NULL, NULL },
108};
109
110struct retro_core_option_v2_definition option_defs_us[] = {
919cac88 111 {
f3c6ae10 112 "pcsx_rearmed_region",
113 "Region",
114 NULL,
115 "Specify which region the system is from. 'NTSC' is 60 Hz while 'PAL' is 50 Hz. 'Auto' will detect the region of the currently loaded content. Games may run faster or slower than normal if the incorrect region is selected.",
116 NULL,
117 "system",
919cac88 118 {
f3c6ae10 119 { "auto", "Auto" },
120 { "NTSC", NULL },
121 { "PAL", NULL },
fbe06628 122 { NULL, NULL },
919cac88 123 },
f3c6ae10 124 "auto",
919cac88 125 },
ace1989f 126 {
f3c6ae10 127 "pcsx_rearmed_bios",
128 "BIOS Selection",
129 NULL,
130 "Specify which BIOS to use. 'Auto' will attempt to load a real bios file from the frontend 'system' directory, falling back to high level emulation if unavailable. 'HLE' forces high level BIOS emulation. It is recommended to use an official bios file for better compatibility.",
131 NULL,
132 "system",
ace1989f 133 {
f3c6ae10 134 { "auto", "Auto" },
135 { "HLE", NULL },
ace1989f
SK
136 { NULL, NULL },
137 },
f3c6ae10 138 "auto",
ace1989f 139 },
919cac88 140 {
f3c6ae10 141 "pcsx_rearmed_show_bios_bootlogo",
142 "Show BIOS Boot Logo",
143 NULL,
144 "When using an official BIOS file, specify whether to show the PlayStation logo upon starting or resetting content. Warning: Enabling the boot logo may reduce game compatibility.",
145 NULL,
146 "system",
919cac88 147 {
148 { "disabled", NULL },
149 { "enabled", NULL },
fbe06628 150 { NULL, NULL },
919cac88 151 },
f3c6ae10 152 "disabled",
000655e4
S
153 },
154 {
f3c6ae10 155 "pcsx_rearmed_memcard2",
156 "Enable Second Memory Card (Shared)",
157 NULL,
158 "Emulate a second memory card in slot 2. This will be shared by all games.",
159 NULL,
160 "system",
000655e4 161 {
f3c6ae10 162 { "disabled", NULL },
163 { "enabled", NULL },
000655e4
S
164 { NULL, NULL },
165 },
f3c6ae10 166 "disabled",
000655e4 167 },
9f47c8ed 168#if 0 // ndef _WIN32 // currently disabled, see USE_READ_THREAD in libpcsxcore/cdriso.c
000655e4 169 {
f3c6ae10 170 "pcsx_rearmed_async_cd",
171 "CD Access Method (Restart)",
172 NULL,
173 "Select method used to read data from content disk images. 'Synchronous' mimics original hardware. 'Asynchronous' can reduce stuttering on devices with slow storage. 'Pre-Cache (CHD)' loads disk image into memory for faster access (CHD files only).",
174 NULL,
175 "system",
000655e4 176 {
f3c6ae10 177 { "sync", "Synchronous" },
178 { "async", "Asynchronous" },
179 { "precache", "Pre-Cache (CHD)" },
180 { NULL, NULL},
000655e4 181 },
f3c6ae10 182 "sync",
000655e4 183 },
12367ad0 184#endif
639a3501 185#ifdef HAVE_CDROM
186#define V(x) { #x, NULL }
187 {
188 "pcsx_rearmed_phys_cd_readahead",
189 "Physical CD read-ahead",
190 NULL,
191 "(Hardware CD-ROM only) Reads the specified amount of sectors ahead of time to try to avoid later stalls. 333000 will try to read the complete disk (requires an additional 750MB of RAM).",
192 NULL,
193 "system",
194 {
195 V(0), V(1), V(2), V(3), V(4), V(5), V(6), V(7),
196 V(8), V(9), V(10), V(11), V(12), V(13), V(14), V(15),
197 V(16), V(32), V(64), V(128), V(256), V(512), V(1024), V(333000),
198 { NULL, NULL},
199 },
200 "12",
201 },
202#undef V
203#endif
630b122b 204#ifndef DRC_DISABLE
919cac88 205 {
206 "pcsx_rearmed_drc",
c8108d88 207 "Dynamic Recompiler",
f3c6ae10 208 NULL,
209 "Dynamically recompile PSX CPU instructions to native instructions. Much faster than using an interpreter, but may be less accurate on some platforms.",
210 NULL,
211 "system",
919cac88 212 {
213 { "disabled", NULL },
214 { "enabled", NULL },
fbe06628 215 { NULL, NULL },
919cac88 216 },
217 "enabled",
218 },
630b122b 219#endif
919cac88 220 {
221 "pcsx_rearmed_psxclock",
016c6e93 222 "PSX CPU Clock Speed (%)",
f3c6ae10 223 NULL,
016c6e93 224 "Overclock or under-clock the PSX CPU. The value has to be lower than 100 because of some slowdowns (cache misses, hw access penalties, etc.) that are not emulated. Try adjusting this if the game is too slow, too fast or hangs."
44e8d7af 225#if defined(HAVE_PRE_ARMV7) && !defined(_3DS)
86be2515 226 " Default is 50."
fbe06628 227#else
86be2515 228 " Default is 57."
fbe06628 229#endif
86be2515 230 ,
f3c6ae10 231 NULL,
232 "system",
919cac88 233 {
fbe06628 234 { "30", NULL },
235 { "31", NULL },
236 { "32", NULL },
237 { "33", NULL },
238 { "34", NULL },
239 { "35", NULL },
240 { "36", NULL },
241 { "37", NULL },
242 { "38", NULL },
243 { "39", NULL },
244 { "40", NULL },
245 { "41", NULL },
246 { "42", NULL },
247 { "43", NULL },
248 { "44", NULL },
249 { "45", NULL },
250 { "46", NULL },
251 { "47", NULL },
252 { "48", NULL },
253 { "49", NULL },
254 { "50", NULL },
255 { "51", NULL },
256 { "52", NULL },
257 { "53", NULL },
258 { "54", NULL },
259 { "55", NULL },
260 { "56", NULL },
261 { "57", NULL },
262 { "58", NULL },
263 { "59", NULL },
264 { "60", NULL },
265 { "61", NULL },
266 { "62", NULL },
267 { "63", NULL },
268 { "64", NULL },
269 { "65", NULL },
270 { "66", NULL },
271 { "67", NULL },
272 { "68", NULL },
273 { "69", NULL },
274 { "70", NULL },
275 { "71", NULL },
276 { "72", NULL },
277 { "73", NULL },
278 { "74", NULL },
279 { "75", NULL },
280 { "76", NULL },
281 { "77", NULL },
282 { "78", NULL },
283 { "79", NULL },
284 { "80", NULL },
285 { "81", NULL },
286 { "82", NULL },
287 { "83", NULL },
288 { "84", NULL },
289 { "85", NULL },
290 { "86", NULL },
291 { "87", NULL },
292 { "88", NULL },
293 { "89", NULL },
294 { "90", NULL },
295 { "91", NULL },
296 { "92", NULL },
297 { "93", NULL },
298 { "94", NULL },
299 { "95", NULL },
300 { "96", NULL },
301 { "97", NULL },
302 { "98", NULL },
303 { "99", NULL },
919cac88 304 { "100", NULL },
fbe06628 305 { NULL, NULL },
919cac88 306 },
44e8d7af 307#if defined(HAVE_PRE_ARMV7) && !defined(_3DS)
fbe06628 308 "50",
309#else
310 "57",
311#endif
919cac88 312 },
919cac88 313 {
f3c6ae10 314 "pcsx_rearmed_dithering",
315 "Dithering Pattern",
316 NULL,
317 "Enable emulation of the dithering technique used by the PSX to smooth out color banding artifacts. Increases performance requirements.",
318 NULL,
319 "video",
320 {
321 { "disabled", NULL },
322 { "enabled", NULL },
323 { NULL, NULL },
324 },
325#if defined HAVE_LIBNX || defined _3DS
326 "disabled",
327#else
328 "enabled",
329#endif
330 },
f3c6ae10 331#ifdef THREAD_RENDERING
332 {
333 "pcsx_rearmed_gpu_thread_rendering",
334 "Threaded Rendering",
335 NULL,
336 "When enabled, runs GPU commands in a secondary thread. 'Synchronous' improves performance while maintaining proper frame pacing. 'Asynchronous' improves performance even further, but may cause dropped frames and increased latency. Produces best results with games that run natively at less than 60 frames per second.",
337 NULL,
338 "video",
339 {
340 { "disabled", NULL },
341 { "sync", "Synchronous" },
342 { "async", "Asynchronous" },
343 { NULL, NULL},
344 },
345 "disabled",
346 },
347#endif
348 {
349 "pcsx_rearmed_frameskip_type",
350 "Frameskip",
351 NULL,
352 "Skip frames to avoid audio buffer under-run (crackling). Improves performance at the expense of visual smoothness. 'Auto' skips frames when advised by the frontend. 'Auto (Threshold)' utilises the 'Frameskip Threshold (%)' setting. 'Fixed Interval' utilises the 'Frameskip Interval' setting.",
353 NULL,
354 "video",
355 {
356 { "disabled", NULL },
357 { "auto", "Auto" },
358 { "auto_threshold", "Auto (Threshold)" },
359 { "fixed_interval", "Fixed Interval" },
360 { NULL, NULL },
361 },
362 "disabled"
363 },
364 {
365 "pcsx_rearmed_frameskip_threshold",
366 "Frameskip Threshold (%)",
367 NULL,
368 "When 'Frameskip' is set to 'Auto (Threshold)', specifies the audio buffer occupancy threshold (percentage) below which frames will be skipped. Higher values reduce the risk of crackling by causing frames to be dropped more frequently.",
369 NULL,
370 "video",
371 {
372 { "15", NULL },
373 { "18", NULL },
374 { "21", NULL },
375 { "24", NULL },
376 { "27", NULL },
377 { "30", NULL },
378 { "33", NULL },
379 { "36", NULL },
380 { "39", NULL },
381 { "42", NULL },
382 { "45", NULL },
383 { "48", NULL },
384 { "51", NULL },
385 { "54", NULL },
386 { "57", NULL },
387 { "60", NULL },
388 { NULL, NULL },
389 },
390 "33"
391 },
392 {
393 "pcsx_rearmed_frameskip_interval",
394 "Frameskip Interval",
395 NULL,
396 "Specify the maximum number of frames that can be skipped before a new frame is rendered.",
397 NULL,
398 "video",
399 {
400 { "1", NULL },
401 { "2", NULL },
402 { "3", NULL },
403 { "4", NULL },
404 { "5", NULL },
405 { "6", NULL },
406 { "7", NULL },
407 { "8", NULL },
408 { "9", NULL },
409 { "10", NULL },
410 { NULL, NULL },
411 },
412 "3"
919cac88 413 },
414 {
f3c6ae10 415 "pcsx_rearmed_display_internal_fps",
416 "Display Internal FPS",
417 NULL,
418 "Show the internal frame rate at which the emulated PlayStation system is rendering content. Note: Requires on-screen notifications to be enabled in the libretro frontend.",
419 NULL,
420 "video",
919cac88 421 {
422 { "disabled", NULL },
423 { "enabled", NULL },
fbe06628 424 { NULL, NULL },
919cac88 425 },
426 "disabled",
427 },
2f326fa1 428 {
429 "pcsx_rearmed_fractional_framerate",
430 "Use fractional frame rate",
431 NULL,
432 "Instead of the exact 50 or 60 (maximum) fps for PAL/NTSC the real console runs closer to something like 49.75 and 59.81fps (varies slightly between hw versions). PCSX-ReARMed uses the former \"round\" framerates to better match modern displays, however that may cause audio/video desync in games like DDR and Spyro 2 (intro). With this option you can try to use fractional framerates.",
433 NULL,
434 "video",
435 {
436 { "auto", "Auto" },
437 { "disabled", NULL },
438 { "enabled", NULL },
439 { NULL, NULL },
440 },
441 "auto",
442 },
fae38d7a 443 {
444 "pcsx_rearmed_gpu_slow_llists",
445 "(GPU) Slow linked list processing",
446 NULL,
447 "Slower but more accurate GPU linked list processing. Needed by only a few games like Vampire Hunter D. Should be autodetected in most cases.",
448 NULL,
449 "video",
450 {
2f326fa1 451 { "auto", "Auto" },
fae38d7a 452 { "disabled", NULL },
453 { "enabled", NULL },
454 { NULL, NULL },
455 },
456 "auto",
457 },
5bbe183f 458 {
459 "pcsx_rearmed_screen_centering",
460 "(GPU) Screen centering",
461 NULL,
8f8ade9c 462 "The PSX has a feature allowing it to shift the image position on screen. Some (mostly PAL) games used this feature in a strange way making the image miscentered and causing uneven borders to appear. With 'Auto' the emulator tries to correct this miscentering automatically. 'Game-controlled' uses the settings supplied by the game. 'Manual' allows to override those values with the settings below.",
5bbe183f 463 NULL,
464 "video",
465 {
466 { "auto", "Auto" },
467 { "game", "Game-controlled" },
8f8ade9c 468 { "borderless", "Borderless" },
5bbe183f 469 { "manual", "Manual" },
470 { NULL, NULL },
471 },
472 "auto",
473 },
474#define V(x) { #x, NULL }
475 {
476 "pcsx_rearmed_screen_centering_x",
477 "(GPU) Manual screen centering X",
478 NULL,
479 "X offset of the frame buffer. Only effective when 'Screen centering' is set to 'Manual'.",
480 NULL,
481 "video",
482 {
483 V(-16), V(-14), V(-12), V(-10), V(-8), V(-6), V(-4), V(-2), V(0), V(2), V(4), V(6), V(8), V(10), V(12), V(14), V(16),
484 { NULL, NULL },
485 },
486 "0",
487 },
488 {
489 "pcsx_rearmed_screen_centering_y",
490 "(GPU) Manual screen centering Y",
491 NULL,
492 "Y offset of the frame buffer. Only effective when 'Screen centering' is set to 'Manual'.",
493 NULL,
494 "video",
495 {
496 V(-16), V(-15), V(-14), V(-13), V(-12), V(-11), V(-10), V(-9), V(-8), V(-7), V(-6), V(-5), V(-4), V(-3), V(-2), V(-1),
497 V(0), V(1), V(2), V(3), V(4), V(5), V(6), V(7), V(8), V(9), V(10), V(11), V(12), V(13), V(14), V(15), V(16),
498 { NULL, NULL },
499 },
500 "0",
501 },
502#undef V
f3c6ae10 503#ifdef GPU_NEON
919cac88 504 {
3c53dce3 505 "pcsx_rearmed_neon_interlace_enable_v2",
f3c6ae10 506 "(GPU) Show Interlaced Video",
507 "Show Interlaced Video",
3c53dce3 508 "When enabled, games that run in high resolution video modes (480i, 512i) will produced interlaced video output. While this displays correctly on CRT televisions, it will produce artifacts on modern displays. When disabled, all video is output in progressive format. Note: there are games that will glitch is this is off.",
f3c6ae10 509 NULL,
510 "gpu_neon",
919cac88 511 {
3c53dce3 512 { "auto", NULL },
919cac88 513 { "disabled", NULL },
514 { "enabled", NULL },
fbe06628 515 { NULL, NULL },
919cac88 516 },
3c53dce3 517 "auto",
919cac88 518 },
919cac88 519 {
f3c6ae10 520 "pcsx_rearmed_neon_enhancement_enable",
1e766b53 521 "(GPU) Enhanced Resolution",
522 "Enhanced Resolution",
f3c6ae10 523 "Render games that do not already run in high resolution video modes (480i, 512i) at twice the native internal resolution. Improves the fidelity of 3D models at the expense of increased performance requirements. 2D elements are generally unaffected by this setting.",
524 NULL,
525 "gpu_neon",
919cac88 526 {
527 { "disabled", NULL },
528 { "enabled", NULL },
fbe06628 529 { NULL, NULL },
919cac88 530 },
f3c6ae10 531 "disabled",
919cac88 532 },
533 {
f3c6ae10 534 "pcsx_rearmed_neon_enhancement_no_main",
535 "(GPU) Enhanced Resolution Speed Hack",
536 "Enhanced Resolution Speed Hack",
5ee1c926 537 "('Enhanced Resolution' Hack) Improves performance but reduces compatibility and may cause rendering errors.",
f3c6ae10 538 NULL,
539 "gpu_neon",
919cac88 540 {
541 { "disabled", NULL },
542 { "enabled", NULL },
fbe06628 543 { NULL, NULL },
919cac88 544 },
545 "disabled",
546 },
af1601fa 547 {
548 "pcsx_rearmed_neon_enhancement_tex_adj",
549 "(GPU) Enhanced Resolution Texture Adjustment",
550 "Enhanced Resolution Texture Adjustment",
5ee1c926 551 "('Enhanced Resolution' Hack) Attempts to solve some texturing issues in some games, but causes new ones in others.",
af1601fa 552 NULL,
553 "gpu_neon",
554 {
555 { "disabled", NULL },
556 { "enabled", NULL },
557 { NULL, NULL },
558 },
559 "disabled",
560 },
f3c6ae10 561#endif /* GPU_NEON */
2d17de26 562#ifdef GPU_PEOPS
c8108d88 563 {
564 "pcsx_rearmed_show_gpu_peops_settings",
f3c6ae10 565 "Show Advanced P.E.Op.S. GPU Settings",
566 NULL,
567 "Show low-level configuration options for the P.E.Op.S. GPU plugin. Quick Menu may need to be toggled for this setting to take effect.",
568 NULL,
569 NULL,
c8108d88 570 {
571 { "disabled", NULL },
572 { "enabled", NULL },
fbe06628 573 { NULL, NULL },
c8108d88 574 },
575 "disabled",
576 },
577 {
6713b629 578 "pcsx_rearmed_gpu_peops_odd_even_bit",
c8108d88 579 "(GPU) Odd/Even Bit Hack",
f3c6ae10 580 "Odd/Even Bit Hack",
581 "A hack fix used to correct lock-ups that may occur in games such as Chrono Cross. Disable unless required.",
582 NULL,
583 "gpu_peops",
c8108d88 584 {
585 { "disabled", NULL },
586 { "enabled", NULL },
fbe06628 587 { NULL, NULL },
c8108d88 588 },
589 "disabled",
590 },
591 {
6713b629 592 "pcsx_rearmed_gpu_peops_expand_screen_width",
c8108d88 593 "(GPU) Expand Screen Width",
f3c6ae10 594 "Expand Screen Width",
595 "Intended for use only with Capcom 2D fighting games. Enlarges the display area at the right side of the screen to show all background elements without cut-off. May cause rendering errors.",
596 NULL,
597 "gpu_peops",
c8108d88 598 {
599 { "disabled", NULL },
600 { "enabled", NULL },
fbe06628 601 { NULL, NULL },
c8108d88 602 },
603 "disabled",
604 },
605 {
6713b629 606 "pcsx_rearmed_gpu_peops_ignore_brightness",
c8108d88 607 "(GPU) Ignore Brightness Color",
f3c6ae10 608 "Ignore Brightness Color",
609 "A hack fix used to repair black screens in Lunar Silver Star Story Complete when entering a house or a menu. Disable unless required.",
610 NULL,
611 "gpu_peops",
c8108d88 612 {
613 { "disabled", NULL },
614 { "enabled", NULL },
fbe06628 615 { NULL, NULL },
c8108d88 616 },
617 "disabled",
618 },
619 {
6713b629 620 "pcsx_rearmed_gpu_peops_disable_coord_check",
c8108d88 621 "(GPU) Disable Coordinate Check",
f3c6ae10 622 "Disable Coordinate Check",
623 "Legacy compatibility mode. May improve games that fail to run correctly on newer GPU hardware. Disable unless required.",
624 NULL,
625 "gpu_peops",
c8108d88 626 {
627 { "disabled", NULL },
628 { "enabled", NULL },
fbe06628 629 { NULL, NULL },
c8108d88 630 },
631 "disabled",
632 },
633 {
6713b629 634 "pcsx_rearmed_gpu_peops_lazy_screen_update",
c8108d88 635 "(GPU) Lazy Screen Update",
f3c6ae10 636 "Lazy Screen Update",
637 "A partial fix to prevent text box flickering in Dragon Warrior VII. May also improve Pandemonium 2. Disable unless required.",
638 NULL,
639 "gpu_peops",
c8108d88 640 {
641 { "disabled", NULL },
642 { "enabled", NULL },
fbe06628 643 { NULL, NULL },
c8108d88 644 },
645 "disabled",
646 },
c8108d88 647 {
6713b629 648 "pcsx_rearmed_gpu_peops_repeated_triangles",
f3c6ae10 649 "(GPU) Repeat Flat Tex Triangles",
650 "Repeat Flat Tex Triangles",
651 "A hack fix used to correct rendering errors in Star Wars: Dark Forces. Disable unless required.",
652 NULL,
653 "gpu_peops",
c8108d88 654 {
655 { "disabled", NULL },
656 { "enabled", NULL },
fbe06628 657 { NULL, NULL },
c8108d88 658 },
659 "disabled",
660 },
661 {
6713b629 662 "pcsx_rearmed_gpu_peops_quads_with_triangles",
f3c6ae10 663 "(GPU) Draw Tex-Quads as Triangles",
664 "Draw Tex-Quads as Triangles",
665 "Corrects graphical distortions that may occur when games utilize Gouraud Shading, at the expense of reduced texture quality. Disable unless required.",
666 NULL,
667 "gpu_peops",
c8108d88 668 {
669 { "disabled", NULL },
670 { "enabled", NULL },
fbe06628 671 { NULL, NULL },
c8108d88 672 },
673 "disabled",
674 },
675 {
6713b629 676 "pcsx_rearmed_gpu_peops_fake_busy_state",
f3c6ae10 677 "(GPU) Fake 'GPU Busy' States",
678 "Fake 'GPU Busy' States",
679 "Emulate the 'GPU is busy' (drawing primitives) status flag of the original hardware instead of assuming the GPU is always ready for commands. May improve compatibility at the expense of reduced performance. Disable unless required.",
680 NULL,
681 "gpu_peops",
c8108d88 682 {
683 { "disabled", NULL },
684 { "enabled", NULL },
fbe06628 685 { NULL, NULL },
c8108d88 686 },
687 "disabled",
688 },
f3c6ae10 689#endif /* GPU_PEOPS */
030d1121 690#ifdef GPU_UNAI
691 {
692 "pcsx_rearmed_show_gpu_unai_settings",
f3c6ae10 693 "Show Advanced UNAI GPU Settings",
694 NULL,
695 "Show low-level configuration options for the UNAI GPU plugin. Quick Menu may need to be toggled for this setting to take effect.",
696 NULL,
697 NULL,
030d1121 698 {
699 { "disabled", NULL },
700 { "enabled", NULL },
701 { NULL, NULL},
702 },
703 "disabled",
704 },
705 {
706 "pcsx_rearmed_gpu_unai_blending",
f3c6ae10 707 "(GPU) Texture Blending",
708 "Texture Blending",
709 "Enable alpha-based (and additive) texture blending. Required for various rendering effects, including transparency (e.g. water, shadows). Can be disabled to improve performance at the expense of severe display errors/inaccuracies.",
030d1121 710 NULL,
f3c6ae10 711 "gpu_unai",
030d1121 712 {
713 { "disabled", NULL },
714 { "enabled", NULL },
715 { NULL, NULL},
716 },
717 "enabled",
718 },
719 {
720 "pcsx_rearmed_gpu_unai_lighting",
f3c6ae10 721 "(GPU) Lighting Effects",
722 "Lighting Effects",
723 "Enable simulated lighting effects (via vertex coloring combined with texture mapping). Required by almost all 3D games. Can be disabled to improve performance at the expense of severe display errors/inaccuracies (missing shadows, flat textures, etc.).",
030d1121 724 NULL,
f3c6ae10 725 "gpu_unai",
030d1121 726 {
727 { "disabled", NULL },
728 { "enabled", NULL },
729 { NULL, NULL},
730 },
731 "enabled",
732 },
733 {
734 "pcsx_rearmed_gpu_unai_fast_lighting",
f3c6ae10 735 "(GPU) Fast Lighting",
736 "Fast Lighting",
737 "Improves performance when 'Lighting Effects' are enabled, but may cause moderate/severe rendering errors.",
030d1121 738 NULL,
f3c6ae10 739 "gpu_unai",
030d1121 740 {
741 { "disabled", NULL },
742 { "enabled", NULL },
743 { NULL, NULL},
744 },
6725614d 745 "disabled",
030d1121 746 },
747 {
f3c6ae10 748 "pcsx_rearmed_gpu_unai_scale_hires",
749 "(GPU) Hi-Res Downscaling",
750 "Hi-Res Downscaling",
751 "When enabled, games that run in high resolution video modes (480i, 512i) will be downscaled to 320x240. Can improve performance, and is recommended on devices with native 240p display resolutions.",
030d1121 752 NULL,
f3c6ae10 753 "gpu_unai",
030d1121 754 {
755 { "disabled", NULL },
756 { "enabled", NULL },
757 { NULL, NULL},
758 },
f3c6ae10 759#ifdef _MIYOO
760 "enabled",
761#else
030d1121 762 "disabled",
f3c6ae10 763#endif
030d1121 764 },
f3c6ae10 765#endif /* GPU_UNAI */
030d1121 766 {
f3c6ae10 767 "pcsx_rearmed_spu_reverb",
768 "Audio Reverb Effects",
769 "Reverb Effects",
770 "Enable emulation of the reverb feature provided by the PSX SPU. Can be disabled to improve performance at the expense of reduced audio quality/authenticity.",
030d1121 771 NULL,
f3c6ae10 772 "audio",
030d1121 773 {
774 { "disabled", NULL },
775 { "enabled", NULL },
f3c6ae10 776 { NULL, NULL },
030d1121 777 },
f3c6ae10 778#ifdef HAVE_PRE_ARMV7
030d1121 779 "disabled",
f3c6ae10 780#else
781 "enabled",
782#endif
030d1121 783 },
43047988 784 {
f3c6ae10 785 "pcsx_rearmed_spu_interpolation",
786 "Sound Interpolation",
787 NULL,
788 "Enable emulation of the in-built audio interpolation provided by the PSX SPU. 'Gaussian' sounds closest to original hardware. 'Simple' improves performance but reduces quality. 'Cubic' has the highest performance requirements but produces increased clarity. Can be disabled entirely for maximum performance, at the expense of greatly reduced audio quality.",
789 NULL,
790 "audio",
791 {
792 { "simple", "Simple" },
793 { "gaussian", "Gaussian" },
794 { "cubic", "Cubic" },
795 { "off", "disabled" },
796 { NULL, NULL },
797 },
798#ifdef HAVE_PRE_ARMV7
799 "off",
800#else
801 "simple",
802#endif
803 },
804 {
805 "pcsx_rearmed_nocdaudio",
806 "CD Audio",
807 NULL,
808 "Enable playback of CD (CD-DA) audio tracks. Can be disabled to improve performance in games that include CD audio, at the expense of missing music.",
809 NULL,
810 "audio",
43047988
JW
811 {
812 { "disabled", NULL },
813 { "enabled", NULL },
f3c6ae10 814 { NULL, NULL },
43047988 815 },
ad32ae17 816 "enabled",
43047988 817 },
c765eb86 818 {
f3c6ae10 819 "pcsx_rearmed_noxadecoding",
820 "XA Decoding",
821 NULL,
822 "Enable playback of XA (eXtended Architecture ADPCM) audio tracks. Can be disabled to improve performance in games that include XA audio, at the expense of missing music.",
823 NULL,
824 "audio",
c765eb86
JW
825 {
826 { "disabled", NULL },
f3c6ae10 827 { "enabled", NULL },
828 { NULL, NULL },
829 },
830 "enabled",
831 },
94f0c7c5 832#if P_HAVE_PTHREAD
04d27b25 833 {
834 "pcsx_rearmed_spu_thread",
835 "Threaded SPU",
836 NULL,
837 "Emulates the PSX SPU on another CPU thread. May cause audio glitches in some games.",
838 NULL,
839 "audio",
840 {
841 { "disabled", NULL },
842 { "enabled", NULL },
843 { NULL, NULL },
844 },
845 "disabled",
846 },
94f0c7c5 847#endif // P_HAVE_PTHREAD
f3c6ae10 848 {
849 "pcsx_rearmed_show_input_settings",
850 "Show Input Settings",
851 NULL,
852 "Show configuration options for all input devices: analog response, Multitaps, light guns, etc. Quick Menu may need to be toggled for this setting to take effect.",
853 NULL,
854 NULL,
855 {
856 { "disabled", NULL },
857 { "enabled", NULL },
858 { NULL, NULL },
c765eb86
JW
859 },
860 "disabled",
861 },
919cac88 862 {
f3c6ae10 863 "pcsx_rearmed_analog_axis_modifier",
864 "Analog Axis Bounds",
865 NULL,
866 "Specify range limits for the left and right analog sticks when input device is set to 'analog' or 'dualshock'. 'Square' bounds improve input response when using controllers with highly circular ranges that are unable to fully saturate the X and Y axes at 45 degree deflections.",
867 NULL,
868 "input",
869 {
870 { "circle", "Circle" },
871 { "square", "Square" },
872 { NULL, NULL },
873 },
874 "circle",
875 },
876 {
877 "pcsx_rearmed_vibration",
878 "Rumble Effects",
879 NULL,
880 "Enable haptic feedback when using a rumble-equipped gamepad with input device set to 'dualshock'.",
881 NULL,
882 "input",
919cac88 883 {
884 { "disabled", NULL },
885 { "enabled", NULL },
26e9c4f1 886 { NULL, NULL },
887 },
888 "enabled",
889 },
890 {
7c6a636a 891 "pcsx_rearmed_analog_combo",
892 "DualShock Analog Mode Toggle Key Combo",
26e9c4f1 893 NULL,
7c6a636a 894 "When the input device type is DualShock, this option allows the emulated DualShock to be toggled between DIGITAL and ANALOG mode like original hardware. You can select the button combination for this.",
26e9c4f1 895 NULL,
896 "input",
897 {
898 { "disabled", NULL },
7c6a636a 899 { "l1+r1+select", "L1 + R1 + Select" },
900 { "l1+r1+start", "L1 + R1 + Start" },
901 { "l1+r1+l3", "L1 + R1 + L3" },
902 { "l1+r1+r3", "L1 + R1 + R3" },
903 { "l3+r3", "L3 + R3" },
fbe06628 904 { NULL, NULL },
919cac88 905 },
7c6a636a 906 "l1+r1+select"
f3c6ae10 907 },
908 {
909 "pcsx_rearmed_multitap",
a11d0b9d 910 "Multitap Mode",
f3c6ae10 911 NULL,
a11d0b9d 912 "Connect a virtual PSX Multitap peripheral to either controller 'Port 1' or controller 'Port 2' for 5 player simultaneous input, or to both 'Ports 1 and 2' for 8 player input. Mutlitap usage requires compatible games.",
f3c6ae10 913 NULL,
914 "input",
915 {
916 { "disabled", NULL },
917 { "port 1", "Port 1" },
918 { "port 2", "Port 2" },
919 { "ports 1 and 2", "Ports 1 and 2" },
920 { NULL, NULL },
921 },
922 "disabled",
923 },
924 {
925 "pcsx_rearmed_negcon_deadzone",
926 "NegCon Twist Deadzone",
927 NULL,
928 "Set the deadzone of the RetroPad left analog stick when simulating the 'twist' action of emulated neGcon Controllers. Used to eliminate drift/unwanted input.",
929 NULL,
930 "input",
931 {
932 { "0", "0%" },
933 { "3", "3%" },
934 { "5", "5%" },
935 { "7", "7%" },
936 { "10", "10%" },
937 { "13", "13%" },
938 { "15", "15%" },
939 { "17", "17%" },
940 { "20", "20%" },
941 { "23", "23%" },
942 { "25", "25%" },
943 { "27", "27%" },
944 { "30", "30%" },
945 { NULL, NULL },
946 },
947 "0",
948 },
949 {
950 "pcsx_rearmed_negcon_response",
951 "NegCon Twist Response",
952 NULL,
953 "Specify the analog response when using a RetroPad left analog stick to simulate the 'twist' action of emulated neGcon Controllers.",
954 NULL,
955 "input",
956 {
957 { "linear", "Linear" },
958 { "quadratic", "Quadratic" },
959 { "cubic", "Cubic" },
960 { NULL, NULL },
961 },
962 "linear",
963 },
964 {
965 "pcsx_rearmed_input_sensitivity",
966 "Mouse Sensitivity",
967 NULL,
968 "Adjust responsiveness of emulated 'mouse' input devices.",
969 NULL,
970 "input",
971 {
972 { "0.05", NULL },
973 { "0.10", NULL },
974 { "0.15", NULL },
975 { "0.20", NULL },
976 { "0.25", NULL },
977 { "0.30", NULL },
978 { "0.35", NULL },
979 { "0.40", NULL },
980 { "0.45", NULL },
981 { "0.50", NULL },
982 { "0.55", NULL },
983 { "0.60", NULL },
984 { "0.65", NULL },
985 { "0.70", NULL },
986 { "0.75", NULL },
987 { "0.80", NULL },
988 { "0.85", NULL },
989 { "0.90", NULL },
990 { "0.95", NULL },
991 { "1.00", NULL },
992 { "1.05", NULL },
993 { "1.10", NULL },
994 { "1.15", NULL },
995 { "1.20", NULL },
996 { "1.25", NULL },
997 { "1.30", NULL },
998 { "1.35", NULL },
999 { "1.40", NULL },
1000 { "1.45", NULL },
1001 { "1.50", NULL },
1002 { "1.55", NULL },
1003 { "1.60", NULL },
1004 { "1.65", NULL },
1005 { "1.70", NULL },
1006 { "1.75", NULL },
1007 { "1.80", NULL },
1008 { "1.85", NULL },
1009 { "1.90", NULL },
1010 { "1.95", NULL },
1011 { "2.00", NULL },
1012 },
1013 "1.00",
1014 },
8b1be692
S
1015 {
1016 "pcsx_rearmed_crosshair1",
1017 "Player 1 Lightgun Crosshair",
1018 NULL,
1019 "Toggle player 1's crosshair for the Guncon or Konami Gun",
1020 NULL,
1021 "input",
1022 {
1023 { "disabled", NULL },
1024 { "blue", NULL },
1025 { "green", NULL },
1026 { "red", NULL },
1027 { "white", NULL },
1028 { NULL, NULL },
1029 },
1030 "disabled",
1031 },
1032 {
1033 "pcsx_rearmed_crosshair2",
1034 "Player 2 Lightgun Crosshair",
1035 NULL,
1036 "Toggle player 2's crosshair for the Guncon or Konami Gun",
1037 NULL,
1038 "input",
1039 {
1040 { "disabled", NULL },
1041 { "blue", NULL },
1042 { "green", NULL },
1043 { "red", NULL },
1044 { "white", NULL },
1045 { NULL, NULL },
1046 },
1047 "disabled",
1048 },
1049 {
1050 "pcsx_rearmed_konamigunadjustx",
1051 "Konami Gun X Axis Offset",
1052 NULL,
1053 "Apply an X axis offset to light gun input when emulating a Konami Gun (Hyper Blaster / Justifier) device. Can be used to correct aiming misalignments.",
1054 NULL,
1055 "input",
1056 {
1057 { "-40", NULL },
1058 { "-39", NULL },
1059 { "-38", NULL },
1060 { "-37", NULL },
1061 { "-36", NULL },
1062 { "-35", NULL },
1063 { "-34", NULL },
1064 { "-33", NULL },
1065 { "-32", NULL },
1066 { "-31", NULL },
1067 { "-30", NULL },
1068 { "-29", NULL },
1069 { "-28", NULL },
1070 { "-27", NULL },
1071 { "-26", NULL },
1072 { "-25", NULL },
1073 { "-24", NULL },
1074 { "-23", NULL },
1075 { "-22", NULL },
1076 { "-21", NULL },
1077 { "-20", NULL },
1078 { "-19", NULL },
1079 { "-18", NULL },
1080 { "-17", NULL },
1081 { "-16", NULL },
1082 { "-15", NULL },
1083 { "-14", NULL },
1084 { "-13", NULL },
1085 { "-12", NULL },
1086 { "-11", NULL },
1087 { "-10", NULL },
1088 { "-9", NULL },
1089 { "-8", NULL },
1090 { "-7", NULL },
1091 { "-6", NULL },
1092 { "-5", NULL },
1093 { "-4", NULL },
1094 { "-3", NULL },
1095 { "-2", NULL },
1096 { "-1", NULL },
1097 { "0", NULL },
1098 { "1", NULL },
1099 { "2", NULL },
1100 { "3", NULL },
1101 { "4", NULL },
1102 { "5", NULL },
1103 { "6", NULL },
1104 { "7", NULL },
1105 { "8", NULL },
1106 { "9", NULL },
1107 { "10", NULL },
1108 { "11", NULL },
1109 { "12", NULL },
1110 { "13", NULL },
1111 { "14", NULL },
1112 { "15", NULL },
1113 { "16", NULL },
1114 { "17", NULL },
1115 { "18", NULL },
1116 { "19", NULL },
1117 { "20", NULL },
1118 { "21", NULL },
1119 { "22", NULL },
1120 { "23", NULL },
1121 { "24", NULL },
1122 { "25", NULL },
1123 { "26", NULL },
1124 { "27", NULL },
1125 { "28", NULL },
1126 { "29", NULL },
1127 { "30", NULL },
1128 { "31", NULL },
1129 { "32", NULL },
1130 { "33", NULL },
1131 { "34", NULL },
1132 { "35", NULL },
1133 { "36", NULL },
1134 { "37", NULL },
1135 { "38", NULL },
1136 { "39", NULL },
1137 { "40", NULL },
1138 { NULL, NULL },
1139 },
1140 "0",
1141 },
1142 {
1143 "pcsx_rearmed_konamigunadjusty",
1144 "Konami Gun Y Axis Offset",
1145 NULL,
1146 "Apply a Y axis offset to light gun input when emulating a Konami Gun (Hyper Blaster / Justifier) device. Can be used to correct aiming misalignments.",
1147 NULL,
1148 "input",
1149 {
1150 { "-40", NULL },
1151 { "-39", NULL },
1152 { "-38", NULL },
1153 { "-37", NULL },
1154 { "-36", NULL },
1155 { "-35", NULL },
1156 { "-34", NULL },
1157 { "-33", NULL },
1158 { "-32", NULL },
1159 { "-31", NULL },
1160 { "-30", NULL },
1161 { "-29", NULL },
1162 { "-28", NULL },
1163 { "-27", NULL },
1164 { "-26", NULL },
1165 { "-25", NULL },
1166 { "-24", NULL },
1167 { "-23", NULL },
1168 { "-22", NULL },
1169 { "-21", NULL },
1170 { "-20", NULL },
1171 { "-19", NULL },
1172 { "-18", NULL },
1173 { "-17", NULL },
1174 { "-16", NULL },
1175 { "-15", NULL },
1176 { "-14", NULL },
1177 { "-13", NULL },
1178 { "-12", NULL },
1179 { "-11", NULL },
1180 { "-10", NULL },
1181 { "-9", NULL },
1182 { "-8", NULL },
1183 { "-7", NULL },
1184 { "-6", NULL },
1185 { "-5", NULL },
1186 { "-4", NULL },
1187 { "-3", NULL },
1188 { "-2", NULL },
1189 { "-1", NULL },
1190 { "0", NULL },
1191 { "1", NULL },
1192 { "2", NULL },
1193 { "3", NULL },
1194 { "4", NULL },
1195 { "5", NULL },
1196 { "6", NULL },
1197 { "7", NULL },
1198 { "8", NULL },
1199 { "9", NULL },
1200 { "10", NULL },
1201 { "11", NULL },
1202 { "12", NULL },
1203 { "13", NULL },
1204 { "14", NULL },
1205 { "15", NULL },
1206 { "16", NULL },
1207 { "17", NULL },
1208 { "18", NULL },
1209 { "19", NULL },
1210 { "20", NULL },
1211 { "21", NULL },
1212 { "22", NULL },
1213 { "23", NULL },
1214 { "24", NULL },
1215 { "25", NULL },
1216 { "26", NULL },
1217 { "27", NULL },
1218 { "28", NULL },
1219 { "29", NULL },
1220 { "30", NULL },
1221 { "31", NULL },
1222 { "32", NULL },
1223 { "33", NULL },
1224 { "34", NULL },
1225 { "35", NULL },
1226 { "36", NULL },
1227 { "37", NULL },
1228 { "38", NULL },
1229 { "39", NULL },
1230 { "40", NULL },
1231 { NULL, NULL },
1232 },
1233 "0",
1234 },
f3c6ae10 1235 {
1236 "pcsx_rearmed_gunconadjustx",
1237 "Guncon X Axis Offset",
1238 NULL,
1239 "Apply an X axis offset to light gun input when emulating a Guncon device. Can be used to correct aiming misalignments.",
1240 NULL,
1241 "input",
1242 {
8b1be692
S
1243 { "-40", NULL },
1244 { "-39", NULL },
1245 { "-38", NULL },
1246 { "-37", NULL },
1247 { "-36", NULL },
1248 { "-35", NULL },
1249 { "-34", NULL },
1250 { "-33", NULL },
1251 { "-32", NULL },
1252 { "-31", NULL },
1253 { "-30", NULL },
1254 { "-29", NULL },
1255 { "-28", NULL },
1256 { "-27", NULL },
1257 { "-26", NULL },
f3c6ae10 1258 { "-25", NULL },
1259 { "-24", NULL },
1260 { "-23", NULL },
1261 { "-22", NULL },
1262 { "-21", NULL },
1263 { "-20", NULL },
1264 { "-19", NULL },
1265 { "-18", NULL },
1266 { "-17", NULL },
1267 { "-16", NULL },
1268 { "-15", NULL },
1269 { "-14", NULL },
1270 { "-13", NULL },
1271 { "-12", NULL },
1272 { "-11", NULL },
1273 { "-10", NULL },
1274 { "-9", NULL },
1275 { "-8", NULL },
1276 { "-7", NULL },
1277 { "-6", NULL },
1278 { "-5", NULL },
1279 { "-4", NULL },
1280 { "-3", NULL },
1281 { "-2", NULL },
1282 { "-1", NULL },
1283 { "0", NULL },
1284 { "1", NULL },
1285 { "2", NULL },
1286 { "3", NULL },
1287 { "4", NULL },
1288 { "5", NULL },
1289 { "6", NULL },
1290 { "7", NULL },
1291 { "8", NULL },
1292 { "9", NULL },
1293 { "10", NULL },
1294 { "11", NULL },
1295 { "12", NULL },
1296 { "13", NULL },
1297 { "14", NULL },
1298 { "15", NULL },
1299 { "16", NULL },
1300 { "17", NULL },
1301 { "18", NULL },
1302 { "19", NULL },
1303 { "20", NULL },
1304 { "21", NULL },
1305 { "22", NULL },
1306 { "23", NULL },
1307 { "24", NULL },
1308 { "25", NULL },
8b1be692
S
1309 { "26", NULL },
1310 { "27", NULL },
1311 { "28", NULL },
1312 { "29", NULL },
1313 { "30", NULL },
1314 { "31", NULL },
1315 { "32", NULL },
1316 { "33", NULL },
1317 { "34", NULL },
1318 { "35", NULL },
1319 { "36", NULL },
1320 { "37", NULL },
1321 { "38", NULL },
1322 { "39", NULL },
1323 { "40", NULL },
f3c6ae10 1324 { NULL, NULL },
1325 },
1326 "0",
1327 },
1328 {
1329 "pcsx_rearmed_gunconadjusty",
1330 "Guncon Y Axis Offset",
1331 NULL,
1332 "Apply a Y axis offset to light gun input when emulating a Guncon device. Can be used to correct aiming misalignments.",
1333 NULL,
1334 "input",
1335 {
8b1be692
S
1336 { "-40", NULL },
1337 { "-39", NULL },
1338 { "-38", NULL },
1339 { "-37", NULL },
1340 { "-36", NULL },
1341 { "-35", NULL },
1342 { "-34", NULL },
1343 { "-33", NULL },
1344 { "-32", NULL },
1345 { "-31", NULL },
1346 { "-30", NULL },
1347 { "-29", NULL },
1348 { "-28", NULL },
1349 { "-27", NULL },
1350 { "-26", NULL },
f3c6ae10 1351 { "-25", NULL },
1352 { "-24", NULL },
1353 { "-23", NULL },
1354 { "-22", NULL },
1355 { "-21", NULL },
1356 { "-20", NULL },
1357 { "-19", NULL },
1358 { "-18", NULL },
1359 { "-17", NULL },
1360 { "-16", NULL },
1361 { "-15", NULL },
1362 { "-14", NULL },
1363 { "-13", NULL },
1364 { "-12", NULL },
1365 { "-11", NULL },
1366 { "-10", NULL },
1367 { "-9", NULL },
1368 { "-8", NULL },
1369 { "-7", NULL },
1370 { "-6", NULL },
1371 { "-5", NULL },
1372 { "-4", NULL },
1373 { "-3", NULL },
1374 { "-2", NULL },
1375 { "-1", NULL },
1376 { "0", NULL },
1377 { "1", NULL },
1378 { "2", NULL },
1379 { "3", NULL },
1380 { "4", NULL },
1381 { "5", NULL },
1382 { "6", NULL },
1383 { "7", NULL },
1384 { "8", NULL },
1385 { "9", NULL },
1386 { "10", NULL },
1387 { "11", NULL },
1388 { "12", NULL },
1389 { "13", NULL },
1390 { "14", NULL },
1391 { "15", NULL },
1392 { "16", NULL },
1393 { "17", NULL },
1394 { "18", NULL },
1395 { "19", NULL },
1396 { "20", NULL },
1397 { "21", NULL },
1398 { "22", NULL },
1399 { "23", NULL },
1400 { "24", NULL },
1401 { "25", NULL },
8b1be692
S
1402 { "26", NULL },
1403 { "27", NULL },
1404 { "28", NULL },
1405 { "29", NULL },
1406 { "30", NULL },
1407 { "31", NULL },
1408 { "32", NULL },
1409 { "33", NULL },
1410 { "34", NULL },
1411 { "35", NULL },
1412 { "36", NULL },
1413 { "37", NULL },
1414 { "38", NULL },
1415 { "39", NULL },
1416 { "40", NULL },
f3c6ae10 1417 { NULL, NULL },
1418 },
1419 "0",
919cac88 1420 },
1421 {
f3c6ae10 1422 "pcsx_rearmed_gunconadjustratiox",
1423 "Guncon X Axis Response",
1424 NULL,
1425 "Adjust relative magnitude of horizontal light gun motion when emulating a Guncon device. Can be used to correct aiming misalignments.",
1426 NULL,
1427 "input",
919cac88 1428 {
f3c6ae10 1429 { "0.75", NULL },
1430 { "0.76", NULL },
1431 { "0.77", NULL },
1432 { "0.78", NULL },
1433 { "0.79", NULL },
1434 { "0.80", NULL },
1435 { "0.81", NULL },
1436 { "0.82", NULL },
1437 { "0.83", NULL },
1438 { "0.84", NULL },
1439 { "0.85", NULL },
1440 { "0.86", NULL },
1441 { "0.87", NULL },
1442 { "0.88", NULL },
1443 { "0.89", NULL },
1444 { "0.90", NULL },
1445 { "0.91", NULL },
1446 { "0.92", NULL },
1447 { "0.93", NULL },
1448 { "0.94", NULL },
1449 { "0.95", NULL },
1450 { "0.96", NULL },
1451 { "0.97", NULL },
1452 { "0.98", NULL },
1453 { "0.99", NULL },
1454 { "1.00", NULL },
1455 { "1.01", NULL },
1456 { "1.02", NULL },
1457 { "1.03", NULL },
1458 { "1.04", NULL },
1459 { "1.05", NULL },
1460 { "1.06", NULL },
1461 { "1.07", NULL },
1462 { "1.08", NULL },
1463 { "1.09", NULL },
1464 { "1.10", NULL },
1465 { "1.11", NULL },
1466 { "1.12", NULL },
1467 { "1.13", NULL },
1468 { "1.14", NULL },
1469 { "1.15", NULL },
1470 { "1.16", NULL },
1471 { "1.17", NULL },
1472 { "1.18", NULL },
1473 { "1.19", NULL },
1474 { "1.20", NULL },
1475 { "1.21", NULL },
1476 { "1.22", NULL },
1477 { "1.23", NULL },
1478 { "1.24", NULL },
1479 { "1.25", NULL },
fbe06628 1480 { NULL, NULL },
919cac88 1481 },
f3c6ae10 1482 "1.00",
919cac88 1483 },
1484 {
f3c6ae10 1485 "pcsx_rearmed_gunconadjustratioy",
1486 "Guncon Y Axis Response",
1487 NULL,
1488 "Adjust relative magnitude of vertical light gun motion when emulating a Guncon device. Can be used to correct aiming misalignments.",
919cac88 1489 NULL,
f3c6ae10 1490 "input",
919cac88 1491 {
f3c6ae10 1492 { "0.75", NULL },
1493 { "0.76", NULL },
1494 { "0.77", NULL },
1495 { "0.78", NULL },
1496 { "0.79", NULL },
1497 { "0.80", NULL },
1498 { "0.81", NULL },
1499 { "0.82", NULL },
1500 { "0.83", NULL },
1501 { "0.84", NULL },
1502 { "0.85", NULL },
1503 { "0.86", NULL },
1504 { "0.87", NULL },
1505 { "0.88", NULL },
1506 { "0.89", NULL },
1507 { "0.90", NULL },
1508 { "0.91", NULL },
1509 { "0.92", NULL },
1510 { "0.93", NULL },
1511 { "0.94", NULL },
1512 { "0.95", NULL },
1513 { "0.96", NULL },
1514 { "0.97", NULL },
1515 { "0.98", NULL },
1516 { "0.99", NULL },
1517 { "1.00", NULL },
1518 { "1.01", NULL },
1519 { "1.02", NULL },
1520 { "1.03", NULL },
1521 { "1.04", NULL },
1522 { "1.05", NULL },
1523 { "1.06", NULL },
1524 { "1.07", NULL },
1525 { "1.08", NULL },
1526 { "1.09", NULL },
1527 { "1.10", NULL },
1528 { "1.11", NULL },
1529 { "1.12", NULL },
1530 { "1.13", NULL },
1531 { "1.14", NULL },
1532 { "1.15", NULL },
1533 { "1.16", NULL },
1534 { "1.17", NULL },
1535 { "1.18", NULL },
1536 { "1.19", NULL },
1537 { "1.20", NULL },
1538 { "1.21", NULL },
1539 { "1.22", NULL },
1540 { "1.23", NULL },
1541 { "1.24", NULL },
1542 { "1.25", NULL },
fbe06628 1543 { NULL, NULL },
919cac88 1544 },
f3c6ae10 1545 "1.00",
919cac88 1546 },
919cac88 1547 {
f3c6ae10 1548 "pcsx_rearmed_icache_emulation",
1549 "Instruction Cache Emulation",
919cac88 1550 NULL,
6d79a06f 1551 "Enable emulation of the PSX CPU instruction cache. Improves accuracy at the expense of increased performance overheads. Required for Formula One 2001, Formula One Arcade and Formula One 99. [Interpreter only; partial on lightrec and ARM dynarecs]",
1552 NULL,
1553 "compat_hack",
1554 {
1555 { "enabled", NULL },
1556 { "disabled", NULL },
1557 { NULL, NULL },
1558 },
1559 "enabled",
1560 },
1561 {
1562 "pcsx_rearmed_exception_emulation",
1563 "Exception and Breakpoint Emulation",
1564 NULL,
1565 "Enable emulation of some almost never used PSX's debug features. This causes a performance hit, is not useful for games and is intended for PSX homebrew and romhack developers only. Only enable if you know what you are doing. [Interpreter only]",
f3c6ae10 1566 NULL,
1567 "compat_hack",
919cac88 1568 {
1569 { "disabled", NULL },
1570 { "enabled", NULL },
fbe06628 1571 { NULL, NULL },
919cac88 1572 },
f3c6ae10 1573 "disabled",
919cac88 1574 },
f3c6ae10 1575#if !defined(DRC_DISABLE) && !defined(LIGHTREC)
34af0fff 1576 {
f3c6ae10 1577 "pcsx_rearmed_nocompathacks",
1578 "Disable Automatic Compatibility Hacks",
1579 NULL,
1580 "By default, PCSX-ReARMed will apply auxiliary compatibility hacks automatically, based on the currently loaded content. This behaviour is required for correct operation, but may be disabled if desired.",
1581 NULL,
1582 "compat_hack",
34af0fff 1583 {
1584 { "disabled", NULL },
1585 { "enabled", NULL },
1586 { NULL, NULL },
1587 },
1588 "disabled",
1589 },
919cac88 1590 {
1591 "pcsx_rearmed_nosmccheck",
1592 "(Speed Hack) Disable SMC Checks",
f3c6ae10 1593 "Disable SMC Checks",
1594 "Will cause crashes when loading, and lead to memory card failure.",
1595 NULL,
1596 "speed_hack",
919cac88 1597 {
1598 { "disabled", NULL },
1599 { "enabled", NULL },
fbe06628 1600 { NULL, NULL },
919cac88 1601 },
1602 "disabled",
1603 },
1604 {
1605 "pcsx_rearmed_gteregsunneeded",
f3c6ae10 1606 "(Speed Hack) Assume GTE Registers Unneeded",
1607 "Assume GTE Registers Unneeded",
1608 "May cause rendering errors.",
1609 NULL,
1610 "speed_hack",
919cac88 1611 {
1612 { "disabled", NULL },
1613 { "enabled", NULL },
fbe06628 1614 { NULL, NULL },
919cac88 1615 },
1616 "disabled",
1617 },
1618 {
1619 "pcsx_rearmed_nogteflags",
1620 "(Speed Hack) Disable GTE Flags",
f3c6ae10 1621 "Disable GTE Flags",
1622 "Will cause rendering errors.",
1623 NULL,
1624 "speed_hack",
919cac88 1625 {
1626 { "disabled", NULL },
1627 { "enabled", NULL },
38114665
ÖK
1628 { NULL, NULL },
1629 },
fbe06628 1630 "disabled",
38114665 1631 },
65662232 1632#endif /* !DRC_DISABLE && !LIGHTREC */
630b122b 1633 {
1634 "pcsx_rearmed_nostalls",
f3c6ae10 1635 "Disable CPU/GTE Stalls",
f3c6ae10 1636 NULL,
65662232 1637 "Will cause some games to run too quickly."
1638#if defined(LIGHTREC)
1639 " Interpreter only."
1640#endif
1641 ,
1642 NULL,
1643 "compat_hack",
630b122b 1644 {
1645 { "disabled", NULL },
1646 { "enabled", NULL },
1647 { NULL, NULL },
1648 },
1649 "disabled",
1650 },
f3c6ae10 1651 { NULL, NULL, NULL, NULL, NULL, NULL, {{0}}, NULL },
1652};
38114665 1653
f3c6ae10 1654struct retro_core_options_v2 options_us = {
1655 option_cats_us,
1656 option_defs_us
38114665
ÖK
1657};
1658
919cac88 1659/*
1660 ********************************
1661 * Language Mapping
1662 ********************************
1663*/
1664
fbe06628 1665#ifndef HAVE_NO_LANGEXTRA
f3c6ae10 1666struct retro_core_options_v2 *options_intl[RETRO_LANGUAGE_LAST] = {
1667 &options_us, /* RETRO_LANGUAGE_ENGLISH */
1668 NULL, /* RETRO_LANGUAGE_JAPANESE */
1669 NULL, /* RETRO_LANGUAGE_FRENCH */
1670 NULL, /* RETRO_LANGUAGE_SPANISH */
1671 NULL, /* RETRO_LANGUAGE_GERMAN */
1672 NULL, /* RETRO_LANGUAGE_ITALIAN */
1673 NULL, /* RETRO_LANGUAGE_DUTCH */
1674 NULL, /* RETRO_LANGUAGE_PORTUGUESE_BRAZIL */
1675 NULL, /* RETRO_LANGUAGE_PORTUGUESE_PORTUGAL */
1676 NULL, /* RETRO_LANGUAGE_RUSSIAN */
1677 NULL, /* RETRO_LANGUAGE_KOREAN */
1678 NULL, /* RETRO_LANGUAGE_CHINESE_TRADITIONAL */
1679 NULL, /* RETRO_LANGUAGE_CHINESE_SIMPLIFIED */
1680 NULL, /* RETRO_LANGUAGE_ESPERANTO */
1681 NULL, /* RETRO_LANGUAGE_POLISH */
1682 NULL, /* RETRO_LANGUAGE_VIETNAMESE */
1683 NULL, /* RETRO_LANGUAGE_ARABIC */
1684 NULL, /* RETRO_LANGUAGE_GREEK */
1685 &options_tr, /* RETRO_LANGUAGE_TURKISH */
919cac88 1686};
fbe06628 1687#endif
919cac88 1688
1689/*
1690 ********************************
1691 * Functions
1692 ********************************
1693*/
1694
1695/* Handles configuration/setting of core options.
fbe06628 1696 * Should be called as early as possible - ideally inside
1697 * retro_set_environment(), and no later than retro_load_game()
919cac88 1698 * > We place the function body in the header to avoid the
1699 * necessity of adding more .c files (i.e. want this to
1700 * be as painless as possible for core devs)
1701 */
1702
f3c6ae10 1703static INLINE void libretro_set_core_options(retro_environment_t environ_cb,
1704 bool *categories_supported)
919cac88 1705{
f3c6ae10 1706 unsigned version = 0;
1707#ifndef HAVE_NO_LANGEXTRA
1708 unsigned language = 0;
1709#endif
919cac88 1710
f3c6ae10 1711 if (!environ_cb || !categories_supported)
919cac88 1712 return;
1713
f3c6ae10 1714 *categories_supported = false;
1715
1716 if (!environ_cb(RETRO_ENVIRONMENT_GET_CORE_OPTIONS_VERSION, &version))
1717 version = 0;
1718
1719 if (version >= 2)
919cac88 1720 {
fbe06628 1721#ifndef HAVE_NO_LANGEXTRA
f3c6ae10 1722 struct retro_core_options_v2_intl core_options_intl;
919cac88 1723
f3c6ae10 1724 core_options_intl.us = &options_us;
919cac88 1725 core_options_intl.local = NULL;
1726
1727 if (environ_cb(RETRO_ENVIRONMENT_GET_LANGUAGE, &language) &&
1728 (language < RETRO_LANGUAGE_LAST) && (language != RETRO_LANGUAGE_ENGLISH))
f3c6ae10 1729 core_options_intl.local = options_intl[language];
919cac88 1730
f3c6ae10 1731 *categories_supported = environ_cb(RETRO_ENVIRONMENT_SET_CORE_OPTIONS_V2_INTL,
1732 &core_options_intl);
fbe06628 1733#else
f3c6ae10 1734 *categories_supported = environ_cb(RETRO_ENVIRONMENT_SET_CORE_OPTIONS_V2,
1735 &options_us);
fbe06628 1736#endif
919cac88 1737 }
1738 else
1739 {
f3c6ae10 1740 size_t i, j;
919cac88 1741 size_t option_index = 0;
1742 size_t num_options = 0;
f3c6ae10 1743 struct retro_core_option_definition
1744 *option_v1_defs_us = NULL;
1745#ifndef HAVE_NO_LANGEXTRA
1746 size_t num_options_intl = 0;
1747 struct retro_core_option_v2_definition
1748 *option_defs_intl = NULL;
1749 struct retro_core_option_definition
1750 *option_v1_defs_intl = NULL;
1751 struct retro_core_options_intl
1752 core_options_v1_intl;
1753#endif
919cac88 1754 struct retro_variable *variables = NULL;
1755 char **values_buf = NULL;
1756
f3c6ae10 1757 /* Determine total number of options */
919cac88 1758 while (true)
1759 {
1760 if (option_defs_us[num_options].key)
1761 num_options++;
1762 else
1763 break;
1764 }
1765
f3c6ae10 1766 if (version >= 1)
1767 {
1768 /* Allocate US array */
1769 option_v1_defs_us = (struct retro_core_option_definition *)
1770 calloc(num_options + 1, sizeof(struct retro_core_option_definition));
1771
1772 /* Copy parameters from option_defs_us array */
1773 for (i = 0; i < num_options; i++)
1774 {
1775 struct retro_core_option_v2_definition *option_def_us = &option_defs_us[i];
1776 struct retro_core_option_value *option_values = option_def_us->values;
1777 struct retro_core_option_definition *option_v1_def_us = &option_v1_defs_us[i];
1778 struct retro_core_option_value *option_v1_values = option_v1_def_us->values;
919cac88 1779
f3c6ae10 1780 option_v1_def_us->key = option_def_us->key;
1781 option_v1_def_us->desc = option_def_us->desc;
1782 option_v1_def_us->info = option_def_us->info;
1783 option_v1_def_us->default_value = option_def_us->default_value;
919cac88 1784
f3c6ae10 1785 /* Values must be copied individually... */
1786 while (option_values->value)
1787 {
1788 option_v1_values->value = option_values->value;
1789 option_v1_values->label = option_values->label;
919cac88 1790
f3c6ae10 1791 option_values++;
1792 option_v1_values++;
1793 }
1794 }
919cac88 1795
f3c6ae10 1796#ifndef HAVE_NO_LANGEXTRA
1797 if (environ_cb(RETRO_ENVIRONMENT_GET_LANGUAGE, &language) &&
1798 (language < RETRO_LANGUAGE_LAST) && (language != RETRO_LANGUAGE_ENGLISH) &&
1799 options_intl[language])
1800 option_defs_intl = options_intl[language]->definitions;
919cac88 1801
f3c6ae10 1802 if (option_defs_intl)
919cac88 1803 {
f3c6ae10 1804 /* Determine number of intl options */
919cac88 1805 while (true)
1806 {
f3c6ae10 1807 if (option_defs_intl[num_options_intl].key)
1808 num_options_intl++;
919cac88 1809 else
1810 break;
1811 }
1812
f3c6ae10 1813 /* Allocate intl array */
1814 option_v1_defs_intl = (struct retro_core_option_definition *)
1815 calloc(num_options_intl + 1, sizeof(struct retro_core_option_definition));
1816
1817 /* Copy parameters from option_defs_intl array */
1818 for (i = 0; i < num_options_intl; i++)
919cac88 1819 {
f3c6ae10 1820 struct retro_core_option_v2_definition *option_def_intl = &option_defs_intl[i];
1821 struct retro_core_option_value *option_values = option_def_intl->values;
1822 struct retro_core_option_definition *option_v1_def_intl = &option_v1_defs_intl[i];
1823 struct retro_core_option_value *option_v1_values = option_v1_def_intl->values;
1824
1825 option_v1_def_intl->key = option_def_intl->key;
1826 option_v1_def_intl->desc = option_def_intl->desc;
1827 option_v1_def_intl->info = option_def_intl->info;
1828 option_v1_def_intl->default_value = option_def_intl->default_value;
1829
1830 /* Values must be copied individually... */
1831 while (option_values->value)
1832 {
1833 option_v1_values->value = option_values->value;
1834 option_v1_values->label = option_values->label;
1835
1836 option_values++;
1837 option_v1_values++;
1838 }
1839 }
1840 }
919cac88 1841
f3c6ae10 1842 core_options_v1_intl.us = option_v1_defs_us;
1843 core_options_v1_intl.local = option_v1_defs_intl;
919cac88 1844
f3c6ae10 1845 environ_cb(RETRO_ENVIRONMENT_SET_CORE_OPTIONS_INTL, &core_options_v1_intl);
1846#else
1847 environ_cb(RETRO_ENVIRONMENT_SET_CORE_OPTIONS, option_v1_defs_us);
1848#endif
1849 }
1850 else
1851 {
1852 /* Allocate arrays */
1853 variables = (struct retro_variable *)calloc(num_options + 1,
1854 sizeof(struct retro_variable));
1855 values_buf = (char **)calloc(num_options, sizeof(char *));
1856
1857 if (!variables || !values_buf)
1858 goto error;
1859
1860 /* Copy parameters from option_defs_us array */
1861 for (i = 0; i < num_options; i++)
1862 {
1863 const char *key = option_defs_us[i].key;
1864 const char *desc = option_defs_us[i].desc;
1865 const char *default_value = option_defs_us[i].default_value;
1866 struct retro_core_option_value *values = option_defs_us[i].values;
1867 size_t buf_len = 3;
1868 size_t default_index = 0;
919cac88 1869
f3c6ae10 1870 values_buf[i] = NULL;
919cac88 1871
f3c6ae10 1872 /* Skip options that are irrelevant when using the
1873 * old style core options interface */
1874 if ((strcmp(key, "pcsx_rearmed_show_input_settings") == 0) ||
1875 (strcmp(key, "pcsx_rearmed_show_gpu_peops_settings") == 0) ||
1876 (strcmp(key, "pcsx_rearmed_show_gpu_unai_settings") == 0))
1877 continue;
1878
1879 if (desc)
1880 {
1881 size_t num_values = 0;
1882
1883 /* Determine number of values */
1884 while (true)
1885 {
1886 if (values[num_values].value)
1887 {
1888 /* Check if this is the default value */
1889 if (default_value)
1890 if (strcmp(values[num_values].value, default_value) == 0)
1891 default_index = num_values;
1892
1893 buf_len += strlen(values[num_values].value);
1894 num_values++;
1895 }
1896 else
1897 break;
1898 }
919cac88 1899
f3c6ae10 1900 /* Build values string */
1901 if (num_values > 0)
919cac88 1902 {
f3c6ae10 1903 buf_len += num_values - 1;
1904 buf_len += strlen(desc);
1905
1906 values_buf[i] = (char *)calloc(buf_len, sizeof(char));
1907 if (!values_buf[i])
1908 goto error;
1909
1910 strcpy(values_buf[i], desc);
1911 strcat(values_buf[i], "; ");
1912
1913 /* Default value goes first */
1914 strcat(values_buf[i], values[default_index].value);
1915
1916 /* Add remaining values */
1917 for (j = 0; j < num_values; j++)
919cac88 1918 {
f3c6ae10 1919 if (j != default_index)
1920 {
1921 strcat(values_buf[i], "|");
1922 strcat(values_buf[i], values[j].value);
1923 }
919cac88 1924 }
1925 }
1926 }
f3c6ae10 1927
1928 variables[option_index].key = key;
1929 variables[option_index].value = values_buf[i];
1930 option_index++;
919cac88 1931 }
1932
f3c6ae10 1933 /* Set variables */
1934 environ_cb(RETRO_ENVIRONMENT_SET_VARIABLES, variables);
919cac88 1935 }
1936
919cac88 1937error:
919cac88 1938 /* Clean up */
f3c6ae10 1939
1940 if (option_v1_defs_us)
1941 {
1942 free(option_v1_defs_us);
1943 option_v1_defs_us = NULL;
1944 }
1945
1946#ifndef HAVE_NO_LANGEXTRA
1947 if (option_v1_defs_intl)
1948 {
1949 free(option_v1_defs_intl);
1950 option_v1_defs_intl = NULL;
1951 }
1952#endif
1953
919cac88 1954 if (values_buf)
1955 {
1956 for (i = 0; i < num_options; i++)
1957 {
1958 if (values_buf[i])
1959 {
1960 free(values_buf[i]);
1961 values_buf[i] = NULL;
1962 }
1963 }
1964
1965 free(values_buf);
1966 values_buf = NULL;
1967 }
1968
1969 if (variables)
1970 {
1971 free(variables);
1972 variables = NULL;
1973 }
1974 }
1975}
1976
1977#ifdef __cplusplus
1978}
1979#endif
1980
1981#endif