Compare commits

...

4 Commits

Author SHA1 Message Date
Cédric Valmary c1f9f6061a Updated Occitan translation 2015-05-30 20:24:56 +00:00
Cédric Valmary fccac5a50c Added Occitan translation 2015-05-22 20:39:30 +00:00
Patrick Welche 1c18e00ea2 Remove vestiges of libdl / dlfcn.h as cogl uses gmodule.
https://bugzilla.gnome.org/show_bug.cgi?id=691944

Reviewed-by: Neil Roberts <neil@linux.intel.com>

(cherry picked from commit 397e673446)

Conflicts:
	cogl/Makefile.am
2013-01-22 17:43:11 +00:00
Neil Roberts c8081d7f28 bitmap: Don't try to token paste the typenames from stdint.h
Previously the functions for packing and unpacking pixels where
generated by token pasting together a function name along with its
type, like the following:

 _cogl_pack_ ## uint8_t

Then later in cogl-bitmap-conversion.c it would directly refer to the
function names without token pasting.

This wouldn't work however if the system headers define the stdint
types using #defines instead of typedefs because in that case the
function name generated using token pasting would get the expanded
type name but the reference that doesn't use token pasting wouldn't.

This patch adds an extra macro passed to the cogl-bitmap-packing.h
header which just has the type size. That way the function can be
defined like this instead:

 _cogl_pack_ ## 8

That should prevent it from hitting problems with #defined types.

https://bugzilla.gnome.org/show_bug.cgi?id=691945

Reviewed-by: Robert Bragg <robert@linux.intel.com>

(cherry picked from commit d6b5d7085b)
2013-01-21 15:07:05 +00:00
5 changed files with 461 additions and 90 deletions

View File

@ -504,9 +504,6 @@ include $(top_srcdir)/build/autotools/Makefile.am.enums
lib_LTLIBRARIES += libcogl.la
libcogl_la_LIBADD = -lm $(COGL_DEP_LIBS) $(COGL_EXTRA_LDFLAGS)
if SUPPORT_GLX
libcogl_la_LIBADD += -ldl
endif
# XXX: The aim is to eventually get rid of all private API exports
# for cogl-pango.
libcogl_la_LDFLAGS = \

View File

