Made the TurboJPEG code for decoding and encoding images disable-able.

--HG--
branch : minor
This commit is contained in:
Alex Szpakowski
2015-02-18 00:18:47 -04:00
parent 5652475dd2
commit d0300a4fa7
3 changed files with 16 additions and 1 deletions
+4
View File
@@ -43,7 +43,11 @@ namespace magpie
Image::Image()
{
formatHandlers.push_back(new PNGHandler);
#ifndef LOVE_NO_TURBOJPEG
formatHandlers.push_back(new JPEGHandler);
#endif
formatHandlers.push_back(new STBHandler);
#ifdef LOVE_SUPPORT_IMAGEIO
+6 -1
View File
@@ -18,8 +18,11 @@
* 3. This notice may not be removed or altered from any source distribution.
**/
// LOVE
#include "JPEGHandler.h"
#ifndef LOVE_NO_TURBOJPEG
// LOVE
#include "common/Exception.h"
#include "common/math.h"
@@ -161,3 +164,5 @@ FormatHandler::EncodedImage JPEGHandler::encode(const DecodedImage &img, ImageDa
} // magpie
} // image
} // love
#endif // LOVE_NO_TURBOJPEG
+6
View File
@@ -21,6 +21,10 @@
#ifndef LOVE_IMAGE_MAGPIE_JPEG_HANDLER_H
#define LOVE_IMAGE_MAGPIE_JPEG_HANDLER_H
#include "common/config.h"
#ifndef LOVE_NO_TURBOJPEG
// LOVE
#include "FormatHandler.h"
#include "thread/threads.h"
@@ -72,4 +76,6 @@ private:
} // image
} // love
#endif // LOVE_NO_TURBOJPEG
#endif // LOVE_IMAGE_MAGPIE_JPEG_HANDLER_H