@@ -150,8 +150,11 @@ namespace oxygine
if (!t->getHandle())
return false;
- w = nextPOT(w);
- h = nextPOT(h);
+ if (!HAVE_NPOT_RT())
+ {
+ w = nextPOT(w);
+ h = nextPOT(h);
+ }
if (t->getFormat() == tf &&
t->getWidth() >= w && t->getHeight() >= h &&
@@ -88,7 +88,7 @@ namespace oxygine
{
if (*mode == 's')
++mode;
-
+
LOGD("oxFileOpen %s", filename);
oxHandle* h = oxFileOpen_(filename, mode);
if (h)
@@ -102,7 +102,7 @@ namespace oxygine
handle open(const char* file_, const char* mode, error_policy ep)
#ifdef OX_DEBUG
if (!strstr(mode, "b"))
log::warning("file::open for file '%s' should be called with 'b' (means binary) flag", file_);
@@ -119,8 +119,11 @@ namespace oxygine
if (rt)
}
glPixel p = SurfaceFormat2GL(tf);
@@ -526,14 +526,14 @@ namespace oxygine
bool beginRendering(window w)
#ifdef OXYGINE_SDL
SDL_Window* wnd = w;
if (!wnd)
if (!focus)
wnd = _window;
SDL_GL_MakeCurrent(wnd, _context);
@@ -23,6 +23,13 @@
// Introduces some CPU overhead.
//#define OXYGINE_NO_SUBPIXEL_RENDERING 1
+#ifdef __ANDROID__
+#define HAVE_NPOT_RT() (false)
+#else
+#define HAVE_NPOT_RT() (true)
+#endif
//#define OXYGINE_NO_YEILD 1
// Bypass SDL file functions and use plain fopen, fread etc.