@ -32,6 +32,7 @@
#include <string.h>
#define component_type uint8_t
#define component_size 8
/* We want to specially optimise the packing when we are converting
to/from an 8-bit type so that it won't do anything. That way for
example if we are just doing a swizzle conversion then the inner
@ -42,14 +43,17 @@
#undef PACK_BYTE
#undef UNPACK_BYTE
#undef component_type
#undef component_size
#define component_type uint16_t
#define component_size 16
#define UNPACK_BYTE(b) (((b) * 65535 + 127) / 255)
#define PACK_BYTE(b) (((b) * 255 + 32767) / 65535)
#include "cogl-bitmap-packing.h"
#undef PACK_BYTE
#undef UNPACK_BYTE
#undef component_type
#undef component_size
/* (Un)Premultiplication */
@ -205,8 +209,8 @@ _cogl_premult_alpha_last_four_pixels_sse2 (uint8_t *p)
#endif /* COGL_USE_PREMULT_SSE2 */
static void
_cogl_bitmap_premult_unpacked_span_uint8_t (uint8_t *data,
int width)
_cogl_bitmap_premult_unpacked_span_8 (uint8_t *data,
int width)
{
#ifdef COGL_USE_PREMULT_SSE2
@ -231,8 +235,8 @@ _cogl_bitmap_premult_unpacked_span_uint8_t (uint8_t *data,
}
static void
_cogl_bitmap_unpremult_unpacked_span_uint8_t (uint8_t *data,
int width)
_cogl_bitmap_unpremult_unpacked_span_8 (uint8_t *data,
int width)
{
int x;
@ -247,8 +251,8 @@ _cogl_bitmap_unpremult_unpacked_span_uint8_t (uint8_t *data,
}
static void
_cogl_bitmap_unpremult_unpacked_span_uint16_t (uint16_t *data,
int width)
_cogl_bitmap_unpremult_unpacked_span_16 (uint16_t *data,
int width)
{
while (width-- > 0)
{
@ -266,8 +270,8 @@ _cogl_bitmap_unpremult_unpacked_span_uint16_t (uint16_t *data,
}
static void
_cogl_bitmap_premult_unpacked_span_uint16_t (uint16_t *data,
int width)
_cogl_bitmap_premult_unpacked_span_16 (uint16_t *data,
int width)
{
while (width-- > 0)
{
@ -430,9 +434,9 @@ _cogl_bitmap_convert_into_bitmap (CoglBitmap *src_bmp,
dst = dst_data + y * dst_rowstride;
if (use_16)
_cogl_unpack_uint16_t (src_format, src, tmp_row, width);
_cogl_unpack_16 (src_format, src, tmp_row, width);
else
_cogl_unpack_uint8_t (src_format, src, tmp_row, width);
_cogl_unpack_8 (src_format, src, tmp_row, width);
/* Handle premultiplication */
if (need_premult)
@ -440,23 +444,23 @@ _cogl_bitmap_convert_into_bitmap (CoglBitmap *src_bmp,
if (dst_format & COGL_PREMULT_BIT)
{
if (use_16)
_cogl_bitmap_premult_unpacked_span_uint16_t (tmp_row, width);
_cogl_bitmap_premult_unpacked_span_16 (tmp_row, width);
else
_cogl_bitmap_premult_unpacked_span_uint8_t (tmp_row, width);
_cogl_bitmap_premult_unpacked_span_8 (tmp_row, width);
}
else
{
if (use_16)
_cogl_bitmap_unpremult_unpacked_span_uint16_t (tmp_row, width);
_cogl_bitmap_unpremult_unpacked_span_16 (tmp_row, width);
else
_cogl_bitmap_unpremult_unpacked_span_uint8_t (tmp_row, width);
_cogl_bitmap_unpremult_unpacked_span_8 (tmp_row, width);
}
}
if (use_16)
_cogl_pack_uint16_t (dst_format, tmp_row, dst, width);
_cogl_pack_16 (dst_format, tmp_row, dst, width);
else
_cogl_pack_uint8_t (dst_format, tmp_row, dst, width);
_cogl_pack_8 (dst_format, tmp_row, dst, width);
}
_cogl_bitmap_unmap (src_bmp);
@ -527,9 +531,9 @@ _cogl_bitmap_unpremult (CoglBitmap *bmp)
if (tmp_row)
{
_cogl_unpack_uint16_t (format, p, tmp_row, width);
_cogl_bitmap_unpremult_unpacked_span_uint16_t (tmp_row, width);
_cogl_pack_uint16_t (format, tmp_row, p, width);
_cogl_unpack_16 (format, p, tmp_row, width);
_cogl_bitmap_unpremult_unpacked_span_16 (tmp_row, width);
_cogl_pack_16 (format, tmp_row, p, width);
}
else
{
@ -545,7 +549,7 @@ _cogl_bitmap_unpremult (CoglBitmap *bmp)
}
}
else
_cogl_bitmap_unpremult_unpacked_span_uint8_t (p, width);
_cogl_bitmap_unpremult_unpacked_span_8 (p, width);
}
}
@ -592,9 +596,9 @@ _cogl_bitmap_premult (CoglBitmap *bmp)
if (tmp_row)
{
_cogl_unpack_uint16_t (format, p, tmp_row, width);
_cogl_bitmap_premult_unpacked_span_uint16_t (tmp_row, width);
_cogl_pack_uint16_t (format, tmp_row, p, width);
_cogl_unpack_16 (format, p, tmp_row, width);
_cogl_bitmap_premult_unpacked_span_16 (tmp_row, width);
_cogl_pack_16 (format, tmp_row, p, width);
}
else
{
@ -607,7 +611,7 @@ _cogl_bitmap_premult (CoglBitmap *bmp)
}
}
else
_cogl_bitmap_premult_unpacked_span_uint8_t (p, width);
_cogl_bitmap_premult_unpacked_span_8 (p, width);
}
}

View File

