aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2026-07-26 00:45:26 +0200
committerdec05eba <dec05eba@protonmail.com>2026-07-26 00:45:26 +0200
commitbbd861af191908130d7f2f51059e1be1bb244052 (patch)
treecdbc7d61729b4e2edb7a3e8233a89d56d55f4366 /include
parent3239a346ad886ccaf6cb047bc6856e960320c259 (diff)
Fix jpeg screenshot not yuv444
Diffstat (limited to 'include')
-rw-r--r--include/image_writer.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/image_writer.h b/include/image_writer.h
index 01101b2..15e478c 100644
--- a/include/image_writer.h
+++ b/include/image_writer.h
@@ -5,6 +5,9 @@
typedef struct gsr_egl gsr_egl;
+/* Quality at which yuv444 (no chroma subsampling) is used instead of yuv420 to preserve color detail at high quality */
+#define JPEG_YUV444_QUALITY_THRESHOLD 91
+
typedef enum {
GSR_IMAGE_FORMAT_JPEG,
GSR_IMAGE_FORMAT_PNG
@@ -15,6 +18,12 @@ typedef struct {
int width;
int height;
unsigned int texture;
+
+ void *turbojpeg_lib;
+ void *turbojpeg_compressor;
+ void *tjCompress2_func;
+ void *tjFree_func;
+ void *tjDestroy_func;
} gsr_image_writer;
bool gsr_image_writer_init_opengl(gsr_image_writer *self, gsr_egl *egl, int width, int height);