asakous / Neo-EmuELEC-H3

Neo-EmuELEC-H3, retro emulation for Allwinner H3 devices. Based on shantigilbert EmuELEC https://github.com/EmuELEC/EmuELEC .
53 stars 16 forks source link

Scummvm standalone choppy sound #4

Closed Broos-E closed 3 years ago

Broos-E commented 3 years ago

Hi when trying to play Scummvm games with standalone version the sound is all choppy and unplayable.

EmuELEC Run Log ##############################################

EmuELEC

Retro emulation for Amlogic Devices

Based on CoreELEC

############################################## EmuELEC (Community - EmuELEC is FREE! NOT FOR SALE!): 3.7 (H3.arm) PLATFORM: scummvm ROM NAME: /storage/.config/scummvm/games/ft.scummvm BASE ROM NAME: ft.scummvm USING CONFIG: /storage/.config/retroarch/retroarch.cfg 1st Argument: /storage/.config/scummvm/games/ft.scummvm 2nd Argument: -Pscummvm 3rd Argument: --core=SCUMMVMSA 4th Argument: --emulator=SCUMMVMSA Full arguments: /storage/.config/scummvm/games/ft.scummvm -Pscummvm --core=SCUMMVMSA --emulator=SCUMMVMSA --controllers=-p1index 0 -p1guid 03000000790000001c18000011010000 Run Command is: /usr/bin/bash /usr/bin/scummvm.start sa /storage/.config/scummvm/games/ft.scummvm Emulator Output is: Set-Audio: Using audio device hw:1,0 Connection failure: Connection refused pa_context_connect() failed: Connection refused Set-Audio: neither the PulseAudio module module-alsa-card or module-alsa-sink was found. Nothing to unload Set-Audio: PulseAudio will enable timer-based audio scheduling Set-Audio: PulseAudio module-alsa-sink loaded, setting a volume of 100% Set-Audio: PulseAudio will use sink 1 alsa_output.temp_sink module-alsa-sink.c s16le 2ch 44100Hz IDLE Set-Audio: FluidSynth service loaded successfully Set-Audio: SDL2 set environment variable SDL_AUDIODRIVER=pulseaudio [?25lUsing joystick: TGZ Controller WARNING: SDL mixer output buffer size: 512 differs from desired: 1024! User picked target 'ft' (engine ID 'scumm', game ID 'ft')... Looking for a plugin supporting this target... SCUMM [all games] Using joystick: TGZ Controller WARNING: Language file is forced to be ignored! [?12l[?25hSet-Audio: Using audio device hw:1,0 Set-Audio: PulseAudio module-alsa-sink unloaded Set-Audio: FluidSynth service successfully stopped Set-Audio: PulseAudio will enable timer-based audio scheduling Set-Audio: PulseAudio module-alsa-sink loaded, setting a volume of 100% Set-Audio: PulseAudio will use sink 1 alsa_output.temp_sink module-alsa-sink.c s16le 2ch 44100Hz IDLE Set-Audio: SDL2 set environment variable SDL_AUDIODRIVER=pulseaudio Using device path: /js Using button mode: hold Load cfg file ... Amlogic ini not found /storage/.kodi/addons/script.emuelec.Amlogic.launcher/config/jslisten.cfg Amlogic-ng ini not found /storage/.kodi/addons/script.emuelec.Amlogic-ng.launcher/config/jslisten.cfg Will Run: /usr/bin/killall scummvm button1: 10 button2: 11 Call succesfull Call succesfull exit 0

asakous commented 3 years ago

cpu load too high?

edit scummvm.start change set_audio "pulseaudio" to alsa. maybe can fix audio problem

Broos-E commented 3 years ago

ok where is the file scummvm.start located?

ok i found it but it would not let me overwrite the changes

asakous commented 3 years ago

follow my steps.

  1. copy /usr/bin/scummvm.start to ~/.config/emuelec/scripts
  2. edit ~/.config/emuelec/scripts/scummvm.start change set_audio "pulseaudio" to set_audio "alsa". 3:. edit ~/.config/emuelec/scripts/emuelecRunEmu.sh line 218 change RUNTHIS='${TBASH} /usr/bin/scummvm.start sa "${ROMNAME}"' to RUNTHIS='${TBASH} /storage/.config/emuelec/scripts/scummvm.start sa "${ROMNAME}"'

and test it.

Broos-E commented 3 years ago

did not make a difference

