Daniel López Guimaraes
ba3d16b48b
cellMic: Fix CELLMIC_DEVATTR_CHANVOL handling
...
The microphone index given in `arg1` is 1-indexed, so we have to
subtract 1 from the index to access the proper value.
This wasn't caught up before since we were doing direct access of the
array instead of using `::at32` which wouldn't check that the value is
within bounds.
This allows the original SingStar game to boot up again, as it would
otherwise crash then trying to set the volume to the second channel due
to the index being out of bounds.
2024-08-02 19:29:42 +02:00
Elad Ashkenazi
700334753d
cellMic: Fix potential overflow
2024-07-28 12:36:42 +03:00
Daniel López Guimaraes
501e9260b2
cellMic: Wake up upon registering emulated SingStar microphone
...
When using the emulated SingStar microphone, the device is only
registered when initializing `cellMic`. However, the `mic_context`
thread is only woken up when calling `register_device`. The registration
happens before initializing `cellMic`, so the thread is never woken up
after registering the device.
Add call to `wake_up` in `load_config_and_init` inside the emulated
SingStar microphone specific code to fix this issue, allowing the thread
to detect the device and update the microphone data.
This allows SingStar to receive the microphone data when using the
emulated SingStar microphone that it previously wasn't receiving.
2024-07-26 09:44:00 +03:00
Megamouse
cf5a66a204
cellMic: add nullptr check for data in cell_mic_read
...
Also rename S to Size for readability
2024-03-26 13:50:43 +01:00
Megamouse
9fe640b187
whitespace and format
2024-01-02 16:46:31 +01:00
Megamouse
cf20526f9f
cellMic: Improve cellMicGetDeviceAttr
2023-09-21 07:52:00 +02:00
Ivan Chikish
d34287b2cc
Linux: use futex_waitv syscall for atomic waiting
...
In order to make this possible, some unnecessary features were removed.
2023-08-02 21:46:06 +03:00
Megamouse
a6313fa46c
cellMic: fix mic type regression
2023-04-13 20:00:05 +02:00
Megamouse
2a7431bd61
cellMic: fallback to proper sampling rate if necessary
2023-04-13 20:00:05 +02:00
Megamouse
90851459c8
cellMic: change some log levels
2023-04-13 20:00:05 +02:00
Megamouse
27c9bf137c
cellMic: fallback to 4,2,1 channels by default
2023-04-13 20:00:05 +02:00
Megamouse
2205790dd4
cellMic: add some error checks
2023-04-13 20:00:05 +02:00
Megamouse
0115c2f70a
cellMic: minor format changes for readability
2023-04-13 20:00:05 +02:00
RipleyTom
0e8b0e414a
Improve cellMic and sys_usbd thread scheduling
2023-04-07 23:36:32 +02:00
RipleyTom
0c051a83a7
Fix mic thread usage
2023-03-30 08:14:28 +02:00
Megamouse
a8ada492b2
cellMic: fix registration index
2023-03-28 20:26:04 +02:00
Megamouse
f2b51668b4
cellMic: use fixed index for devices
2023-03-28 20:26:04 +02:00
Megamouse
c2527c9e1b
cellMic: wait for registration of multiple input devices
2023-03-28 20:26:04 +02:00
Megamouse
0bcd45c1d4
cellMic: add some additional error check and silence log spam
2023-03-28 20:26:04 +02:00
Megamouse
ecf0022fd1
cellMicGetSignalState: fake some more values
...
Maybe this improves the mic signal even more
2023-03-28 20:26:04 +02:00
Megamouse
69ebdfd689
cellMic: random improvements
2023-03-03 08:27:42 +01:00
Nekotekina
6ff6a4989a
Implement at32() util
...
Works like .at() but uses source location for "exception".
2022-09-26 18:04:15 +03:00
Megamouse
34615d3a74
cellMic: slow down if no mics are configured
2022-07-17 19:31:05 +02:00
Megamouse
686d2759f4
cellMic: remove cellMicRead error spam
2022-03-12 20:48:36 +01:00
Megamouse
2af2db2cbf
Lower some log spam
...
These functions probably aren't perfect, but they spam a lot of unnecessary log messages.
2021-10-27 00:25:27 +02:00
Megamouse
a16d8ba3ea
More random changes
2021-04-11 14:01:51 +03:00
Nekotekina
95725bf7fc
Add -Werror=missing-noreturn (GCC, clang)
...
May be useful to diagnose functions which fail assertions unconditionally.
2021-04-08 10:29:47 +03:00
Nekotekina
87af905018
Enable -Wunused-parameter
2021-03-06 18:07:08 +03:00
Nekotekina
ea5e837bd6
fixed_typemap.hpp: return reference
2021-03-02 16:08:14 +03:00
Eladash
bf6f43ec3a
Utils: Rewrite fmt::split
2021-01-08 22:23:48 +03:00
Nekotekina
36c8654fb8
Remove HERE macro
...
Some cleanup.
Add location to some functions.
2020-12-10 12:30:22 +03:00
Nekotekina
e055d16b2c
Replace verify() with ensure() with auto src location.
...
Expression ensure(x) returns x.
Using comma operator removed.
2020-12-09 15:43:38 +03:00
RipleyTom
af8c661a64
Remove BOM markers
2020-12-06 15:30:12 +03:00
Megamouse
bb3ac62126
cellMic: use s32 consistently
2020-07-24 14:47:10 +02:00
Megamouse
a00ebacef3
cellFont: add error_code
2020-07-24 14:47:10 +02:00
Megamouse
c2f4244c4d
cellMic: error_code, random cleanup and stubbing
2020-07-24 14:47:10 +02:00
Megamouse
b1fdbc7fcc
Move some format functions
2020-04-06 20:59:58 +02:00
gamerforEA
93552a5958
Apply some Clang-Tidy fixes
2020-02-27 00:38:55 +03:00
Megamouse
fe75311be2
move config structs to own files and clean up some headers
2020-02-17 15:08:17 +03:00
Nekotekina
185c067d5b
C-style cast cleanup V
2019-12-03 17:23:00 +03:00
Hula Hoop
200ec5c4b3
Super-important PR ( #6900 )
...
* Fix capitalisation errors and typos
* Oops
2019-10-28 17:44:44 +03:00
Eladash
1d07c40aa5
Fix state reset in cellMic, cellAudio, cellCamera ( #6761 )
2019-10-13 19:26:11 +03:00
Nekotekina
16dd72b3e3
Replace some uses of Emu.IsStopped()
...
Poll thread state instead.
2019-10-12 21:12:47 +03:00
Megamouse
f8c6cc2476
cellMic: add some params
...
makes me wonder if dev_num should always be s32
2019-10-08 08:21:30 +02:00
Nekotekina
c2fe2ac4a4
cellMic: use g_fxo
2019-09-17 02:46:34 +03:00
Eladash
85b1152e29
Timers scaling and fixes
2019-07-23 00:09:01 +01:00
RipleyTom
6c6b973342
Microphone implementation
2019-07-11 20:13:12 +01:00
Nekotekina
1456678316
Refactor audio/camera/mic threads
2018-10-02 02:22:26 +03:00
Nekotekina
306f95a9ae
New named_thread template (preview)
...
Old class named_thread renamed to old_thread
It's too hard to move in a single commit
2018-09-27 14:04:16 +03:00
Nekotekina
5e556a87ff
Adjust cellMic log levels
2018-09-03 21:40:36 +03:00