Skip to content

Commit

Permalink
ui: Redesign user interface
Browse files Browse the repository at this point in the history
Introduces a new user interface that looks much nicer, is easier to
navigate with controllers, provides more context to users, and is
scalable. Some additional features are included.

* Adds 'popup menu' with actions that can be used easily from controller
* Adds 'main menu', unifying other configuration dialogs
* Adds port-forwarding user interface
* Adds screenshot feature
* Adds volume control feature
* Adds gamepad auto-bind option
* Adds vsync configuration option
* Adds auto UI scaling
* Adds preferred window size selection
* Adds AV pack selection
* Exposes some existing config items in GUI
  • Loading branch information
mborgerson committed May 7, 2022
1 parent 306891b commit 9c06980
Show file tree
Hide file tree
Showing 98 changed files with 12,880 additions and 3,846 deletions.
1 change: 1 addition & 0 deletions .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ IncludeCategories:
IncludeIsMainRegex: '$'
IndentCaseLabels: false
IndentWidth: 4
AccessModifierOffset: -4
IndentWrappedFunctionNames: false
KeepEmptyLinesAtTheStartOfBlocks: false
MacroBlockBegin: '.*_BEGIN$' # only PREC_BEGIN ?
Expand Down
8 changes: 4 additions & 4 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,12 @@
[submodule "roms/vbootrom"]
path = roms/vbootrom
url = https://gitlab.com/qemu-project/vbootrom.git
[submodule "ui/imgui"]
path = ui/imgui
[submodule "ui/thirdparty/imgui"]
path = ui/thirdparty/imgui
url = https://github.com/ocornut/imgui.git
ignore = untracked
[submodule "ui/implot"]
path = ui/implot
[submodule "ui/thirdparty/implot"]
path = ui/thirdparty/implot
url = https://github.com/epezent/implot.git
ignore = untracked
[submodule "hw/xbox/nv2a/xxHash"]
Expand Down
5 changes: 0 additions & 5 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -272,11 +272,6 @@ set -x # Print commands from now on
${opts} \
"$@"

# Force imgui update now to work around annoying make issue
if ! test -f "${project_source_dir}/ui/imgui/imgui.cpp"; then
./scripts/git-submodule.sh update ui/imgui
fi

time make -j"${job_count}" ${target} 2>&1 | tee build.log

"${postbuild}" # call post build functions
56 changes: 52 additions & 4 deletions config_spec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ general:
check:
type: bool
default: true
misc:
skip_boot_anim: bool
screenshot_dir: string
skip_boot_anim: bool
# throttle_io: bool
last_viewed_menu_index: integer
user_token: string

input:
Expand All @@ -16,26 +18,55 @@ input:
port2: string
port3: string
port4: string
gamecontrollerdb_path: string
auto_bind:
type: bool
default: true
background_input_capture: bool

display:
quality:
surface_scale:
type: integer
default: 1
window:
last_width: integer
last_height: integer
fullscreen_on_startup: bool
startup_size:
type: enum
values: [last_used, 640x480, 1280x720, 1280x800, 1280x960, 1920x1080, 2560x1440, 2560x1600, 2560x1920, 3840x2160]
default: 1280x960
last_width:
type: integer
default: 640
last_height:
type: integer
default: 480
vsync:
type: bool
default: true
ui:
show_menubar:
type: bool
default: true
use_animations:
type: bool
default: true
fit:
type: enum
values: [center, scale, scale_16_9, scale_4_3, stretch]
default: scale
scale:
type: integer
default: 1
auto_scale:
type: bool
default: true

audio:
use_dsp: bool
volume_limit:
type: number
default: 1

net:
enable: bool
Expand All @@ -52,12 +83,26 @@ net:
remote_addr:
type: string
default: 1.2.3.4:9368
nat:
forward_ports:
type: array
items:
host: integer
guest: integer
protocol:
type: enum
values: [tcp, udp]
default: tcp

sys:
mem_limit:
type: enum
values: ['64', '128']
default: '64'
avpack:
type: enum
values: [scart, hdtv, vga, rfu, svideo, composite, none]
default: hdtv
files:
bootrom_path: string
flashrom_path: string
Expand All @@ -69,3 +114,6 @@ perf:
hard_fpu:
type: bool
default: true
# cache_shaders:
# type: bool
# default: true
2 changes: 1 addition & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ else
git_submodules_action="ignore"
fi

git_submodules="ui/keycodemapdb ui/imgui ui/implot util/xxHash"
git_submodules="ui/keycodemapdb ui/thirdparty/imgui ui/thirdparty/implot util/xxHash tomlplusplus genconfig"
git="git"

# Don't accept a target_list environment variable.
Expand Down
Binary file renamed data/roboto_medium.ttf → data/Roboto-Medium.ttf
Binary file not shown.
Binary file added data/RobotoCondensed-Regular.ttf
Binary file not shown.
156 changes: 156 additions & 0 deletions data/abxy.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added data/abxy.ttf
Binary file not shown.

0 comments on commit 9c06980

Please sign in to comment.