[Spice-devel] [PATCH] add image type for images that are compressed by zlib after they have been compressed by glz

Yonit Halperin yhalperi at redhat.com
Sun Jun 20 05:22:42 PDT 2010


---
 spice/draw.h  |   11 +++++++++++
 spice/enums.h |    1 +
 2 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/spice/draw.h b/spice/draw.h
index ff70e7b..874681d 100644
--- a/spice/draw.h
+++ b/spice/draw.h
@@ -182,6 +182,17 @@ typedef struct SPICE_ATTR_PACKED SpiceJPEGImage {
     SpiceJPEGData jpeg;
 } SpiceJPEGImage;
 
+typedef struct SPICE_ATTR_PACKED SpiceZlibGlzRGBData {
+    uint32_t glz_data_size;
+    uint32_t data_size;
+    uint8_t data[0];
+} SpiceZlibGlzRGBData;
+
+typedef struct SPICE_ATTR_PACKED SpiceZlibGlzRGBImage {
+    SpiceImageDescriptor descriptor;
+    SpiceZlibGlzRGBData zlib_glz;
+} SpiceZlibGlzRGBImage;
+
 typedef struct SPICE_ATTR_PACKED SpiceOpaque {
     SPICE_ADDRESS src_bitmap;
     SpiceRect src_area;
diff --git a/spice/enums.h b/spice/enums.h
index 0ea4e79..4dfda1f 100644
--- a/spice/enums.h
+++ b/spice/enums.h
@@ -129,6 +129,7 @@ enum SpiceImageType {
     SPICE_IMAGE_TYPE_SURFACE,
     SPICE_IMAGE_TYPE_JPEG,
     SPICE_IMAGE_TYPE_FROM_CACHE_LOSSLESS,
+    SPICE_IMAGE_TYPE_ZLIB_GLZ_RGB,
 
     SPICE_IMAGE_TYPE_ENUM_END
 };
-- 
1.6.6.1



More information about the Spice-devel mailing list