#jsmess 2017-04-09,Sun

↑back Search

Time Nickname Message
02:34 🔗 phe has quit IRC (Quit: Leaving)
04:38 🔗 godane has quit IRC (Quit: Leaving.)
04:38 🔗 godane has joined #jsmess
04:52 🔗 db48x` has joined #jsmess
04:53 🔗 db48x has quit IRC (Read error: Operation timed out)
05:10 🔗 X-Scale has quit IRC (Quit: HydraIRC -> http://www.hydrairc.com <- Wibbly Wobbly IRC)
09:32 🔗 phe has joined #jsmess
10:46 🔗 Rai-chan has quit IRC (Ping timeout: 244 seconds)
10:52 🔗 Rai-chan has joined #jsmess
11:57 🔗 bwn has quit IRC (Ping timeout: 244 seconds)
12:11 🔗 bwn has joined #jsmess
15:55 🔗 phe got the sound working for macplus Sierra Boxing game by patching emscripten library_sld.js: https://hastebin.com/uxixirahoz.js
15:55 🔗 phe and in pce-macplus.cfg set cpu speed = 1
15:55 🔗 phe it's a bug in empscripten imho
16:12 🔗 SketchCow Generally? Or in the case of this?
16:12 🔗 SketchCow Like, is this a sound improvement patch?
16:36 🔗 phe should work with all, even not PCE based if they request weird sampling rate
16:37 🔗 phe See the code and the comment which is in library_sld.js 'An implementation must support sample-rates in at least the range 22050 to 96000.' but dunno why they allowed not the range but some discrete value
16:39 🔗 phe so commenting these line allow any freq < 96000
16:44 🔗 bai well...if it's not resampling within the range, if what the app supplies is at an in'between value it'll play too fast/pitch shifted
18:26 🔗 DFJustin why is it using library_sdl.js and not the full SDL port
18:27 🔗 bai sdl 1.3 vs 2.0
18:51 🔗 db48x` I compiled it with SDL2 the other day, but haven't actually done anything with it yet
18:51 🔗 db48x` is now known as db48x
18:53 🔗 db48x phe: but I'm also leaning towards setting speed=1
18:54 🔗 db48x phe: coupled with a change to the outer loop that calculates the right number of cycles to execute each time through
18:54 🔗 Vito` I suspect some of the performance issues will go away if SDL2 would work
18:55 🔗 Vito` but also you can't actually support any sample rate, right?
18:55 🔗 Vito` the browser still needs one specific sample rate
18:55 🔗 phe speed = 0 is likely to ask for trouble
18:55 🔗 Vito` we tested for that and set it in the original jsmess loader
18:56 🔗 phe bai, sure, but what the best path, ask browser to implement the psc with resampling or do it in each emulator needed it?
18:56 🔗 phe *spec
18:56 🔗 bai Vito`: the browser can definitely accept a number of different sample rates, all the standard ones
18:56 🔗 bai it just doesn't do weirdo inbetween ones
18:56 🔗 db48x Vito`: yea, PCE only supports one sample rate, but SDL2 does have SDL_ConvertAudio which I can presumably use
18:56 🔗 phe look like ff nightly resample correctly for PCE
18:57 🔗 Vito` bai: is that recent? they didn't use to
18:57 🔗 bai yeah, if sdl can't do the conversion or there isn't a library I'd be surprised
18:57 🔗 bai https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/sampleRate
18:58 🔗 bai that doesn't list the possible values, hmm
18:58 🔗 bai I think there's an api call to get a list of sample rates your system supports
18:58 🔗 phe I think that's different, the audio context use hardware capabilities but the input source can get different sample rate afaics
18:59 🔗 bai yeah
18:59 🔗 Vito` bai: https://github.com/jsmess/jsmess/issues/82
18:59 🔗 phe https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/createBuffer
18:59 🔗 Vito` at least in 2014, each browser supported only one sample rate, and you had to deliver audio at that rate for the best quality
19:00 🔗 Vito` so we detected it and told mess to output at that, which meant it resampled internally
19:01 🔗 bai hmm, dunno. I've definitely played around with a variety of different samplerates when doing webaudio stuff, but it's not really my strong suit so maybe this comes in through a different set of nodes than I was working with
19:05 🔗 db48x SDL2 still wants us to resample it, but I can try changing from SDL_OpenAudio to SDL_OpenAudioDevice and asking it not to change the sample rate
19:06 🔗 db48x heh:
19:06 🔗 db48x missing function: SDL_OpenAudioDevice pce-macplus.js:1:3592
19:12 🔗 db48x aha!
19:12 🔗 db48x requested audio format: freq=22255; format=32784; channels=1; samples=512 pce-macplus.js:1:583415
19:12 🔗 db48x obtained audio format: freq=22255; format=32784; channels=1; samples=512 pce-macplus.js:1:583415
19:13 🔗 db48x but then ReferenceError: assignment to undeclared variable SDL2 :P
19:18 🔗 db48x Invalid function pointer '768' called with signature 'vii'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this) pce-macplus.js:1:3592
19:43 🔗 db48x https://github.com/db48x/retroweb-pcejs-jsdf/commit/3d39f826c85090b4aa82759020b4ef135fb7a94e
19:44 🔗 db48x I can't figure out the function pointer error
19:46 🔗 * db48x recompiles with -g4
19:52 🔗 db48x somehow that's even less helpful
20:05 🔗 SketchCow I'm sorry I can't get c in here yet, like azakai indicated
21:12 🔗 godane has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 balrog has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 bai has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 zino has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 SketchCow has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 arkiver has quit IRC (ny.us.hub ircd.choopa.net)
21:12 🔗 datajerk has quit IRC (ny.us.hub ircd.choopa.net)
21:16 🔗 godane has joined #jsmess
21:16 🔗 balrog has joined #jsmess
21:16 🔗 zino has joined #jsmess
21:16 🔗 SketchCow has joined #jsmess
21:16 🔗 arkiver has joined #jsmess
21:16 🔗 datajerk has joined #jsmess
21:16 🔗 bai has joined #jsmess
21:16 🔗 ircd.choopa.net sets mode: +oo SketchCow bai

irclogger-viewer