-
Notifications
You must be signed in to change notification settings - Fork 9
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
Runs on half speed on RPi 3 #1
Comments
I'll try to have a look at it within the next couple of days. I've got a Pi3 standing by :) |
Hi, just compiled and ran it successfully on my Pi3. No playback issues. Which song where you testing? |
we have accidently borrowed your votedisk.v2m |
Sorry, I've got none of your issues. I've uploaded my compiled version here, https://jgilje.net/prosjekter/v2m/, if you'd like to compare. I also checked against a recording of the original demo, at https://www.youtube.com/watch?v=muMqrNZz0dQ, and noticed some effects are missing when played with this player. But this don't match the problem you're describing. |
Still runs on half speed on your own binary. |
I'm starting to think you don't get the expected audio format back from SDL. In https://github.com/jgilje/v2m-player/blob/master/tinyplayer.cpp#L36. I never implemented a check on whether the actual SDL_AudioSpec matches the requested format. Are you able to debug this code yourself? If not, I can compile a test-build to try to pinpoint the bug. |
jgilje, what's special about this format ? couldn't find much info. |
@frranck it's a soft-synth created by farbrausch (https://en.wikipedia.org/wiki/Farbrausch) and used in many (most? all?) of their demos. |
perhaps, but right now we are focusing on a issue related to sample rate & speed. Also I might be able to debug the code, and a SDL_AudioSpec check sounds like it would fix this problem. |
@jthecodebuilder i just added some code for checking and validating the actual audio format returned by SDL. give it a go, and let me know if it reports any errors. |
@frranck probably, but as already noted this issue is for a different topic. feel free to open a new issue when they land a stable API :) |
got "INFO: Failed to get requested format, wanted 8120, got 8010" when attempting to play it and then it quits |
Just now, while looking through the code (thinking the values im looking for will never be found), line 63 of v2mplayer.h contains a very important value which can alter the speed, which would be the perfect place to implement a failsafe for when the audio format isn't the expected one! yay |
but ive also found that the static values in synth_core need to be auto-tweaked as well...! |
Nope, the failed format message means SDL failed to open the audio output device using the requested format. The requested format is 32-bit floats (which is what the soft-synth itself outputs), but the actual format returned by the audio device is 16-bit integers (ref. SDL_audio.h). I just committed a change which should cause SDL to do this conversion automaticly. |
Well, darn. I thought I had caught the bug in it's tracks. Atleast it finally plays fine now. Now all it needs now is those effects fixed and then this is a very good port to SDL! |
Compiles successfully on Raspbian, but seems to play at half speed. How do we/us fix this?
The text was updated successfully, but these errors were encountered: