- DataType type = get_component_type(storage_fmt);
- glTexSubImage2D(face, level, x, y, wd, ht, comp, type, data);
+ GLenum type = get_gl_type(get_component_type(storage_fmt));
+ if(ARB_direct_state_access)
+ glTextureSubImage3D(id, level, x, y, get_face_index(face), wd, ht, 1, comp, type, data);
+ else
+ glTexSubImage2D(face, level, x, y, wd, ht, comp, type, data);