mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Centralize NPOT support check for image, export it to isSupported
This commit is contained in:
@@ -278,7 +278,7 @@ namespace opengl
|
||||
|
||||
bool Image::loadVolatile()
|
||||
{
|
||||
if (GLEE_ARB_texture_non_power_of_two)
|
||||
if (hasNpot())
|
||||
return loadVolatileNPOT();
|
||||
else
|
||||
return loadVolatilePOT();
|
||||
@@ -387,6 +387,11 @@ namespace opengl
|
||||
glPopMatrix();
|
||||
}
|
||||
|
||||
bool Image::hasNpot()
|
||||
{
|
||||
return GLEE_ARB_texture_non_power_of_two;
|
||||
}
|
||||
|
||||
} // opengl
|
||||
} // graphics
|
||||
} // love
|
||||
|
||||
Reference in New Issue
Block a user