da275cfd52cad5126e671d635e2a75c7616edf4c
The original implementation reserved a channel sized to the whole buffer (~44160 samples) and sent it in one sceAudioOutputPannedBlocking call. Confirmed against the PSP SDK's own samples (pspaudiolib, the mp3 sample) that this deviates from how PSP audio hardware is actually meant to be driven: small fixed-size chunks (1024 frames, matching pspaudiolib's own convention) fed continuously, decoupled from the render loop. Reproduced as crackling on real hardware. Now reserves a 1024-frame channel and runs a dedicated thread (the project's existing thread_t abstraction, already used by asset.c and already working on PSP via DUSK_THREAD_PTHREAD) that streams the buffer chunk-by-chunk until exhausted, re-reading volume/pan every chunk so live changes take effect mid-playback. Finish detection switched from polling sceAudioGetChannelRestLength (which can't tell "between chunks" from "actually done" once chunked) to a flag the feeder thread sets on completion, same shape as the Dolphin voice callback. Verified via the dusk-psp toolchain and PPSSPP headless (channel now reserved at 1024 frames instead of 44160, onEnd still fires once). Real-hardware crackle-free confirmation pending.
Dusk
RPG Game Project, small and able to run on a PSP.
Building
Each build target has different requirements. You can take a look at the git workflow to see how the builds are done for each target. In addition, for accessing the editor and building the game on your host system, install the following packages, depending on your system;
Fedora;
sudo dnf install git make gcc cmake python python-polib python3-pillow python3-dotenv python3-numpy python-qt5 python3-pyopengl SDL2-devel zlib-devel libzip-devel bzip2-devel openssl-devel lzma-sdk-devel xz xz-devel lua-devel
Ubuntu;
sudo apt-get install git build-essential gcc python python-polib python3-pillow python3-dotenv python3-numpy python3-pyqt5 python3-opengl
Arch Linux;
sudo pacman -S git base-devel gcc python python-polib python-pillow python-dotenv python-numpy python-pyqt5 python-opengl
Description
Languages
C
87%
JavaScript
4.2%
Python
3.5%
CMake
3.4%
HTML
0.9%
Other
1%