BindRestore _bind(this);
glTexStorage2D(target, levels, storage_fmt, size, size);
apply_swizzle();
- allocated |= (1<<levels)-1;
+ allocated |= (64<<levels)-1;
}
else
{
}
PixelComponents comp = get_components(storage_fmt);
- DataType type = get_component_type(storage_fmt);
+ GLenum type = get_gl_type(get_component_type(storage_fmt));
glTexImage2D(face, level, storage_fmt, s, s, 0, comp, type, data);
if(level==0)
allocate(level);
PixelComponents comp = get_components(storage_fmt);
- DataType type = get_component_type(storage_fmt);
+ GLenum type = get_gl_type(get_component_type(storage_fmt));
glTexSubImage2D(face, level, x, y, wd, ht, comp, type, data);
if(auto_gen_mipmap && level==0)