Alex Szpakowski
04ca33d127
Updated Xcode project with new bezier files
2013-05-12 17:04:56 -03:00
vrld
aa4d96317f
[bezier curve] add missing files
2013-05-12 22:01:12 +02:00
vrld
19eade843c
Add support for Bezier curves of arbitrary degree.
...
New functions:
bezier = love.math.newBezierCurve(control-points)
degree = bezier:getDegree() -- degree = #control-points - 1
x,y = bezier:getControlPoint(pos) -- pos < 0 => string.sub semantics
bezier:setControlPoint(pos, x, y) -- pos < 0 => string.sub semantics
bezier:insertControlPoint(x,y, [pos = -1])
x,y = bezier:eval(t) -- 0 <= t <= 1
polyline = bezier:render([accuracy = 5]) -- returns a table of points
Example:
function love.load()
b = love.math.newBezierCurve(10,10, 80,400, 380,400, 470,10)
end
function love.draw()
if not curve then -- curve rendering is expensive-ish
curve = b:render()
end
love.graphics.line(curve)
end
2013-05-12 21:57:06 +02:00
Alex Szpakowski
aa59761177
Fixed smooth lines with love.graphics.origin() after love.graphics.scale
2013-05-12 16:13:32 -03:00
vrld
e9d0204cdc
Disallow concave shapes as geometry.
2013-05-12 13:01:05 +02:00
vrld
d454be7025
Add love.math.isConvex()
...
Checks whether a given polygon is convex or not.
2013-05-12 13:00:08 +02:00
Alex Szpakowski
c1cbd610e6
Fixed the default blend mode (and other related state)
2013-05-12 05:49:00 -03:00
Alex Szpakowski
b391a9f4a6
Added love.window.hasMouseFocus (issue #120 )
2013-05-11 15:57:16 -03:00
Alex Szpakowski
ff77eb4b29
Added love.window (issue #6.) All window-related functions have been moved from love.graphics to love.window.
...
love.graphics.setCaption has been renamed to love.window.setTitle.
2013-05-10 22:32:15 -03:00
vrld
13dd8d3199
Faster (and less WTF-ish) computation of current pixel size for line drawing.
2013-05-10 19:09:17 +02:00
Bart van Strien
8a5c8c4dc4
Use tail calls to event handlers from love.handlers
2013-05-10 19:06:12 +02:00
Bart van Strien
79d1a7a6ef
Add love.mousefocus (partial issue #120 ) temporary name (see issue #573 ) and it's waiting for an exposed love.window to get a check, too
2013-05-10 19:03:16 +02:00
Bart van Strien
0a422daa75
Add Contact:getChildren (pull request #15 )
2013-05-10 17:40:04 +02:00
Bart van Strien
402ae4638a
Make ImageData:setPixel accept a table (issue #582 )
2013-05-10 17:28:55 +02:00
Bart van Strien
fb8a94a4a3
Enable looping in tracker formats with looping support (issue #421 )
2013-05-10 17:00:15 +02:00
Bart van Strien
16e27d95b1
Rename ParticleSystem:setLifetime/setParticleLife and getters to setEmitterLifetime/setParticleLifetime (issue #601 )
2013-05-10 16:50:20 +02:00
Bart van Strien
721d50c2ef
Make most love.filesystem functions return nil, err instead of erroring (when used correctly)
...
Note that argument exceptions, for instance, are still thrown as errors.
Also fixes a potential uncaught exception with getSize being called for the optional
size arg in read, now it just uses the ALL constant instead.
File:read no longer opens and closes a file automagically (this was undocumented, and weird)
NOTE: the love.filesystem.lines iterator can still error, but this should only happen in
case there's something really, really wrong (otherwise love.filesystem.lines would've failed
already)
NOTE: love.filesystem.lines still errors, because otherwise you'd get weird errors from the for
loop (namely 'attempt to call nil value') instead of seeing anything useful
2013-05-10 16:39:02 +02:00
Alex Szpakowski
00060af4c1
Updated changelog
2013-05-10 01:01:40 -03:00
Alex Szpakowski
9fc2a085cd
Updated love.timer.getTime to be microsecond-precise and monotonic (thanks Boolsheet), removed the now-obsolete love.timer.getMicroTime (issue #492 )
2013-05-09 23:12:50 -03:00
Alex Szpakowski
4952ebd5d9
love.filesystem.newFile now accepts an optional FileMode parameter ("r", "w", "a") to better mirror io.open
2013-05-08 17:47:37 -03:00
Alex Szpakowski
c7ebb50b70
love.graphics.newParticleSystem now uses a default buffer size of 1000 (issue #598 )
2013-05-08 17:19:25 -03:00
Bart van Strien
759930164f
Don't hardcode include paths in makefile.am, use $(srcdir) instead (issue #612 )
2013-05-08 14:01:55 +02:00
Alex Szpakowski
7ab3809165
Fixed Object:typeOf for love.physics objects new to 0.8.0, removed vestigial ColorMode code
2013-05-07 15:23:26 -03:00
Alex Szpakowski
63404f7097
Added love.graphics.getRendererInfo(infotype). Useful for creating more informative error reports and advanced debugging.
...
Returned string can be highly system-dependent, so don't rely on its output!
infotype can be "name", "version", "vendor", or "device"
2013-05-05 16:47:42 -03:00
Alex Szpakowski
08d6e658c1
Removed love.graphics.newStencil (issue #569 )
2013-05-03 15:49:39 -03:00
Alex Szpakowski
c9003750fa
Removed extension and "."'s from default filesystem identity (issue #568 )
2013-05-03 15:43:10 -03: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
Alex Szpakowski
3bf43dadd8
Renamed CompressedData:getNumMipmaps to CompressedData:getMipmapCount; Improved type-checking error messages for some functions which expect function arguments
2013-05-02 17:26:50 -04:00
Alex Szpakowski
77c6efd8fd
Fixed love.mouse.setPosition when called in love.load (issue #611 )
2013-05-02 07:05:14 -07:00
Alex Szpakowski
f8c7e2cab8
Code cleanup
2013-05-01 23:18:25 -07:00
Alex Szpakowski
9ccf013570
Added love.math.noise(x, [y, z, w]). Calculates the 1D, 2D, 3D or 4D Simplex noise value at a particular coordinate
2013-05-01 18:26:40 -07:00
Alex Szpakowski
1edfbb766f
Misc. fixes
2013-05-01 16:17:42 -07:00
Alex Szpakowski
8b50dd499b
Removed now-unnecessary optional filter parameters from love.graphics.newImageFont
2013-04-28 18:15:03 -07:00
Alex Szpakowski
ad2239aaaf
Error instead of crash when love.graphics.newScreenshot fails
2013-04-28 11:12:19 -07:00
Alex Szpakowski
b44c083894
Added Shader:sendInt
2013-04-27 19:26:32 -07:00
Alex Szpakowski
fb9f8d2962
Added the getString method to all Data objects (issue #608 )
2013-04-26 22:35:01 -07:00
Alex Szpakowski
16f3a93f28
Removed vestigial internal code for Data:getPointer
2013-04-26 22:05:58 -07:00
Bart van Strien
5c2b70f8ab
Add man page (thanks Miriam Ruiz for the original) and make automake install and distribute it
2013-04-26 14:42:16 +02:00
Michał Górny
53408e3768
Install file associations and icons using autotools (issue #605 )
...
Condensed version of pull request #24 , containing the following commits:
- 31f803f Install .desktop and mime-info files with autotools.
- a354096 unix: Install icon using autotools as well.
- 4b1beb2 Fix Icon= in love.desktop.
- d0d3fe4 unix: Install game file icon as well.
- 9a6e291 unix: Update/fix README file name in Makefile.am.
All of the above commits were made by Michał Górny, and this single
code import was committed by Bart van Strien (so blame me if I broke
it..)
2013-04-26 14:20:49 +02:00
Alex Szpakowski
97f7ad1a54
Fixed extern matrices
2013-04-25 11:16:43 -07:00
Alex Szpakowski
0130b726de
Improved error messages when sending bad values to a shader (also issue #587 )
2013-04-24 23:19:37 -07:00
Alex Szpakowski
4e9050216f
Updated changelog
2013-04-24 16:01:16 -07:00
Alex Szpakowski
d0970658bf
Exposed Geometry:setVertexColors and Geometry:hasVertexColors, to enable/disable per-vertex colors.
...
Vertex colors are automatically enabled if newGeometry or setVertex is called with a color other than 255,255,255,255
2013-04-24 12:04:24 -07:00
Alex Szpakowski
3b05ec0635
Geometries now automatically use per-vertex colors when drawing if any vertex has a custom color set, otherwise the constant color is used.
...
Still not a perfect solution, but it works better than before
2013-04-23 23:25:45 -07:00
Alex Szpakowski
a5eaffe625
Disabled opengl debug output until it can be improved & made optional
2013-04-23 16:47:22 -07:00
Alex Szpakowski
97d61dda96
Optimized Geometry:setVertex
2013-04-23 01:02:13 -07:00
Alex Szpakowski
8de3a7c708
Fixed love.graphics.getColor before setColor is called
2013-04-22 23:34:28 -07:00
Alex Szpakowski
ce8c8876fd
Updated Visual Studio project for Geometry files (thanks Boolsheet)
2013-04-22 10:02:49 -07:00
Alex Szpakowski
38b7e19914
Fixed Geometry:flip
2013-04-21 19:54:05 -07:00
Alex Szpakowski
f05e681b24
Error instead of crash when love.graphics.newGeometry fails
2013-04-21 18:49:56 -07:00