Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Castlevania X Chronicles - unavoidable audio-related softlock bug in Rondo of Blood #11091

Open
eiendream-ar opened this issue May 28, 2018 · 19 comments
Labels
Atrac3+ Issue involves sceAtrac features. I/O Affected by I/O timing settings, or other kind of I/O issue.

Comments

@eiendream-ar
Copy link

eiendream-ar commented May 28, 2018

Hi and hopefully I'm doing it right since it's my first time around here. I'm interested in this game because it has a rather interesting PC Engine emulator that overlays text directly onscreen, but the problem causes it only to run ever on real hardware in full.

Game in question: Castlevania X Chronicles [ULUS10277] - Specifically the Rondo of Blood direct emulation port that has a translation exclusive to it.
It's normally an unlockable, but gamefaqs should have a 100% save file for the collection with that taken care of.
This password for the original game X-X!V''Q unlocks a level select and most importantly the sound test, where this issue can be stress-tested much more efficiently.

A fix for this issue might be beneficial for other emulated PCE-CD compilations on PSP that also use the atrac3 codec for sound files in their BIN+CUE+WAV setup, some of it with unique content.

PPSSPP Version: Latest nightly.

What should happen?
Normal sound playback and looping, no crashes.

What happens?
Major sound bugs, some associated with crashes that prevent the game from being clearable. There are 3 areas where this problem manifests:

  • Normal gameplay: Around the midpoint of some songs (when unique composition in later parts in the song aren't even played yet) or near looping points, the music awkwardly fades out to complete silence and plays back again after the initial part is looped to.

  • The sound test: After you play one track from the sound test, and then play another track from it while the former track is still playing, the second track begins playback but the game softlocks for the duration of the entire playback. On real hardware, the playback stops after a while, and around that time the emulator sometimes exits that softlock state.
    This doesn't happen when moving from the main menu music to the sound test, or when the first played track is stopped first before playing the second one.
    The same problem observed with normal gameplay appears here as well even when the track is supposed to loop once in this menu it fades out midway.

  • Cutscenes:
    This doesn't apply to the very first cutscene narrated in German and the ending cutscene (Richter's, since the other is impossible to access because of this bug), that still nonetheless have the audio cutoff problem midways.
    But all other cutscenes during gameplay (rescuing maidens, unlocking alternate mode) which makes it effectively impossible to finish the game 100%, play as the second character (with her own cutscenes), or even see the cutscenes that have most of the translated content made specifically for this version.
    Anytime a cutscene is to begin, a softlock just like the sound test one happens in the black screen fade out just before the cutscene graphics are supposed to play, and the entirety of the cutscene audio plays over that black screen. Unlike the sound test case when it sometimes gets out of that softlock after enough time, there's no getting around this and it persists forever.

If you need a save state just before one of these cutscenes, please tell me which version of your liking to use and I'll happily oblige.

@unknownbrackets
Copy link
Collaborator

Anything in the logs when these things happen?

What graphics settings are you using? Does the video issue happen with software rendering (it will be slow)?

-[Unknown]

@LunaMoo
Copy link
Collaborator

LunaMoo commented May 28, 2018

Didn't tested everything from here, but I can't reproduce sound test problems in my game in any way.

This might be either platform specific(using win amd64 myself) or game version specific(mine's EU).

Could also be a bad copy(pretty sure there was at least one bad dump of this game used by pirates) or game breaking cheats(game swaps code when different game is selected so most cheats outside of few I made for eu version would be game breaking here;p).

@eiendream-ar
Copy link
Author

eiendream-ar commented May 28, 2018

It still happens with the software renderer, I checked.
I tried with Vulkan and OpenGL. Each time from a fresh emulator reboot.
It's not a problem with the dump either, considering the exact same version/file runs as intended on real hardware. No cheats are used.

Intel i7 CPU, AMD R7 GPU, Windows 10 x64.
Tried it with similar results on laptops with:
Intel i7 CPU, AMD Radeon 6000 series GPU, Windows 7 x64 (2017 nightly).
Intel i7 CPU, GeForce M930 GPU, Windows 7 x64 (2017 nightly).

The PPSSPP debug console shows this after the game comes back from the sound test softlock:
ATRAC3 play E[ME]: HLE\sceAtrac.cpp:570 avcodec_decode_audio4: Error decoding audio -1094995529 / bebbb1b7

The debug console doesn't display anything for the abrupt fadeout.

Most importantly, for the cutscene crash, the debug console doesn't show anything, but when I use "dump next frame to log" (which normally displays all kind of steps to drawing the next frame's graphics) it shows this single line instead of the usual wall of graphical calls:
35:30:868 ATRAC3 play N[G3D]: Vulkan\GPU_Vulkan.cpp:291 DUMPING THIS FRAME