EmuELEC Run Log ##############################################

EmuELEC

Retro emulation for Amlogic Devices

Based on CoreELEC

############################################## EmuELEC (Community - EmuELEC is FREE! NOT FOR SALE!): 3.7 (H3.arm) PLATFORM: scummvm ROM NAME: /storage/.config/scummvm/games/ft.scummvm BASE ROM NAME: ft.scummvm USING CONFIG: /storage/.config/retroarch/retroarch.cfg 1st Argument: /storage/.config/scummvm/games/ft.scummvm 2nd Argument: -Pscummvm 3rd Argument: --core=SCUMMVMSA 4th Argument: --emulator=SCUMMVMSA Full arguments: /storage/.config/scummvm/games/ft.scummvm -Pscummvm --core=SCUMMVMSA --emulator=SCUMMVMSA --controllers=-p1index 0 -p1guid 03000000790000001c18000011010000 Run Command is: /usr/bin/bash /storage/.config/emuelec/scripts/scummvm.start sa /storage/.config/scummvm/games/ft.scummvm Emulator Output is: Set-Audio: Using audio device hw:1,0 Connection failure: Connection refused pa_context_connect() failed: Connection refused Set-Audio: neither the PulseAudio module module-alsa-card or module-alsa-sink was found. Nothing to unload Set-Audio: PulseAudio will enable timer-based audio scheduling Set-Audio: PulseAudio module-alsa-sink loaded, setting a volume of 100% Set-Audio: PulseAudio will use sink 1 alsa_output.temp_sink module-alsa-sink.c s16le 2ch 44100Hz IDLE Set-Audio: FluidSynth service loaded successfully Set-Audio: SDL2 set environment variable SDL_AUDIODRIVER=pulseaudio [?25lUsing joystick: TGZ Controller WARNING: SDL mixer output buffer size: 512 differs from desired: 1024! User picked target 'ft' (engine ID 'scumm', game ID 'ft')... Looking for a plugin supporting this target... SCUMM [all games] Using joystick: TGZ Controller WARNING: Language file is forced to be ignored! [?12l[?25hSet-Audio: Using audio device hw:1,0 Set-Audio: PulseAudio module-alsa-sink unloaded Set-Audio: FluidSynth service successfully stopped Set-Audio: SDL2 set environment variable SDL_AUDIODRIVER=alsa Using device path: /js Using button mode: hold Load cfg file ... Amlogic ini not found /storage/.kodi/addons/script.emuelec.Amlogic.launcher/config/jslisten.cfg Amlogic-ng ini not found /storage/.kodi/addons/script.emuelec.Amlogic-ng.launcher/config/jslisten.cfg Will Run: /usr/bin/killall scummvm button1: 10 button2: 11 Call succesfull exit 0

asakous commented 3 years ago

try change audio setting in ScummVM Audio tab

Broos-E commented 3 years ago

again it makes no difference. is this not anything? "WARNING: SDL mixer output buffer size: 512 differs from desired: 1024"

asakous commented 3 years ago

choppy sound is cause by high CPU load https://freeimage.host/i/27app4 maybe EmuELEC also affected too.

the temporary solution is change AUDIO_DRIVER=alsa in /etc/fluidsynth/fluidsynth.conf file but may lost mixed sound functionality

please backup file before you do that.

asakous commented 3 years ago

yesterday I played monkey Island 1 . I didn't find any sound problem. I though it was high CPU problem . but actually not . @Broos-E I need to more information. or just tell me how to reproduce this bug. include Scummvm settings.

Broos-E commented 3 years ago

sorry i think my orange pi pc has taken its last breath now and stopped working, not sure why but have tried several power cables. the only orange pi i have left now is PC 2 H5. fingers crossed.

asakous commented 3 years ago

that's too bad. I temporary close this issue . until someone has same problem reported.

asakous commented 3 years ago

@Broos-E I added a mt-32 emulator for Scummvm and will be published next release. check out https://www.youtube.com/watch?v=sElM1VesQqs

mt32 music are awesome !

aurunmilla commented 3 years ago

hi, i'm on emuelec 4.0 and on s905X3. ScummVM on this release seems has serious issue. Libretro work goog but return every time an error on exit, and the stand alone high suffer of bad frames drop.

asakous commented 3 years ago

@aurunmilla you are asking the question in the wrong place. this repo is for H3 chips not for Amlogic chips. or follow my instruction above. may help you fix the problem.