Patch from Joseph Steel, added missing check for the mipmap usage.

This commit is contained in:
Robert Osfield 2003-01-15 11:33:33 +00:00
parent d542a2165d
commit 5960307703

View File

@ -127,7 +127,12 @@ Texture2D* txp::GetLocalTexture(trpgrImageHelper& image_helper, trpgLocalMateria
Image* image = new Image;
char* data = 0L;
int32 num_mipmaps = tex->CalcNumMipmaps();
bool bMipmap;
tex->GetIsMipmap(bMipmap);
int32 num_mipmaps = bMipmap ? tex->CalcNumMipmaps() : 1; // this is currently line 130
// osg::Image do their own mipmaps
if(num_mipmaps <= 1)
{