aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* SimpleSineSynth: Reuse WorkerThread, drop handcrafted code ..Sven Gothel2023-10-031-113/+30
| | | | | Actually new GlueGen WorkerThread was created from GLMediaPlayer, which was also the template for this one and hence lead to generalization to WorkerThread.
* ALAudioSink: Allow disabling using AL_SOFT_events via setUseSOFTEvents(boolean)Sven Gothel2023-10-032-5/+16
|
* SimpleSineSynth: Ensure stop() destroys ALAudioSink even if streamWorker is ↵Sven Gothel2023-10-031-0/+2
| | | | not running
* ALAudioSink.dequeueBuffer(..): AL_SOFT_events cumulated released buffers is ↵v2.5.0Sven Gothel2023-08-011-5/+20
| | | | 'sometimes wrong'. Workaround: Query released buffers after receiving event and use minimum.
* AudioSystem3D.checkAL*Error(): Close single quote in error messageSven Gothel2023-08-011-2/+2
|
* AL_SOFT_events: Define 'ALCcontext` as `UserParam` type for more claritySven Gothel2023-07-103-10/+9
|
* ALAudioSink.destroy(): Shutdown alEventCallbackSOFT properly (only if ↵Sven Gothel2023-07-091-7/+9
| | | | hasAL_SOFT_events, 1st disable all events); growBuffers(): No pre-condition exception for hasAL_SOFT_events
* ALContextKey.equals(): Use cached nativeAddress of other item as well.Sven Gothel2023-07-091-2/+1
|
* GlueGen cfg files: Remove now unused import java.security.AccessControllerSven Gothel2023-07-093-3/+0
|
* ALAudioSink: Utilize AL_SOFT_events if available, i.e. use callback for ↵Sven Gothel2023-07-094-43/+225
| | | | | | | released buffer count instead of polling With wait == true, we simply wait until enough buffers have arrived, otherwise take what we got - both w/o polling and querying the alSource.
* Add OpenAL extension AL_SOFT_events using userParam ALCcontext as key for ↵Sven Gothel2023-07-095-0/+120
| | | | | | GlueGen JavaCallback https://openal-soft.org/openal-extensions/SOFT_events.txt
* Sound3d.Context: destroy() shall only 'null' thread-local context if this is ↵Sven Gothel2023-07-091-4/+4
| | | | current; Expose hasALC_thread_local_context to avoid double checks
* ALExtImpl: Remove unused importsSven Gothel2023-07-091-7/+0
|
* Use GlueGen's SecurityUtil.doPrivileged(..) instead of AccessController, ↵Sven Gothel2023-07-093-12/+3
| | | | remove dead code
* Fix file mods in make/configSven Gothel2023-07-098-0/+0
|
* Adopt to GlueGen commit 952e0c1f83c9e0583a97d39988a6ba1428911c8cSven Gothel2023-06-093-3/+0
|
* Promote SimpleSineSynth to API (util) from Synth02AL, allowing user to have ↵Sven Gothel2023-05-232-387/+438
| | | | a simple sound source to test
* ALAudioSink: Use and expose Sound3D object, allow user app to deal w/ ↵Sven Gothel2023-05-231-453/+321
| | | | | | | | | | | JOAL/OpenAL easier and reuse Context context locking Context locking logic has been fixed and moved to Sound3D Context class (beside many other transparency changes), see commit afb386e13fd00fde1401d4551ee4790b1f6d5e09. This also aligns w/ AudioSink API change of Gluegen commits - c04726720a57f8db42f2621ad58ff3bd42006c63 - 6a74d16a805a4204093972bb91361b2aa633065c
* Sound3D: Further OO wrapper to be used in ALAudioSink: Context locking, ↵Sven Gothel2023-05-237-93/+452
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ALCcontext recreation, .. Context - Recursive context locking (only 1st shall do native makeCurrent, only last shall do native release) - Access to the current Context instance (thread local storage) - Obey "One context can only be current on one thread, and one thread can only have one context current!" - ALCcontext recreation within lock, allowing to change native OpenAL specifics via attr list - ALCcontext creation (initial) w/ attr list Device - Retrieve name if default name null has been given - Expose device name - Allow to open() again Source - Allow lazy creation w/ invalid ID - Allow create() post instantiation (for a single source) - Throw ALException in all queued buffer methods as they are crucial in multithreading streaming. - Add queue buffer with OpenAL buffer-id int[] arrays variant to be used w/o Buffer Listener - Fix (get|set)Orientation() API doc: It's 'at' vector, then 'up' vector. General: - Have toString() - Added versatile AudioSystem3D.check*Error(..) Earlier Sound3D changes - 7f73d50c90d05cf7388f23977ca956a4933019ad - 64b40bd4359cad46ebf62751ea342d80205bd98b
* ALException: Suppress serial warningSven Gothel2023-05-231-0/+1
|
* ALAudioSink: Use float in seconds for duration (AudioFormat and ↵Sven Gothel2023-05-212-82/+102
| | | | 'avgFrameDuration') to avoid losing precision when dealing with stats, averages etc
* ALAudioSink: Enhance description re 'AudioFrame' and 'frameDuration'; Drop ↵Sven Gothel2023-05-211-5/+10
| | | | unused field 'avgFrameDuration'.
* Fix ALAudioSink.dequeueBuffer(): AL_BUFFERS_PROCESSED result is total not ↵Sven Gothel2023-05-201-5/+14
| | | | | | | | | | | | | | | | | | accumulative while waiting (not yet dequeueing), ... Further: - brackets were missed in 'sleep =', i.e. 'releaseBufferLimes-releasedBuffers * avgBufferDura' -> '(releaseBufferLimes-releasedBuffers) * avgBufferDura)' - The minimum sleep of avgFrameDuration 'sleep = Math.max(avgFrameDuration, ..' lead to cut-off smaller sleep cycles and the else branch would only sleep for less (1ms) multiple times. Hence use the minimum of 2ms, where we subtract 1ms for busy polling. Notable, this is an extreme situation of small buffer sizes (duration), but may happen on like synthesizer applications (jsyn). We actually could use latency (refresh cycle) as used in OpenAL-Soft, but this is an undocumented feature .. sort of.
* ALHelpers.getALFormat(..): Drop alGetEnumValue("type") and use 'type' via ↵Sven Gothel2023-05-201-17/+18
| | | | | | | | | ALExtConstants directly: Fixes failing al.alGetEnumValue("AL_FORMAT_STEREO_DOUBLE") al.alGetEnumValue("AL_FORMAT_STEREO_DOUBLE") failed w/ OpenAL-Soft, despite having AL_EXT_MCFORMATS, AL_EXT_FLOAT32 and AL_EXT_DOUBLE supported. Notable, al.alGetEnumValue("AL_FORMAT_MONO_FLOAT32") did work.
* build.xml: Fix 7z archive: README.{txt -> md}Sven Gothel2023-05-201-1/+1
|
* Synth02AL: Use ALAudioSink's default latency instead of fixed frameDuration, ↵Sven Gothel2023-05-201-9/+16
| | | | | | using actual OpenAL frame processing refresh value Also pre-allocate sampleBuffer to 30ms actual format, using AudioFormat.getDurationsByteSize(..)
* ALAudioSink.toString(): Allow null==chosenFormat (pre init string ↵Sven Gothel2023-05-201-1/+1
| | | | representation)
* README.{txt -> md) and update text incl. licenseSven Gothel2023-05-203-132/+187
|
* Synth02ALL Use float32 (native openal-soft format) if availableSven Gothel2023-05-201-13/+40
|
* ALAudioSink: Add getSourceCount() and cleanup error handling and initImpl() ↵Sven Gothel2023-05-201-237/+248
| | | | | | locking and exit. initImpl() shall just return false, not throwing an exception.
* JoalVersion: Cleanup dead branchesSven Gothel2023-05-202-14/+14
|
* Demos OpenALTest/Synth02AL: Show JoalVersionSven Gothel2023-05-192-22/+14
|
* ALAudioSink: Query latency and re-create context @ init w/ latency ↵Sven Gothel2023-05-191-137/+245
| | | | (refresh-rate) if frameDuration < defaultLatency
* JoalVersion: List all devices, output devices w/ latency and source count ↵Sven Gothel2023-05-191-1/+113
| | | | (mono, stereo) using undocumented queries
* ALAudioSink.lockContext(): Only check error state if AL ↵Sven Gothel2023-05-181-14/+29
| | | | makeContextCurrent()/alcSetThreadContext() fails (returns false)
* Sound3D/Context: Use same base ctor to initialize ↵Sven Gothel2023-05-182-3/+2
| | | | `hasALC_thread_local_context`, benefitting from thread-local-context
* Sound3D: Make all OO wrapper fully transparent and stand-alone, allow ↵Sven Gothel2023-05-188-154/+330
| | | | | | | | | | | mix-and-match; Align Context makeCurrent/release w/ ALAudioSink ... Align Context makeCurrent/release w/ ALAudioSink - use ALC_EXT_thread_local_context if available - use a recursive lock - same release method as makeCurrent - ALC_EXT_thread_local_context or traditional - destroy also releases the context and fully unwinds lock
* ALAudioSink: Don'e check errors before context; Track method of ↵Sven Gothel2023-05-181-4/+11
| | | | | | context-locking and release same way; Destroy shall also release context. Result is 'ALSOFT(WW)' free.
* Doc, scripsts/tests.sh: Mentione OpenAL-Soft environment variablesSven Gothel2023-05-182-0/+8
|
* ALAudioSink: Promote to public, be fully functional regarding AudioFormat ↵Sven Gothel2023-05-183-104/+390
| | | | and OpenAL paremeter. Can be 'plugged' into existing OpenAL logic.
* Synth02AL: Fix API doc re reduces latencySven Gothel2023-05-171-2/+2
|
* README/index.html: Update Web resources & URLs, add details about ↵Sven Gothel2023-05-172-6/+53
| | | | audio-backens per platform and contained openal-soft library
* ALAudioSink: Enhance using AL_EXT_MCFORMATS (max channels == 8), ↵Sven Gothel2023-05-172-11/+67
| | | | | | | | | | | AL_EXT_FLOAT32, AL_EXT_DOUBLE Note: AL_SOFT_buffer_samples is n/a since openal-soft 1.18.0 ALHelpers.getALFormat(..) uses cached booleans for optionally used available extensions. Add DEBUG output for ALAudioSink.init() and ALAudioSink.isSupported(), allowing to track supported and used formats.
* make/scripts/tests.sh: Adjust D_ARGS and add X_ARGS for optional FlightRecorderSven Gothel2023-05-171-2/+10
|
* ALAudioSink.toString(): Show hasALC_thread_local_context value ('tlc')Sven Gothel2023-05-171-1/+1
|
* ALAudioSink.dequeueBuffer(): wait == true: Fix sleep cycle and use sleep(1) ↵Sven Gothel2023-05-172-28/+68
| | | | | | | if slept long enough but giving better threading perf for openal-soft This with exclusive context gives us no distortion at 3x 12ms frames, reduced from 3x 16ms. See Synth02AL.
* ALAudioSink: Add exclusive locking allowing less context management overheadSven Gothel2023-05-171-0/+23
|
* Manual Demos: Add two simple sine wave synthesizer, Synth02AL may be ↵Sven Gothel2023-05-173-1/+688
| | | | enhanced to a general synth solution
* OpenALTest: Drop nonsense LOOPING test on buffer (only applies to a source)Sven Gothel2023-05-171-4/+0
|
* JoalVersion: Accept null ALC instanceSven Gothel2023-05-171-0/+4
|