- texture.storage(GL::RGBA, height, width, 0);
+ unsigned texw = height;
+ unsigned texh = width;
+ if(!GL::is_supported("ARB_texture_non_power_of_two"))
+ {
+ for(texw=1; texw<height; texw<<=1) ;
+ for(texh=1; texh<width; texh<<=1) ;
+ }
+ texture.storage(GL::RGBA, texw, texh, 0);
+ texture.image(0, GL::RGBA, GL::UNSIGNED_BYTE, 0);