gtk/gsk/gpu/gskgpucoloropprivate.h
Matthias Clasen 9f548efd32 gsk: Change color op apis
Make color-related ops take the ccs and a GdkColor, and make
decisions about color conversion on the cpu vs the gpu.

This makes the node processor code simpler, and lets use convert
the color directly into the op instance without extra copying.

We also pass opacity to the op, so it can be applied when we
write the color into the instance.

Lastly, rorder the offset to come right after the opacity argument.

Treat the color and rounded color ops the same way.

Update all callers.

With this, the prepare_color apis in gskgpunodeprocessor.c are
no longer used and have been dropped.
2024-08-05 11:11:14 -04:00

21 lines
913 B
C

#pragma once
#include "gskgputypesprivate.h"
#include "gdkcolorprivate.h"
#include <graphene.h>
G_BEGIN_DECLS
void gsk_gpu_color_op (GskGpuFrame *frame,
GskGpuShaderClip clip,
GdkColorState *ccs,
float opacity,
const graphene_point_t *offset,
const graphene_rect_t *rect,
const GdkColor *color);
G_END_DECLS