|
|
|
|
@@ -20,6 +20,8 @@
|
|
|
|
|
#include "config.h"
|
|
|
|
|
|
|
|
|
|
#include "gdkmemoryformatprivate.h"
|
|
|
|
|
|
|
|
|
|
#include "gdkdmabuffourccprivate.h"
|
|
|
|
|
#include "gdkglcontextprivate.h"
|
|
|
|
|
|
|
|
|
|
#include "gsk/gl/fp16private.h"
|
|
|
|
|
@@ -344,6 +346,9 @@ struct _GdkMemoryFormatDescription
|
|
|
|
|
} gl;
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
VkFormat vk_format;
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
guint32 dmabuf_fourcc;
|
|
|
|
|
#endif
|
|
|
|
|
/* no premultiplication going on here */
|
|
|
|
|
void (* to_float) (float *, const guchar*, gsize);
|
|
|
|
|
@@ -379,6 +384,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_B8G8R8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ARGB8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = b8g8r8a8_premultiplied_to_float,
|
|
|
|
|
.from_float = b8g8r8a8_premultiplied_from_float,
|
|
|
|
|
@@ -403,6 +411,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_BGRA8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a8r8g8b8_premultiplied_to_float,
|
|
|
|
|
.from_float = a8r8g8b8_premultiplied_from_float,
|
|
|
|
|
@@ -426,6 +437,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8B8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r8g8b8a8_premultiplied_to_float,
|
|
|
|
|
.from_float = r8g8b8a8_premultiplied_from_float,
|
|
|
|
|
@@ -450,6 +464,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_RGBA8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a8b8g8r8_premultiplied_to_float,
|
|
|
|
|
.from_float = a8b8g8r8_premultiplied_from_float,
|
|
|
|
|
@@ -474,6 +491,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_B8G8R8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ARGB8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = b8g8r8a8_to_float,
|
|
|
|
|
.from_float = b8g8r8a8_from_float,
|
|
|
|
|
@@ -498,6 +518,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_BGRA8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a8r8g8b8_to_float,
|
|
|
|
|
.from_float = a8r8g8b8_from_float,
|
|
|
|
|
@@ -521,6 +544,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8B8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r8g8b8a8_to_float,
|
|
|
|
|
.from_float = r8g8b8a8_from_float,
|
|
|
|
|
@@ -545,6 +571,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_RGBA8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a8b8g8r8_to_float,
|
|
|
|
|
.from_float = a8b8g8r8_from_float,
|
|
|
|
|
@@ -570,6 +599,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_B8G8R8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_XRGB8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = b8g8r8x8_to_float,
|
|
|
|
|
.from_float = b8g8r8x8_from_float,
|
|
|
|
|
@@ -595,6 +627,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_BGRX8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = x8r8g8b8_to_float,
|
|
|
|
|
.from_float = x8r8g8b8_from_float,
|
|
|
|
|
@@ -619,6 +654,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8B8A8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_XBGR8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r8g8b8x8_to_float,
|
|
|
|
|
.from_float = r8g8b8x8_from_float,
|
|
|
|
|
@@ -644,6 +682,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_UNDEFINED,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_RGBX8888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = x8b8g8r8_to_float,
|
|
|
|
|
.from_float = x8b8g8r8_from_float,
|
|
|
|
|
@@ -668,6 +709,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8B8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_BGR888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r8g8b8_to_float,
|
|
|
|
|
.from_float = r8g8b8_from_float,
|
|
|
|
|
@@ -693,6 +737,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_B8G8R8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_RGB888,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = b8g8r8_to_float,
|
|
|
|
|
.from_float = b8g8r8_from_float,
|
|
|
|
|
@@ -720,6 +767,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16_to_float,
|
|
|
|
|
.from_float = r16g16b16_from_float,
|
|
|
|
|
@@ -746,6 +796,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16A16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR16161616,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16a16_to_float,
|
|
|
|
|
.from_float = r16g16b16a16_from_float,
|
|
|
|
|
@@ -772,6 +825,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16A16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR16161616,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16a16_to_float,
|
|
|
|
|
.from_float = r16g16b16a16_from_float,
|
|
|
|
|
@@ -798,6 +854,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16_float_to_float,
|
|
|
|
|
.from_float = r16g16b16_float_from_float,
|
|
|
|
|
@@ -823,6 +882,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16A16_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR16161616F,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16a16_float_to_float,
|
|
|
|
|
.from_float = r16g16b16a16_float_from_float,
|
|
|
|
|
@@ -848,6 +910,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16B16A16_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_ABGR16161616F,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r16g16b16a16_float_to_float,
|
|
|
|
|
.from_float = r16g16b16a16_float_from_float,
|
|
|
|
|
@@ -874,6 +939,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R32G32B32_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r32g32b32_float_to_float,
|
|
|
|
|
.from_float = r32g32b32_float_from_float,
|
|
|
|
|
@@ -899,6 +967,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R32G32B32A32_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r32g32b32a32_float_to_float,
|
|
|
|
|
.from_float = r32g32b32a32_float_from_float,
|
|
|
|
|
@@ -924,6 +995,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R32G32B32A32_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = r32g32b32a32_float_to_float,
|
|
|
|
|
.from_float = r32g32b32a32_float_from_float,
|
|
|
|
|
@@ -948,6 +1022,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g8a8_premultiplied_to_float,
|
|
|
|
|
.from_float = g8a8_premultiplied_from_float,
|
|
|
|
|
@@ -972,6 +1049,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8G8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g8a8_to_float,
|
|
|
|
|
.from_float = g8a8_from_float,
|
|
|
|
|
@@ -996,6 +1076,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_R8,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g8_to_float,
|
|
|
|
|
.from_float = g8_from_float,
|
|
|
|
|
@@ -1023,6 +1106,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g16a16_premultiplied_to_float,
|
|
|
|
|
.from_float = g16a16_premultiplied_from_float,
|
|
|
|
|
@@ -1050,6 +1136,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16G16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g16a16_to_float,
|
|
|
|
|
.from_float = g16a16_from_float,
|
|
|
|
|
@@ -1077,6 +1166,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = DRM_FORMAT_R16,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = g16_to_float,
|
|
|
|
|
.from_float = g16_from_float,
|
|
|
|
|
@@ -1101,6 +1193,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R8_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a8_to_float,
|
|
|
|
|
.from_float = a8_from_float,
|
|
|
|
|
@@ -1128,6 +1223,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16_UNORM,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a16_to_float,
|
|
|
|
|
.from_float = a16_from_float,
|
|
|
|
|
@@ -1154,6 +1252,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R16_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a16_float_to_float,
|
|
|
|
|
.from_float = a16_float_from_float,
|
|
|
|
|
@@ -1180,6 +1281,9 @@ static const GdkMemoryFormatDescription memory_formats[] = {
|
|
|
|
|
},
|
|
|
|
|
#ifdef GDK_RENDERING_VULKAN
|
|
|
|
|
.vk_format = VK_FORMAT_R32_SFLOAT,
|
|
|
|
|
#endif
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
.dmabuf_fourcc = 0,
|
|
|
|
|
#endif
|
|
|
|
|
.to_float = a32_float_to_float,
|
|
|
|
|
.from_float = a32_float_from_float,
|
|
|
|
|
@@ -1474,6 +1578,34 @@ gdk_memory_format_vk_rgba_format (GdkMemoryFormat format,
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* gdk_memory_format_get_dmabuf_fourcc:
|
|
|
|
|
* @format: The memory format
|
|
|
|
|
*
|
|
|
|
|
* Gets the dmabuf fourcc for a given memory format.
|
|
|
|
|
*
|
|
|
|
|
* The format is an exact match, so data can be copied between the
|
|
|
|
|
* dmabuf and data of the format. This is different from the
|
|
|
|
|
* memoryformat returned by a GdkDmabufTexture, which is just the
|
|
|
|
|
* closest match.
|
|
|
|
|
*
|
|
|
|
|
* Not all formats have a corresponding dmabuf format.
|
|
|
|
|
* In those cases 0 will be returned.
|
|
|
|
|
*
|
|
|
|
|
* If dmabuf support is not compiled in, always returns 0.
|
|
|
|
|
*
|
|
|
|
|
* Returns: the fourcc or 0
|
|
|
|
|
**/
|
|
|
|
|
guint32
|
|
|
|
|
gdk_memory_format_get_dmabuf_fourcc (GdkMemoryFormat format)
|
|
|
|
|
{
|
|
|
|
|
#ifdef HAVE_DMABUF
|
|
|
|
|
return memory_formats[format].dmabuf_fourcc;
|
|
|
|
|
#else
|
|
|
|
|
return 0;
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
premultiply (float *rgba,
|
|
|
|
|
gsize n)
|
|
|
|
|
|