//---------------------------------------------------------- bool ofImage::loadImage(string fileName){ bool bLoadedOk = false; bLoadedOk = loadImageIntoPixels(fileName, myPixels); if (bLoadedOk && myPixels.isAllocated() && bUseTexture){ tex.allocate(myPixels.getWidth(), myPixels.getHeight(), myPixels.getGlDataType()); } update(); return bLoadedOk; }
//---------------------------------------------------------- bool ofImage::loadImage(string fileName){ bool bLoadedOk = false; bLoadedOk = loadImageIntoPixels(fileName, myPixels); if (bLoadedOk == true){ if (myPixels.bAllocated == true && bUseTexture == true){ tex.allocate(myPixels.width, myPixels.height, myPixels.glDataType); } update(); } return bLoadedOk; }