@ -42,7 +42,7 @@
511) / 1023)
inline static void
G_PASTE (_cogl_unpack_a_8_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_a_8_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -58,7 +58,7 @@ G_PASTE (_cogl_unpack_a_8_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_g_8_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_g_8_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -79,7 +79,7 @@ G_PASTE (_cogl_unpack_g_8_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgb_888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgb_888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -95,7 +95,7 @@ G_PASTE (_cogl_unpack_rgb_888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_bgr_888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_bgr_888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -111,7 +111,7 @@ G_PASTE (_cogl_unpack_bgr_888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_bgra_8888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_bgra_8888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -127,7 +127,7 @@ G_PASTE (_cogl_unpack_bgra_8888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_argb_8888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_argb_8888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -143,7 +143,7 @@ G_PASTE (_cogl_unpack_argb_8888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_abgr_8888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_abgr_8888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -159,7 +159,7 @@ G_PASTE (_cogl_unpack_abgr_8888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgba_8888_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgba_8888_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -175,7 +175,7 @@ G_PASTE (_cogl_unpack_rgba_8888_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgb_565_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgb_565_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -193,7 +193,7 @@ G_PASTE (_cogl_unpack_rgb_565_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgba_4444_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgba_4444_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -211,7 +211,7 @@ G_PASTE (_cogl_unpack_rgba_4444_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgba_5551_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgba_5551_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -229,7 +229,7 @@ G_PASTE (_cogl_unpack_rgba_5551_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_rgba_1010102_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_rgba_1010102_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -247,7 +247,7 @@ G_PASTE (_cogl_unpack_rgba_1010102_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_bgra_1010102_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_bgra_1010102_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -265,7 +265,7 @@ G_PASTE (_cogl_unpack_bgra_1010102_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_argb_2101010_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_argb_2101010_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -283,7 +283,7 @@ G_PASTE (_cogl_unpack_argb_2101010_, component_type) (const uint8_t *src,
}
inline static void
G_PASTE (_cogl_unpack_abgr_2101010_, component_type) (const uint8_t *src,
G_PASTE (_cogl_unpack_abgr_2101010_, component_size) (const uint8_t *src,
component_type *dst,
int width)
{
@ -308,7 +308,7 @@ G_PASTE (_cogl_unpack_abgr_2101010_, component_type) (const uint8_t *src,
#undef UNPACK_10
inline static void
G_PASTE (_cogl_unpack_, component_type) (CoglPixelFormat format,
G_PASTE (_cogl_unpack_, component_size) (CoglPixelFormat format,
const uint8_t *src,
component_type *dst,
int width)
@ -316,59 +316,59 @@ G_PASTE (_cogl_unpack_, component_type) (CoglPixelFormat format,
switch (format)
{
case COGL_PIXEL_FORMAT_A_8:
G_PASTE (_cogl_unpack_a_8_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_a_8_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_G_8:
G_PASTE (_cogl_unpack_g_8_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_g_8_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGB_888:
G_PASTE (_cogl_unpack_rgb_888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgb_888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGR_888:
G_PASTE (_cogl_unpack_bgr_888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_bgr_888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_8888:
case COGL_PIXEL_FORMAT_RGBA_8888_PRE:
G_PASTE (_cogl_unpack_rgba_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgba_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGRA_8888:
case COGL_PIXEL_FORMAT_BGRA_8888_PRE:
G_PASTE (_cogl_unpack_bgra_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_bgra_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ARGB_8888:
case COGL_PIXEL_FORMAT_ARGB_8888_PRE:
G_PASTE (_cogl_unpack_argb_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_argb_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ABGR_8888:
case COGL_PIXEL_FORMAT_ABGR_8888_PRE:
G_PASTE (_cogl_unpack_abgr_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_abgr_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGB_565:
G_PASTE (_cogl_unpack_rgb_565_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgb_565_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_4444:
case COGL_PIXEL_FORMAT_RGBA_4444_PRE:
G_PASTE (_cogl_unpack_rgba_4444_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgba_4444_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_5551:
case COGL_PIXEL_FORMAT_RGBA_5551_PRE:
G_PASTE (_cogl_unpack_rgba_5551_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgba_5551_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_1010102:
case COGL_PIXEL_FORMAT_RGBA_1010102_PRE:
G_PASTE (_cogl_unpack_rgba_1010102_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_rgba_1010102_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGRA_1010102:
case COGL_PIXEL_FORMAT_BGRA_1010102_PRE:
G_PASTE (_cogl_unpack_bgra_1010102_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_bgra_1010102_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ARGB_2101010:
case COGL_PIXEL_FORMAT_ARGB_2101010_PRE:
G_PASTE (_cogl_unpack_argb_2101010_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_argb_2101010_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ABGR_2101010:
case COGL_PIXEL_FORMAT_ABGR_2101010_PRE:
G_PASTE (_cogl_unpack_abgr_2101010_, component_type) (src, dst, width);
G_PASTE (_cogl_unpack_abgr_2101010_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ANY:
case COGL_PIXEL_FORMAT_YUV:
@ -391,7 +391,7 @@ G_PASTE (_cogl_unpack_, component_type) (CoglPixelFormat format,
#define PACK_10(b) PACK_SIZE (b, 1023)
inline static void
G_PASTE (_cogl_pack_a_8_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_a_8_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -404,7 +404,7 @@ G_PASTE (_cogl_pack_a_8_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_g_8_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_g_8_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -422,7 +422,7 @@ G_PASTE (_cogl_pack_g_8_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgb_888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgb_888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -437,7 +437,7 @@ G_PASTE (_cogl_pack_rgb_888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_bgr_888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_bgr_888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -452,7 +452,7 @@ G_PASTE (_cogl_pack_bgr_888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_bgra_8888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_bgra_8888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -468,7 +468,7 @@ G_PASTE (_cogl_pack_bgra_8888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_argb_8888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_argb_8888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -484,7 +484,7 @@ G_PASTE (_cogl_pack_argb_8888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_abgr_8888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_abgr_8888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -500,7 +500,7 @@ G_PASTE (_cogl_pack_abgr_8888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgba_8888_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgba_8888_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -516,7 +516,7 @@ G_PASTE (_cogl_pack_rgba_8888_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgb_565_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgb_565_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -533,7 +533,7 @@ G_PASTE (_cogl_pack_rgb_565_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgba_4444_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgba_4444_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -551,7 +551,7 @@ G_PASTE (_cogl_pack_rgba_4444_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgba_5551_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgba_5551_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -569,7 +569,7 @@ G_PASTE (_cogl_pack_rgba_5551_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_rgba_1010102_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_rgba_1010102_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -587,7 +587,7 @@ G_PASTE (_cogl_pack_rgba_1010102_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_bgra_1010102_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_bgra_1010102_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -605,7 +605,7 @@ G_PASTE (_cogl_pack_bgra_1010102_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_argb_2101010_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_argb_2101010_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -623,7 +623,7 @@ G_PASTE (_cogl_pack_argb_2101010_, component_type) (const component_type *src,
}
inline static void
G_PASTE (_cogl_pack_abgr_2101010_, component_type) (const component_type *src,
G_PASTE (_cogl_pack_abgr_2101010_, component_size) (const component_type *src,
uint8_t *dst,
int width)
{
@ -649,7 +649,7 @@ G_PASTE (_cogl_pack_abgr_2101010_, component_type) (const component_type *src,
#undef PACK_10
inline static void
G_PASTE (_cogl_pack_, component_type) (CoglPixelFormat format,
G_PASTE (_cogl_pack_, component_size) (CoglPixelFormat format,
const component_type *src,
uint8_t *dst,
int width)
@ -657,59 +657,59 @@ G_PASTE (_cogl_pack_, component_type) (CoglPixelFormat format,
switch (format)
{
case COGL_PIXEL_FORMAT_A_8:
G_PASTE (_cogl_pack_a_8_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_a_8_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_G_8:
G_PASTE (_cogl_pack_g_8_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_g_8_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGB_888:
G_PASTE (_cogl_pack_rgb_888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgb_888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGR_888:
G_PASTE (_cogl_pack_bgr_888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_bgr_888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_8888:
case COGL_PIXEL_FORMAT_RGBA_8888_PRE:
G_PASTE (_cogl_pack_rgba_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgba_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGRA_8888:
case COGL_PIXEL_FORMAT_BGRA_8888_PRE:
G_PASTE (_cogl_pack_bgra_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_bgra_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ARGB_8888:
case COGL_PIXEL_FORMAT_ARGB_8888_PRE:
G_PASTE (_cogl_pack_argb_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_argb_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ABGR_8888:
case COGL_PIXEL_FORMAT_ABGR_8888_PRE:
G_PASTE (_cogl_pack_abgr_8888_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_abgr_8888_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGB_565:
G_PASTE (_cogl_pack_rgb_565_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgb_565_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_4444:
case COGL_PIXEL_FORMAT_RGBA_4444_PRE:
G_PASTE (_cogl_pack_rgba_4444_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgba_4444_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_5551:
case COGL_PIXEL_FORMAT_RGBA_5551_PRE:
G_PASTE (_cogl_pack_rgba_5551_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgba_5551_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_RGBA_1010102:
case COGL_PIXEL_FORMAT_RGBA_1010102_PRE:
G_PASTE (_cogl_pack_rgba_1010102_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_rgba_1010102_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_BGRA_1010102:
case COGL_PIXEL_FORMAT_BGRA_1010102_PRE:
G_PASTE (_cogl_pack_bgra_1010102_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_bgra_1010102_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ARGB_2101010:
case COGL_PIXEL_FORMAT_ARGB_2101010_PRE:
G_PASTE (_cogl_pack_argb_2101010_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_argb_2101010_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ABGR_2101010:
case COGL_PIXEL_FORMAT_ABGR_2101010_PRE:
G_PASTE (_cogl_pack_abgr_2101010_, component_type) (src, dst, width);
G_PASTE (_cogl_pack_abgr_2101010_, component_size) (src, dst, width);
break;
case COGL_PIXEL_FORMAT_ANY:
case COGL_PIXEL_FORMAT_YUV:

View File

@ -56,7 +56,6 @@
#include <glib/gi18n-lib.h>
#include <dlfcn.h>
#include <GL/glx.h>
#include <X11/Xlib.h>

371
po/oc.po Normal file
View File

@ -0,0 +1,371 @@
# Occitan translation for cogl.
# Copyright (C) 2011-12 Listed translators
# This file is distributed under the same license as the cogl package.
# Cédric Valmary (Tot en òc) <cvalmary@yahoo.fr>, 2015.
msgid ""
msgstr ""
"Project-Id-Version: cogl master\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=cogl&ke"
"ywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2015-05-30 15:15+0000\n"
"PO-Revision-Date: 2015-05-30 22:22+0200\n"
"Last-Translator: Cédric Valmary (Tot en òc) <cvalmary@yahoo.fr>\n"
"Language-Team: Tot en òc (totenoc.eu)\n"
"Language: oc\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
"X-Generator: Virtaal 0.7.1\n"
"X-Project-Style: gnome\n"
#: ../cogl/cogl-debug.c:180
msgid "Supported debug values:"
msgstr "Valors de desbugatge presas en carga :"
#: ../cogl/cogl-debug.c:185
msgid "Special debug values:"
msgstr "Valors de desbugatge especialas :"
#: ../cogl/cogl-debug.c:187 ../cogl/cogl-debug.c:189
msgid "Enables all non-behavioural debug options"
msgstr "Activa totas las opcions de desbugatge non associadas al comportament"
#: ../cogl/cogl-debug.c:196
msgid "Additional environment variables:"
msgstr "Variablas d'environament suplementàrias :"
#: ../cogl/cogl-debug.c:197
msgid "Comma-separated list of GL extensions to pretend are disabled"
msgstr ""
"Lista d'extensions GL separadas per de punts-virgulas per las qualas cal far "
"coma se èran desactivadas"
#: ../cogl/cogl-debug.c:199
msgid "Override the GL version that Cogl will assume the driver supports"
msgstr ""
"Passar otra la version de GL que Cogl supausarà que lo pilòt pren en carga"
#: ../cogl/cogl-debug-options.h:32 ../cogl/cogl-debug-options.h:37
#: ../cogl/cogl-debug-options.h:42 ../cogl/cogl-debug-options.h:47
#: ../cogl/cogl-debug-options.h:52 ../cogl/cogl-debug-options.h:57
#: ../cogl/cogl-debug-options.h:62 ../cogl/cogl-debug-options.h:68
#: ../cogl/cogl-debug-options.h:73 ../cogl/cogl-debug-options.h:78
#: ../cogl/cogl-debug-options.h:165 ../cogl/cogl-debug-options.h:170
#: ../cogl/cogl-debug-options.h:175 ../cogl/cogl-debug-options.h:191
#: ../cogl/cogl-debug-options.h:196
msgid "Cogl Tracing"
msgstr "Traçage de Cogl"
#: ../cogl/cogl-debug-options.h:34
msgid "CoglObject references"
msgstr "Referéncias CoglObject"
#: ../cogl/cogl-debug-options.h:35
msgid "Debug ref counting issues for CoglObjects"
msgstr "Desbòga los problèmas de comptage de referéncia pels CoglObjects"
#: ../cogl/cogl-debug-options.h:39
msgid "Trace Texture Slicing"
msgstr "Traçar lo decopatge de la textura"
#: ../cogl/cogl-debug-options.h:40
msgid "debug the creation of texture slices"
msgstr "Desbòga la creacion de las lichas de textura"
#: ../cogl/cogl-debug-options.h:44
msgid "Trace Atlas Textures"
msgstr "Traçar las texturas atlàs"
#: ../cogl/cogl-debug-options.h:45
msgid "Debug texture atlas management"
msgstr "Desbòga la gestion de las texturas atlàs"
#: ../cogl/cogl-debug-options.h:49
msgid "Trace Blend Strings"
msgstr "Traçar las cadenas de Blend"
#: ../cogl/cogl-debug-options.h:50
msgid "Debug CoglBlendString parsing"
msgstr "Desbòga l'analisi dels CoglBlendString"
#: ../cogl/cogl-debug-options.h:54
msgid "Trace Journal"
msgstr "Traçar lo jornal"
#: ../cogl/cogl-debug-options.h:55
msgid "View all the geometry passing through the journal"
msgstr "Aficha tota la geometria transmesa al jornal"
#: ../cogl/cogl-debug-options.h:59
msgid "Trace Batching"
msgstr "Traçar lo tractament per lòt"
#: ../cogl/cogl-debug-options.h:60
msgid "Show how geometry is being batched in the journal"
msgstr "Aficha cossí la geometria es tractada per lòt dins lo jornal"
#: ../cogl/cogl-debug-options.h:64
msgid "Trace matrices"
msgstr "Traçar las matrises"
#: ../cogl/cogl-debug-options.h:65
msgid "Trace all matrix manipulation"
msgstr "Traça totas las manipulacions de matritz"
#: ../cogl/cogl-debug-options.h:70
msgid "Trace Misc Drawing"
msgstr "Traçar los dessenhs divèrses"
#: ../cogl/cogl-debug-options.h:71
msgid "Trace some misc drawing operations"
msgstr "Traça d'operacions de dessenh divèrs"
#: ../cogl/cogl-debug-options.h:75
msgid "Trace Pango Renderer"
msgstr "Traçar lo rendut Pango"
#: ../cogl/cogl-debug-options.h:76
msgid "Trace the Cogl Pango renderer"
msgstr "Traça lo rendut Pango de Cogl"
#: ../cogl/cogl-debug-options.h:80
msgid "Trace CoglTexturePixmap backend"
msgstr "Traçar lo motor CoglTexturaPixmap"
#: ../cogl/cogl-debug-options.h:81
msgid "Trace the Cogl texture pixmap backend"
msgstr "Traça lo motor pixmap de las texturas Cogl"
#: ../cogl/cogl-debug-options.h:83 ../cogl/cogl-debug-options.h:88
msgid "Visualize"
msgstr "Visualizar"
#: ../cogl/cogl-debug-options.h:85
msgid "Outline rectangles"
msgstr "Enrodar los rectangles"
#: ../cogl/cogl-debug-options.h:86
msgid "Add wire outlines for all rectangular geometry"
msgstr "Apond de contorns filars a tota geometria rectangulara"
#: ../cogl/cogl-debug-options.h:90
msgid "Show wireframes"
msgstr "Afichar las estructuras en mòde filar"
#: ../cogl/cogl-debug-options.h:91
msgid "Add wire outlines for all geometry"
msgstr "Apond de contorns filars a tota geometria"
#: ../cogl/cogl-debug-options.h:93 ../cogl/cogl-debug-options.h:98
#: ../cogl/cogl-debug-options.h:103 ../cogl/cogl-debug-options.h:108
#: ../cogl/cogl-debug-options.h:118 ../cogl/cogl-debug-options.h:123
#: ../cogl/cogl-debug-options.h:129 ../cogl/cogl-debug-options.h:134
#: ../cogl/cogl-debug-options.h:139 ../cogl/cogl-debug-options.h:144
#: ../cogl/cogl-debug-options.h:149 ../cogl/cogl-debug-options.h:154
#: ../cogl/cogl-debug-options.h:160 ../cogl/cogl-debug-options.h:180
#: ../cogl/cogl-debug-options.h:185
msgid "Root Cause"
msgstr "Causa principala"
#: ../cogl/cogl-debug-options.h:95
msgid "Disable Journal batching"
msgstr "Desactivar lo tractament per lòt del jornal"
#: ../cogl/cogl-debug-options.h:96
msgid "Disable batching of geometry in the Cogl Journal."
msgstr "Desactiva lo tractament per lòt de la geometria dins lo jornal Cogl."
#: ../cogl/cogl-debug-options.h:100
msgid "Disable GL Vertex Buffers"
msgstr "Desactivar los buffers dels soms GL"
#: ../cogl/cogl-debug-options.h:101
msgid "Disable use of OpenGL vertex buffer objects"
msgstr "Desactiva l'utilizacion dels objèctes del buffer dels soms OpenGL"
#: ../cogl/cogl-debug-options.h:105
msgid "Disable GL Pixel Buffers"
msgstr "Desactivar los buffers dels pixèls GL"
#: ../cogl/cogl-debug-options.h:106
msgid "Disable use of OpenGL pixel buffer objects"
msgstr "Desactiva l'utilizacion dels objèctes del buffer dels pixèls OpenGL"
#: ../cogl/cogl-debug-options.h:110
msgid "Disable software rect transform"
msgstr "Desactivar la transformacion rectangulara del logicial"
#: ../cogl/cogl-debug-options.h:111
msgid "Use the GPU to transform rectangular geometry"
msgstr "Utiliza lo processor grafic per transformer la geometria rectangulara"
#: ../cogl/cogl-debug-options.h:113
msgid "Cogl Specialist"
msgstr "Especialista Cogl"
#: ../cogl/cogl-debug-options.h:115
msgid "Dump atlas images"
msgstr "Voidar los imatges de l'atlàs"
#: ../cogl/cogl-debug-options.h:116
msgid "Dump texture atlas changes to an image file"
msgstr ""
"Voida las modificacions de l'atlàs de las texturas dins un fichièr d'imatge"
#: ../cogl/cogl-debug-options.h:120
msgid "Disable texture atlasing"
msgstr "Desactivar l'enregistrament dins l'atlàs de las texturas"
#: ../cogl/cogl-debug-options.h:121
msgid "Disable use of texture atlasing"
msgstr ""
"Desactiva l'utilizacion de l'enregistrament dins l'atlàs de las texturas"
#: ../cogl/cogl-debug-options.h:125
msgid "Disable sharing the texture atlas between text and images"
msgstr ""
"Desactivar lo partiment de l'atlàs de las texturas entre lo tèxte e los "
"imatges"
#: ../cogl/cogl-debug-options.h:126
msgid ""
"When this is set the glyph cache will always use a separate texture for its "
"atlas. Otherwise it will try to share the atlas with images."
msgstr ""
"Quand aquò es activat, l'escondedor dels glifes ensajarà totjorn d'utilizar "
"una textura separada per son atlàs. Autrament, ensajarà de partejar l'atlàs "
"amb los imatges."
#: ../cogl/cogl-debug-options.h:131
msgid "Disable texturing"
msgstr "Desactivar l'utilizacion de textura"
#: ../cogl/cogl-debug-options.h:132
msgid "Disable texturing any primitives"
msgstr "Desactiva l'utilizacion de textura per tota primitiva"
#: ../cogl/cogl-debug-options.h:136
msgid "Disable arbfp"
msgstr "Desactivar arbfp"
#: ../cogl/cogl-debug-options.h:137
msgid "Disable use of ARB fragment programs"
msgstr "Desactiva l'utilizacion de programas fragmentats ARB"
#: ../cogl/cogl-debug-options.h:141
msgid "Disable fixed"
msgstr "Desactivar fixats"
#: ../cogl/cogl-debug-options.h:142
msgid "Disable use of the fixed function pipeline backend"
msgstr "Desactiva l'utilizacion del motor de pipeline de la foncion fixada"
#: ../cogl/cogl-debug-options.h:146
msgid "Disable GLSL"
msgstr "Desactivar GLSL"
#: ../cogl/cogl-debug-options.h:147
msgid "Disable use of GLSL"
msgstr "Desactiva l'utilizacion de GLSL"
#: ../cogl/cogl-debug-options.h:151
msgid "Disable blending"
msgstr "Desactivar las mesclas"
#: ../cogl/cogl-debug-options.h:152
msgid "Disable use of blending"
msgstr "Desactiva l'utilizacion de las mesclas"
#: ../cogl/cogl-debug-options.h:156
msgid "Disable non-power-of-two textures"
msgstr "Desactivar las texturas non-poténcias de dos"
#: ../cogl/cogl-debug-options.h:157
msgid ""
"Makes Cogl think that the GL driver doesn't support NPOT textures so that it "
"will create sliced textures or textures with waste instead."
msgstr ""
"Fa pensar a Cogl que lo pilòt GL supòrta pas las texturas NPOT per que crèe "
"de texturas tranchadas o de texturas amb los degalhs."
#: ../cogl/cogl-debug-options.h:162
msgid "Disable software clipping"
msgstr "Desactivar la copadura logicial"
#: ../cogl/cogl-debug-options.h:163
msgid "Disables Cogl's attempts to clip some rectangles in software."
msgstr ""
"Empacha tota temptativa de Cogl de talhar certans rectangles dins los "
"logicials."
#: ../cogl/cogl-debug-options.h:167
msgid "Show source"
msgstr "Afichar la font"
#: ../cogl/cogl-debug-options.h:168
msgid "Show generated ARBfp/GLSL source code"
msgstr "Aficha lo còde font ARBfp/GLSL produsit"
#: ../cogl/cogl-debug-options.h:172
msgid "Trace some OpenGL"
msgstr "Traçar qualques OpenGL"
#: ../cogl/cogl-debug-options.h:173
msgid "Traces some select OpenGL calls"
msgstr "Traça qualques apèls OpenGL seleccionats"
#: ../cogl/cogl-debug-options.h:177
msgid "Trace offscreen support"
msgstr "Traçar la presa en carga fòra ecran"
#: ../cogl/cogl-debug-options.h:178
msgid "Debug offscreen support"
msgstr "Desbòga la presa en carga fòra ecran"
#: ../cogl/cogl-debug-options.h:182
msgid "Disable program caches"
msgstr "Desactivar los escondedors de programa"
#: ../cogl/cogl-debug-options.h:183
msgid "Disable fallback caches for arbfp and glsl programs"
msgstr "Desactiva los escondedors d'urgéncia pels programas arbfp e glsl"
#: ../cogl/cogl-debug-options.h:187
msgid "Disable read pixel optimization"
msgstr "Desactivar l'optimizacion de lectura de pixèl"
#: ../cogl/cogl-debug-options.h:188
msgid ""
"Disable optimization for reading 1px for simple scenes of opaque rectangles"
msgstr ""
"Desactiva l'optimizacion de la lectura d'un pixèl de scènas simplas de "
"rectangles opacs"
#: ../cogl/cogl-debug-options.h:193
msgid "Trace clipping"
msgstr "Traçar la copadura"
#: ../cogl/cogl-debug-options.h:194
msgid "Logs information about how Cogl is implementing clipping"
msgstr "Enregistra las informacions sul biais que Cogl met en òbra la copadura"
#: ../cogl/cogl-debug-options.h:198
msgid "Trace performance concerns"
msgstr "Traçar los problèmas de performàncias"
#: ../cogl/cogl-debug-options.h:199
msgid "Tries to highlight sub-optimal Cogl usage."
msgstr "Ensaja de metre en evidéncia l'utilizacion sosoptimala de Cogl."
#~ msgid "Cogl debugging flags to set"
#~ msgstr "Drapeaux de débogage Cogl à définir"
#~ msgid "Cogl debugging flags to unset"
#~ msgstr "Drapeaux de débogage Cogl à annuler"
#~ msgid "Cogl Options"
#~ msgstr "Options Cogl"
#~ msgid "Show Cogl options"
#~ msgstr "Affiche les options Cogl"