Ogre Version: v1.13.3
Operating System: windows
Render System: dx9c
Depending on a texture size I want to read a particular mipmap to speed up my mouse test, and sometimes it crashes with some users, and I don't know why. I have a Access violation reading location 0x0000000000000038 when getting the buffer.
Is there something I could do to avoid this?
Code: Select all
Ogre::Box imageBox;
int x = tex->getWidth()-1;
int y = tex->getHeight()-1;
int mip = 0;
if ((x > 128 || y > 128) && tex->getNumMipmaps() > 2)
mip = 1;
if ((x>512 || y>512) && tex->getNumMipmaps() > 3)
mip = 2;
if ((x>1024 || y>1024) && tex->getNumMipmaps() > 4)
mip = 3;
Ogre::HardwarePixelBufferSharedPtr buf = tex->getBuffer(0, mip);
S.