Commit Graph

139 Commits

Author SHA1 Message Date
Alex Szpakowski 53b20b63a5 Merged default into minor
--HG--
branch : minor
2014-05-21 21:16:37 -03:00
Alex Szpakowski fd5b5aad65 Minor code cleanup 2014-05-21 21:14:08 -03:00
Alex Szpakowski 38b65b859a Merged default into minor
--HG--
branch : minor
2014-05-03 22:27:01 -03:00
Alex Szpakowski d7f1262e20 Query the Decoder instead of the current OpenAL buffer when getting the sample rate for calculations in streaming audio Sources.
Some OpenAL implementations return 0 for alGetSourcei(source, AL_BUFFER) if the source isn't static, which eventually results in returning 0 when querying the buffer's sample rate.
2014-05-02 11:31:12 -03:00
Alex Szpakowski 1bc8b7346d Added internal thread name support, for use with debuggers. 2014-05-02 08:56:23 -03:00
Aesthete 70fabedc09 Aesthete: Bug #829: Added exceptions for all spatial audio calls on stereo
sources. I had to backout the last couple of changes because the diff tool
thought I had changed the entire file, and made it impossible to see what
I had actually changed.

--HG--
branch : minor
2014-04-23 11:39:36 +10:00
Aesthete 30c211f7e3 Backed out changeset: a0191140525e
--HG--
branch : minor
2014-04-23 11:29:55 +10:00
Aesthete 5e7452034a Backed out changeset: 6efefad30fe1
--HG--
branch : minor
2014-04-23 11:29:41 +10:00
Aesthete ba21f79966 Aesthete: Bug #829: Adding missing exception guards to audio source wrapper.
--HG--
branch : minor
2014-04-23 11:15:14 +10:00
Aesthete a2473f860d Aesthete: Bug #829: Refactored all spatial stereo exception messages to static
variable.

