mirror of
https://github.com/brl/mutter.git
synced 2024-11-28 02:50:41 -05:00
6f480c7530
This removes the gl centric _cogl_texture_prepare_for_upload api from cogl-texture.c and instead adds a _cogl_bitmap_convert_for_upload() api which everything now uses instead. GL specific code that needed the gl internal/format/type enums returned by _cogl_texture_prepare_for_upload now use ->pixel_format_to_gl directly. Since there was a special case optimization in cogl_texture_new_from_file that aimed to avoid copying the temporary bitmap that's created for the given file and allow conversions to happen in-place the new _cogl_bitmap_convert_for_upload() api supports converting in place depending on a 'can_convert_in_place' argument. This ability to convert bitmaps in-place has been integrated across the different components as appropriate. In updating cogl-texture-2d-sliced.c this was able to remove a number of other GL specific parts to how spans are setup. Reviewed-by: Neil Roberts <neil@linux.intel.com> (cherry picked from commit e190dd23c655da34b9c5c263a9f6006dcc0413b0) Conflicts: cogl/cogl-auto-texture.c cogl/cogl.symbols |
||
---|---|---|
.. | ||
cogl-attribute-nop-private.h | ||
cogl-attribute-nop.c | ||
cogl-clip-stack-nop-private.h | ||
cogl-clip-stack-nop.c | ||
cogl-driver-nop.c | ||
cogl-framebuffer-nop-private.h | ||
cogl-framebuffer-nop.c | ||
cogl-texture-2d-nop-private.h | ||
cogl-texture-2d-nop.c |