Open hatkidchan opened 3 years ago
Ok, I've found workaround, problems with sound occurring only with alsa backend, with openal everything is fine. I've just added that before including PGEX:
#define USE_ALSA
And, instead of -lasound
now I'm using -lopenal
. But still, in /Videos/
is used older version of pgex
So, I've just tried to build
Videos/OneLoneCoder_PGE_SoundTest.cpp
and it throws this:Then I've changed
olcPGEX_Sound.h
to one fromExtensions
, and then it's compiles successfully, BUT when I ran compiled binary, inpavucontrol
volume is over 100%, but nothing is playing. Also waveform is showing normally, but no sound at all, except "clicking sound" on start.Screenshot of pavucontrol
Screenshot of waveform in application
I think waveform is showing normally because it's processed before writing samples chunk into sound sinkAlso I've tried to play sound after loading WAV and playing it inside
OnUserCreate
, and I got "beautiful" glitchy noise.I'm using this command to compile:
g++ -lX11 -lGL -lpthread -lpng -lasound -lstdc++fs -std=c++17 -o OneLoneCoder_PGE_SoundTest OneLoneCoder_PGE_SoundTest.cpp
Some other info (which I hope should help)
pactl info
System info