--HG--
branch : minor
2014-04-23 10:19:26 +10:00
Alex Szpakowski 6dc10cfd15 Merged default into minor
--HG--
branch : minor
2014-04-01 20:46:31 -03:00
Alex Szpakowski 4faddcd9aa Fixed some trivial compiler warnings 2014-03-12 17:55:19 -03:00
Alex Szpakowski 60cd1456ea Merged default into minor
--HG--
branch : minor
2014-03-12 02:21:27 -03:00
Alex Szpakowski 55514720a6 Fixed some minor compiler warnings 2014-03-01 21:16:01 -04:00
Alex Szpakowski de1f105e40 the AL_SOFT_direct_channels OpenAL extension shouldn't be required for compilation 2014-02-08 02:43:13 -04:00
Alex Szpakowski 33f12a6091 Source:play now returns false if alSourcePlay failed 2014-01-29 17:04:03 -04:00
Alex Szpakowski a49c2a88c1 Increased robustness of audio module initialization (see issue #646.) Also changed Source:play to return a boolean indicating success. 2014-01-29 05:24:47 -04:00
Alex Szpakowski 9b593780b1 Removed spaces from love.audio enum strings (resolves issue #733)
--HG--
branch : minor
2014-01-15 04:41:07 -04:00
Alex Szpakowski b1edf5e7bf Added Source:getType, removed Source:isStatic (resolves issue #776)
--HG--
branch : minor
2014-01-15 04:02:24 -04:00
Alex Szpakowski 3120a0e650 Goodbye 2013, hello 2014! 2014-01-03 17:28:58 -04:00
Bart van Strien 5963e7a9cb Check whether pitch is actually a sane number 2013-12-27 16:50:30 +01:00
Alex Szpakowski 4d1846b745 Removed love.audio.newSource(source) (see issue #319) 2013-12-25 02:19:59 -04:00
Alex Szpakowski e6f2d4f1ac Added Source:clone() and love.audio.newSource(source): creates a new (stopped) Source which has all of the settable state of the original.
Static sources don’t duplicate their OpenAL data buffer when cloned (resolves issue #319). Cloned streaming sources also clone the original Decoder.
2013-12-20 00:20:41 -04:00
Alex Szpakowski eb4fdf3bbe Use a separate preprocessor define for using Framework #includes in OS X (resolves issue #796) 2013-12-13 02:37:06 -04:00
Bart van Strien 3d82eecc08 Apply the love-experiment moduleselect branch
You can now:
	- Enable and disable love's modules, implementations and libraries using configure switches
	- Use pkg-config for a couple of love's requirements
	- Build on OSX
	- Use newer versions of FreeType2
	- Get a slightly better error message using automagic
2013-12-08 19:32:32 +01:00
Alex Szpakowski fad9d25093 Removed Source:getType (resolves issue #776) 2013-10-28 19:33:22 -03:00
Alex Szpakowski b57256b3e5 Renamed Source:setRelativePosition and Source:hasRelativePosition to Source:setRelative and Source:isRelative. Updated changelog. 2013-10-25 17:05:29 -03:00
Alex Szpakowski 3e9fcacf07 Code style fixes 2013-10-20 04:02:09 -03:00
Alex Szpakowski cf6acfa258 Added Source:getChannels. Positional/directional audio only works with 1-channel (mono) sources. 2013-10-15 23:09:35 -04:00
Alex Szpakowski 13ea750454 Added Source:setCone(innerAngle, outerAngle, outerVolume). Resolves issue #643.
When combined with Source:setDirection (and Source:setPosition or love.audio.setPosition), the cone parameters allow for directional sound output from a Source.
2013-10-11 05:30:11 -03:00
Alex Szpakowski 7f3cd7f044 Added Source:setRelativePosition and Source:hasRelativePosition, if enabled the Source's position will always be relative to the listener instead of absolute. 2013-10-11 02:25:48 -03:00
Alex Szpakowski 2710c6c488 Renamed Source:s/getDistance to Source:s/getAttenuationDistances (resolves issue #632).
Fixed detection for mipmap sharpness support.
2013-10-10 23:05:45 -03:00
Alex Szpakowski 95eedcd1be Using auto for some iterators for less dense-looking code 2013-09-30 02:35:10 -03:00
Alex Szpakowski ec9dec6b80 Replaced luax_newtype with luax_pushtype (and added luax_rawnewtype for the old functionality of luax_newtype.)
luax_pushtype keeps the object in a weak table and checks the table before creating a new userdata, so it re-uses the object's existing wrapper userdata if it can, whenever the object is pushed to Lua.

This fixes some subtle issues with love objects, where using them as keys in tables would not always work as expected (https://love2d.org/forums/viewtopic.php?f=4&t=39398&p=112388#p112415). It also decreases the amount of new Lua objects created, saving the garbage collector some work.
2013-08-29 00:40:06 -03:00
Alex Szpakowski f7ca9ef557 Fixed race condition in Source:play (thanks Boolsheet) 2013-08-19 16:05:43 -03:00
Alex Szpakowski 66a773d2a7 Renamed Decoder:getBits to Decoder:getBitDepth (see issue #636) 2013-08-11 04:15:42 -03:00
Alex Szpakowski 4d6bdf4857 Added Source:getType 2013-08-03 21:30:47 -03:00
Alex Szpakowski a4ff39e0d4 Improved error checking for some enum strings (resolves issue #690).
Also moved love.audio.newSource from Lua code into C++ code
2013-08-03 21:24:43 -03:00
Bart van Strien 882313551c Rename SoundData:getBits to getBitDepth (resolve #636) 2013-07-11 14:40:52 +02:00
Bart van Strien e382c8939c Make Source:seek fail with negative offsets (resolves #667) 2013-07-11 14:19:15 +02:00
Bart van Strien ad8e0da351 Fix source reset, specifically audio wasn't always updating the AL_LOOPING flag 2013-06-30 17:29:55 +02:00
Bart van Strien 5d2b20a662 Apply patch that fixes "random" looping of streaming sources (issue #630) 2013-06-14 14:12:28 +02:00
Alex Szpakowski 4c616e409b Renamed ParticleSystem:count, Channel:count, and all getNum* functions to get*Count (issue #602) 2013-05-03 04:04:44 -03:00
Bart van Strien 3d0c5761ce Merge in default, update changelog
--HG--
branch : minor
2013-03-03 19:51:04 +01:00
Alex Szpakowski e05e8e6e6a Switched audio backends in OS X from Apple's OpenAL implementation to OpenAL Soft 2013-02-13 04:01:02 -04:00
Alex Szpakowski 96161c66f6 Updated copyright text for the new year 2013-02-05 05:32:49 -04:00
Bart van Strien 0fd4b147a4 Merge in default
--HG--
branch : minor
2013-01-27 19:15:55 +01:00
Bart van Strien 49961d66c7 Fix setVolumeLimits (issue #537) 2013-01-18 00:32:25 +01:00
vrld c70cd5b8ee Merge default branch
--HG--
branch : minor
2012-11-23 10:24:46 +01:00
vrld dcfc18192d Fix issue #494: Source:getDistance doesn't work 2012-11-23 10:24:15 +01:00