Alex Szpakowski
c7b45b3505
Updated copyright for the new year
2014-12-31 19:32:43 -04:00
Alex Szpakowski
c6896dfc4e
Consolidated some duplicate code in SpriteBatch:add.
2014-09-18 20:29:47 -03:00
Alex Szpakowski
5dda0c08eb
Slightly improved the performance of SpriteBatch:setBufferSize.
2014-09-18 18:30:56 -03:00
Alex Szpakowski
d59c76a55f
Reduced the number of explicit retain/release method calls on love objects. Less chance of bugs!
2014-08-07 14:53:17 -03:00
Alex Szpakowski
f0fa63ba47
Backported commits 145524a and 7785b4b from minor into default (Added SpriteBatch:flush, deprecated SpriteBatch:bind/unbind, SpriteBatch:flush is called implicitly when the spritebatch is drawn.)
2014-06-17 21:52:56 -03:00
Alex Szpakowski
fd5b5aad65
Minor code cleanup
2014-05-21 21:14:08 -03:00
Alex Szpakowski
40242689b1
Fixed rendering to multiple canvases, removed some redundant OpenGL calls when switching between canvases
2014-01-30 21:09:13 -04:00
Alex Szpakowski
7556fde5e6
Added antialiasing (MSAA) support to Canvases via a new optional parameter. Added Canvas:getFSAA.
2014-01-27 01:31:41 -04:00
Alex Szpakowski
3120a0e650
Goodbye 2013, hello 2014!
2014-01-03 17:28:58 -04:00
Alex Szpakowski
aa69a695d3
Canvases can now be used in SpriteBatches, ParticleSystems, and Meshes (resolves issue #782 ).
...
Canvases and Images are now subclasses of the new Texture class.
Added setTexture and getTexture methods for Meshes, ParticleSystems, and SpriteBatches (the old set/getImage methods are deprecated but not removed.)
Canvas texture coordinates are no longer flipped.
2014-01-03 17:07:12 -04:00
Alex Szpakowski
fb34f5bc9e
Auto-padded NPOT images' texture coordinates are now scaled at draw time via the texture matrix (fixes auto-padded images with Meshes.) Also fixed love.graphics.newQuad.
...
--HG--
branch : Mesh
2013-10-06 23:25:29 -03:00
Alex Szpakowski
1e696c4505
Added Mesh objects and love.graphics.newMesh. Mesh objects are similar to Geometry but they're drawables (the relationship between meshes and images is the opposite of geometry and images.)
...
Removed Geometry objects and re-added Quads.
example:
local vertices = {{0, 0, 0, 0}, {100, 0, 1, 0}, {100, 100, 1, 1}, {0, 100, 0, 1}}
mesh = love.graphics.newMesh(vertices, image, "fan")
..
love.graphics.draw(mesh, 0, 0)
--HG--
branch : Mesh
2013-09-28 18:26:47 -03:00
Alex Szpakowski
5de43a7207
The Vertex struct is now recognized as POD by C++, also fixed the name to be consistent with other love structs
2013-09-24 11:09:18 -03:00
Alex Szpakowski
2128ba321e
Fixed Geometry texture coordinates when using Geometry to draw auto-padded NPOT images (resolves issue #696 )
2013-08-01 17:14:20 -03:00
Alex Szpakowski
3fb78d5458
Added SpriteBatch:setBufferSize (issue #655 )
2013-06-29 00:04:56 -03:00
Alex Szpakowski
be33d17f89
Added SpriteBatch:getColor
2013-06-14 05:29:05 -03:00
Alex Szpakowski
0b71fa1483
Added SpriteBatch:getCount and SpriteBatch:getBufferSize, and removed SpriteBatch:isEmpty/isFull.
2013-05-22 18:44:40 -03:00
vrld
1e54049fbb
Fix SpriteBatch.
...
Broken in my last commit (6e0f6a4).
2013-04-21 20:01:03 +02:00
vrld
71317c4359
Add Geometries (replaces Quads).
...
A Geometry is a collection of vertices describing a non self-intersecting
(simple) polygon. In addition to screen coordinates, the vertices have
attributes for texture coordinates (s,t) and color (r,g,b,a).
It can be used as a quad, to display distorted images, or anything in between.
Added:
^^^^^^
-- geometry from table, where table has the format:
-- info = {
-- {x,y, s,t, [r = 255, g = 255, b = 255, a = 255]}
-- {x,y, s,t, [r = 255, g = 255, b = 255, a = 255]}
-- ...
-- }
geom = love.graphics.newGeometry(info)
-- convenience wrapper for quads (same as before)
geom = love.graphics.newQuad(x,y, w,h, sw,sh)
-- retrieve vertex i (1-indexed)
x,y,s,t,r,g,b,a = geom:getVertex(i)
-- set vertex i (1-indexed)
geom:setVertex(i, x,y, s,t, [r,g,b,a])
-- flip geometry
geom:flip(x, y)
Renamed:
^^^^^^^^
love.graphics.drawq() -> love.graphics.drawg()
Removed:
^^^^^^^^
quad:setViewport()
quad:getViewport()
2013-04-21 18:53:13 +02:00
Alex Szpakowski
d3cdb7d609
Added SpriteBatch:isEmpty() and SpriteBatch:isFull()
2013-03-01 17:32:38 -04:00
Alex Szpakowski
1d34dda48b
Removed SpriteBatch:remove(id) (reverted commit 2ca82dd)
...
The implementation had issues with sprite draw order when SpriteBatch:add used indices in the vertex buffer previously freed with SpriteBatch:remove
2013-02-24 09:47:03 -04:00
Alex Szpakowski
77ab120424
Fixed SpriteBatch file includes
2013-02-11 20:27:29 -04:00
Alex Szpakowski
ceb0ee6c7e
Added SpriteBatch:remove(id)
2013-02-11 18:27:57 -04:00
Alex Szpakowski
96161c66f6
Updated copyright text for the new year
2013-02-05 05:32:49 -04:00
Alexander Szpakowski
6560019829
opengl graphics module files now always include OpenGL.h rather than GLee.h
2013-01-01 17:54:14 -04:00
vrld
b2f1408b12
Fix issue #495 : Large spritebatches doesn't render properly
2012-11-23 10:23:44 +01:00
Bart van Strien
7793e7f02f
CRLF to LF
2012-07-04 14:40:24 +02:00
rude
81c38e22d0
Applied the new style guidelines.
...
Well, sort of. Lot's more to be done, but this is a start.
2012-06-28 23:52:33 +02:00
Bill Meltsner
be55579a22
Happy New Year, have an enormous diff
2012-01-09 02:41:11 -06:00
Bart van Strien
1509403ca7
Add SpriteBatch:getImage (issue #321 )
2012-01-08 13:46:01 +01:00
Bill Meltsner
969c53e592
make love build on OS X again - there's no need to include gl.h directly, GLee.h does that for us in a cross-platform way
2011-12-19 00:28:45 -06:00
Bart van Strien
7c8fff979a
Create love.window, abstract SDL out of love.graphics
2011-12-11 16:55:52 +01:00
Bart van Strien
0aae9684b3
Automated formatting fix
2011-11-16 11:32:41 +01:00
Bart van Strien
dc66ea20c1
Add SpriteBatch:set(q) and make add(q) return the index
2011-10-20 20:19:01 +02:00
Bart van Strien
b14ca78109
Add string mapping for spritebatch usage parameter (issue #264 )
2011-08-24 12:11:08 +02:00
rude
480f936815
Added 'VertexBuffer' abstraction. SpriteBatches are now always supported.
...
Also improved memory usage in SpriteBatch. (No need to retain full copy of
sprites in memory. Can read that data back later to save data from OpenGL
context destruction).
2011-08-12 11:35:14 +02:00
Bart van Strien
3c5c4ee604
Add SpriteBatch support to love.graphics.isSupported
2011-07-24 15:37:02 +02:00
rude
387a8ab2dc
Issue #262 : Add per-sprite colors.
2011-07-23 17:12:29 +02:00
vrld
d420d68048
Add shear transformation and transform object (issue #152 ).
...
Add origin parameters to love.graphics.print.
New shear parameters kx,ky for:
- love.graphics.draw,
- love.graphics.drawq,
- love.graphics.print,
- SpriteBatch:add,
- SpriteBatch:addq.
Transform objects apply to:
- love.graphics.draw,
- love.graphics.drawq,
- love.graphics.print.
2011-07-05 14:33:34 +02:00
José Romero
dc2d87a90f
Apply patch for issue #219
2011-04-27 16:35:14 +02:00
Bill Meltsner
fde708160e
bringing in the new year by changing every 2010 to 2011
2011-01-15 14:40:27 -06:00
rude
9c4926b7da
Fixed double-transform spritebatch bug.
2010-02-20 18:19:16 +01:00
rude
aa01c984b9
Updated all dates to 2010.
2010-01-31 16:54:47 +01:00
rude
d58182c4c2
SpriteBatch is now Volatile and can deal with display resolution changes.
2009-08-18 18:43:59 +02:00
rude
c52c218ba1
Renamed Frame to Quad; added drawq/addq; fixed some bugs.
2009-08-17 23:35:04 +02:00
rude
5c068db487
Added locking to SpriteBatch, and conf.lua.
2009-07-27 15:17:54 +02:00
rude
4f32377efa
Added working SpriteBatch.
2009-07-27 02:10:51 +02:00
rude
84bf839872
Removed classes which should be implemented in Lua (or need of re-implementation).
2009-07-26 23:08:40 +02:00
rude
dcb3dfd83d
Initial Mercurial commit.
2009-07-26 15:46:49 +02:00