Merge minor into dynamiccore2

--HG--
branch : dynamiccore2
This commit is contained in:
Bart van Strien
2016-11-26 22:19:12 +01:00
61 changed files with 4909 additions and 1720 deletions
+16 -1
View File
@@ -34,6 +34,8 @@ namespace love
namespace graphics
{
const int MAX_COLOR_RENDER_TARGETS = 16;
/**
* Globally sets whether gamma correction is enabled. Ideally this should be set
* prior to using any Graphics module function.
@@ -59,6 +61,14 @@ void gammaCorrectColor(Colorf &c);
**/
void unGammaCorrectColor(Colorf &c);
class RenderOutsidePassException : public love::Exception
{
public:
RenderOutsidePassException()
: Exception("Cannot draw outside of a render pass!")
{}
};
class Graphics : public Module
{
public:
@@ -143,6 +153,8 @@ public:
FEATURE_MULTI_CANVAS_FORMATS,
FEATURE_CLAMP_ZERO,
FEATURE_LIGHTEN,
FEATURE_FULL_NPOT,
FEATURE_PIXEL_SHADER_HIGHP,
FEATURE_MAX_ENUM
};
@@ -159,6 +171,7 @@ public:
LIMIT_TEXTURE_SIZE,
LIMIT_MULTI_CANVAS,
LIMIT_CANVAS_MSAA,
LIMIT_ANISOTROPY,
LIMIT_MAX_ENUM
};
@@ -180,7 +193,7 @@ public:
struct Stats
{
int drawCalls;
int canvasSwitches;
int renderPasses;
int shaderSwitches;
int canvases;
int images;
@@ -259,6 +272,8 @@ public:
**/
virtual bool isActive() const = 0;
virtual bool isPassActive() const = 0;
static bool getConstant(const char *in, DrawMode &out);
static bool getConstant(DrawMode in, const char *&out);