mirror of
https://github.com/love2d/love.git
synced 2026-08-15 15:51:12 +02:00
Added Transform objects to love.math (resolves issue #1228).
- Added love.math.newTransform. - Added love.graphics.applyTransform and love.graphics.replaceTransform. - love.graphics.draw/print/printf, Text:add/addf, and SpriteBatch:add can accept a Transform argument. - love.graphics.push can accept an optional Transform as a second argument, which will apply the Transform after pushing the matrix stack, - Shader:send can accept Transform objects when sending to a mat4 uniform variable. --HG-- branch : minor
This commit is contained in:
@@ -45,6 +45,7 @@ namespace math
|
||||
{
|
||||
|
||||
class BezierCurve;
|
||||
class Transform;
|
||||
|
||||
struct Triangle
|
||||
{
|
||||
@@ -176,6 +177,9 @@ public:
|
||||
**/
|
||||
BezierCurve *newBezierCurve(const std::vector<Vector> &points);
|
||||
|
||||
Transform *newTransform();
|
||||
Transform *newTransform(float x, float y, float a, float sx, float sy, float ox, float oy, float kx, float ky);
|
||||
|
||||
// Implements Module.
|
||||
virtual ModuleType getModuleType() const
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user