Sasha Szpakowski
21b71d02b5
Add love.graphics.setCustomProjection.
...
The active projection matrix is reset when changing canvases, and when the window is resized if no canvas is active at the time.
2024-03-24 10:46:29 -03:00
Sasha Szpakowski
476e520969
Fix pointer alignment of default random generator object.
2024-02-25 11:51:33 -04:00
Sasha Szpakowski
1e97e09b28
Rework internal module registration to happen in constructors.
2024-02-24 15:21:38 -04:00
Sasha Szpakowski
64a30f177f
Merge branch 'main' into 12.0-development
2024-02-10 12:24:48 -04:00
Sasha Szpakowski
94d5864144
update year for copyright notice
2024-02-10 12:13:22 -04:00
Sasha Szpakowski
f6cdbdc868
Merge branch 'main' into 12.0-development
2022-12-31 22:46:34 -04:00
Sasha Szpakowski
0b75f6cfa5
Missed some files...
2022-12-31 22:36:48 -04:00
Sasha Szpakowski
c823dbca96
Update copyright year for 2023
2022-12-31 22:25:49 -04:00
Miku AuahDark
d082e91435
Use double-precision on all noise-related functions.
2022-09-25 17:43:47 +08:00
Miku AuahDark
ed840b24ea
Deprecate love.math.noise
2022-09-25 00:01:11 +08:00
Miku AuahDark
b285c2c866
Add love.math.perlinNoise and love.math.simplexNoise.
2022-09-24 23:51:12 +08:00
Alex Szpakowski
7f3538d2ba
Merge branch 'main' into 12.0-development
2022-01-05 21:10:27 -04:00
Alex Szpakowski
8e7fd10b6f
Update copyright year for 2022
2021-12-31 18:33:40 -04:00
Alex Szpakowski
185b53421a
Fix function declaration type mismatch (didn't cause any errors).
2021-12-24 11:41:12 -04:00
Alex Szpakowski
c8038f22df
Merge branch 'main' into 12.0-development
2021-12-24 11:35:35 -04:00
Miku AuahDark
fb815edc28
Change luaL_loadbuffer chunkname with prefixes.
2021-12-12 09:23:00 +08:00
megagrump
136c3cd277
use double precision numbers in love.math.noise
2021-11-22 14:57:05 +01:00
Alex Szpakowski
9b4aea8f17
Missed some copyright date updates
2021-04-07 20:34:24 -03:00
Alex Szpakowski
21f5ba86d3
Merge branch 'master' into 12.0-development
2021-04-07 20:33:44 -03:00
Alex Szpakowski
f89aabb0bb
Update copyright year for 2021
2021-04-04 16:14:45 -03:00
Alex Szpakowski
5f9b5a21d0
Merge default into minor
...
--HG--
branch : minor
2020-01-03 22:45:36 -04:00
Alex Szpakowski
fc4847c69d
Update copyright for the new year
2020-01-03 22:40:36 -04:00
Alex Szpakowski
c27629bd47
Re-apply commit b0094b5: Fix BezierCurve:render to avoid adding collinear points in some situations. Resolves issue #1501 .
...
--HG--
branch : minor
2019-12-31 15:45:20 -04:00
Alex Szpakowski
23db4f4a59
Remove functions that were deprecated in LÖVE 11.
...
--HG--
branch : minor
2019-12-20 00:45:20 -04:00
Alex Szpakowski
83e74e5e6c
Fix setRandomSeed and setRandomState not fully invalidating the state used by randomNormal (resolves issue #1516 ).
2019-09-26 19:38:36 -03:00
Alex Szpakowski
32f381576e
Avoid using lightuserdata in internal wrapper code for the math module.
2019-07-20 10:51:59 -03:00
Alex Szpakowski
cb4b45dcf1
Add Data:getFFIPointer. Similar to Data:getPointer but returns a cdata pointer directly (or nil if the FFI isn't available).
...
It should be preferred instead of Data:getPointer because the latter uses lightuserdata which can't store more all possible memory addresses on some new arm64 architectures, when LuaJIT is used.
2019-07-20 10:47:58 -03:00
Alex Szpakowski
2e6644fd44
Backout changeset b0094b5a9fa7f9a8f38040ec2f3d94d0a3cf31ce
2019-06-20 18:57:42 -03:00
Alex Szpakowski
fc8ede263e
Fixed BezierCurve:render to avoid adding collinear points in some situations. Resolves issue #1501 .
2019-06-16 22:48:33 -03:00
Alex Szpakowski
0752f27bdf
Update copyright year for 2019
2019-01-03 21:09:05 -04:00
Alex Szpakowski
6302602a45
Add love.math.colorToBytes and colorFromBytes, simple functions to convert between 0-1 and 0-255 (byte) colors.
2018-12-18 00:07:39 -04:00
Alex Szpakowski
5d5c2f9a96
math and data module instances are now deleted when they have no more Lua references (matches the behaviour of other modules.) Fixes the deprecation system not fully restarting when love.event.quit("restart") is called.
...
Resolves issue #1462 .
2018-12-17 16:44:13 -04:00
Alex Szpakowski
d37c53584e
Fixed the mipmaps flag in love.graphics.newImage; cleaned up a bit of vector code in love.math.isConvex.
2018-01-28 22:32:40 -04:00
Bart van Strien
fd514d8176
Update some more copyright notices
...
I am so good at using search/replace I definitely didn't need a second commit
for this.
2018-01-03 19:55:02 +01:00
Bart van Strien
e80247c191
Happy new year! ✨
2018-01-03 19:47:35 +01:00
Alex Szpakowski
9fa73f8b87
Several love.data functions now take an enum ("data" or "string") to determine whether they return a Data object or a string.
...
Changed functions are love.data.compress, decompress, encode, decode, and pack.
2017-12-22 16:13:20 -04:00
Alex Szpakowski
6dea2ab714
Clamp all color arguments to [0, 1] in cases where values outside that range don't make sense (fixed-point color values & sRGB colors). Closes issue #1315 .
...
--HG--
branch : minor
2017-11-21 19:49:52 -04:00
Bart van Strien
9e4374935d
Show (short) list of possible enum values when an invalid value is encountered ( resolves #1318 )
...
All enum errors have (hopefully) been changed to a luax_enumerror, which has a
fixed error message. If additionally a list of valid options is passed, it
lists that in the error message. For every enum error with few options I've
implemented this using a getConstants call.
This solution has been designed specifically to reduce the number of template
instantiations (as I've been told that was a concern). All new template code
happens in places where there already was an instantiation of the relevant
StringMap. Of course there is still std::vector<std::string>...
--HG--
branch : minor
2017-10-02 17:11:53 +02:00
Alex Szpakowski
90e86c329d
Add love.data module.
...
- Moved love.math.compress / decompress / decode / encode / hash to love.data.
- Changed love.data.compress/decompress to take the format argument first instead of second.
- Added love.data.newDataView. Returns a read-only subsection of an existing Data object.
- Added love.data.newByteData. Mostly useful in combination with LuaJIT's FFI as it has no extra methods currently.
- Added implementations of Lua 5.3's data packing APIs: love.data.packString / packData / unpack / getPackedSize.
Resolves issue #1336 .
Resolves issue #1331 .
--HG--
branch : minor
2017-09-24 19:25:27 -03:00
Alex Szpakowski
5f64737956
Shader:send now optionally accepts a Data object (with optional byte offset and size parameters). Resolves issue #1343 .
...
Also changed the optional 'columnMajor' argument of the matrix variant of Shader:send and Transform:setMatrix to accept enum constants instead. Valid values are "row" and "column".
--HG--
branch : minor
2017-09-23 19:47:57 -03:00
Alex Szpakowski
fee157b6b9
Functions that take a boolean argument now properly type-check for it.
...
--HG--
branch : minor
2017-08-14 22:56:20 -03:00
Alex Szpakowski
ef5897b22c
Seed love.math.random when the math module is loaded, instead of in love.run.
...
--HG--
branch : minor
2017-07-23 19:45:49 -03:00
Alex Szpakowski
34ebe18f14
Use luaL_check/optinteger instead of luaL_check/optnumber when getting integer arguments to functions. Resolves issue #1251 .
...
--HG--
branch : minor
2017-07-16 12:17:50 -03:00
Tanner Rogalsky
9084dce58f
Add bindings for setting and getting a Transform's matrix representation.
...
--HG--
branch : minor
2017-06-20 08:06:28 -04:00
Alex Szpakowski
ac697ddb0f
Clean up love’s internal Vector code a bit, and rename it to Vector2 so it’s more obvious what it is.
...
--HG--
branch : minor
2017-05-16 22:07:01 -03:00
Alex Szpakowski
70b32c47ce
Error if a non-2D/affine matrix is used with auto-batched draws, since they perform CPU-side matrix transforms on 2-component vectors.
...
--HG--
branch : minor
2017-04-23 00:12:57 -03:00
Alex Szpakowski
f8c58c54c8
love.math.randomNormal can be JIT-compiled
...
--HG--
branch : minor
2017-04-01 21:19:19 -03:00
Raidho
8572a33880
Prettifyed the code exploiting inheritance rules
...
added missing comma, added missing `override`
--HG--
branch : minor
2017-02-10 18:36:47 +03:00
Raidho
6ea1ebde9c
Data:clone ported to minor
...
minor tweaks
--HG--
branch : minor
2017-02-10 06:19:53 +03:00
Alex Szpakowski
a6669a8bb2
Merge default into minor
...
--HG--
branch : minor
2017-01-21 12:06:35 -04:00