- sub_image(level, 0, 0, z, w, h, 1, fmt, type, data);
+ sub_image(level, 0, 0, z, w, h, 1, data);
+}
+
+void Texture2DArray::layer_image(unsigned level, unsigned z, PixelComponents comp, DataType type, const void *data)
+{
+ if(comp!=get_components(format) || type!=get_component_type(format))
+ throw incompatible_data("Texture2DArray::layer_image");
+ layer_image(level, z, data);