I never tried with the EU version considering I don't own it, but I will try to get it somehow and try reproducing this bug with it.

Thanks a lot for the replies and interest.

@unknownbrackets unknownbrackets added the Atrac3+ Issue involves sceAtrac features. label May 28, 2018
@eiendream-ar
Copy link
Author

Can confirm the exact same bug appears with ULES00841.

@LunaMoo
Copy link
Collaborator

LunaMoo commented May 28, 2018

If I leave song playing for too long it does break, but I couldn't trigger it by switching, I also didn't get any soft lock(and yeah I do have fast mem enabled), the music just stops playing, tried both main menu sound test as well as rondo of blood original sound test.
I did used one non default setting - simulate UMD delays which does help in some poorly coded games and could be the reason why the game couldn't hang for me;p.

@eiendream-ar
Copy link
Author

@LunaMoo
Thanks a lot for your reply. I think it solved the biggest problem for me.

By changing "System > I/O Timing Method" to "Simulate UMD Delays", the music swaps and the cutscenes no longer softlock and proceed normally, which make the game at least finishable 100% even though the voice acting and the music backgrounds fading out suddenly is still an annoyance that I'd wish to see fixed one day.

@unknownbrackets unknownbrackets added the I/O Affected by I/O timing settings, or other kind of I/O issue. label May 29, 2018
@relu419
Copy link

relu419 commented Oct 27, 2018

@LunaMoo
Thanks a lot for your reply. I think it solved the biggest problem for me.

By changing "System > I/O Timing Method" to "Simulate UMD Delays", the music swaps and the cutscenes no longer softlock and proceed normally, which make the game at least finishable 100% even though the voice acting and the music backgrounds fading out suddenly is still an annoyance that I'd wish to see fixed one day.

A timing problem. On my US version, before the loop, the game cuts the music on Rondo of Blood. Can we skip that? I can remember the problem using the game on SD: the game runs before the loading and to OST will cut after the first loop cut.

@ghost
Copy link

ghost commented May 13, 2019

Having the same issues as the rest of you but I can confirm that changing I/O Timing Method from Fast to Simulate UMD Delays fixes the cutscenes.

The audio issues still occur with sound and music stops playing though.

@relu419
Copy link

relu419 commented May 13, 2019

Having the same issues as the rest of you but I can confirm that changing I/O Timing Method from Fast to Simulate UMD Delays fixes the cutscenes.

The audio issues still occur with sound and music stops playing though.

It's Atrac3+ problem. The loop and the cut need a right TG16 audio emulation. Only devs can solve this. Or back to an old version with some properly/better solution.

@ghost
Copy link

ghost commented May 13, 2019

Thanks for answering!

Hopefully one day this issue will be solved, luckily I own the original PC Engine version that I can play with Mednafen in the mean time.

@ghost
Copy link

ghost commented Oct 5, 2020

Related #5564 ?

@HyenaPinetree
Copy link

How is this still a problem 8 years later?? The PS4 version of these games is essentially the only functional way to play them outside of extremely expensive original hardware at this point.

I wish I had the know-how or time to figure this out on my own. Hopefully this can be resolved at some point.

@hrydgard
Copy link
Owner

Simple: sound bugs can be some of the hardest ones to fix, and nobody who has the game and abilities to debug has prioritized it yet over all the other issues. Emulation is hard, and there are some extra hard edge cases here and there that need serious work to fix. Complaining won't help.

@opsodps
Copy link

opsodps commented Aug 28, 2023

Music cutting out in the original Rondo of Blood still occurs on v1.15.4. Cutscene softlock also occurs with default settings, but changing I/O Timing Method from "Fast" to "Simulate UMD Delays" fixes it. As far as I know there's still no way to fix the first issue.

@EspeonScottie
Copy link

Music cutting out in the original Rondo of Blood still occurs on v1.15.4. Cutscene softlock also occurs with default settings, but changing I/O Timing Method from "Fast" to "Simulate UMD Delays" fixes it. As far as I know there's still no way to fix the first issue.

Same here on the newest v1.16.

@sum2012
Copy link
Collaborator

sum2012 commented Nov 11, 2023

v1.16.6-280-g6d063ce3e
I test no problem for the sound

@MikelAibi
Copy link

v1.16.6-280-g6d063ce3e I test no problem for the sound

I just tested this specific build, and the issue still persists - music still gets cut off

@sum2012
Copy link
Collaborator

sum2012 commented Dec 9, 2023

@MikelAibi does it same as #5564 ?

@MikelAibi
Copy link

@MikelAibi does it same as #5564 ?

It's the same as described in this comment - the music just stops playing halfway through and abruptly stops playing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Atrac3+ Issue involves sceAtrac features. I/O Affected by I/O timing settings, or other kind of I/O issue.
Projects
None yet
Development

No branches or pull requests

10 participants