aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSebastian Geerken <devnull@localhost>2013-06-17 11:21:32 +0200
committerSebastian Geerken <devnull@localhost>2013-06-17 11:21:32 +0200
commite29d48718515b0afe04fecc396f7c34865726cab (patch)
treebb72f513ccc03e5f81d7447a02dc7b203e67fa0f /src
parent126ae913efb3829c980a2151db5bbcfd68c5b39c (diff)
Corrections of gamma.
Diffstat (limited to 'src')
-rw-r--r--src/gif.c3
-rw-r--r--src/jpeg.c2
-rw-r--r--src/png.c2
3 files changed, 4 insertions, 3 deletions
diff --git a/src/gif.c b/src/gif.c
index a4233267..69fcf5d3 100644
--- a/src/gif.c
+++ b/src/gif.c
@@ -816,7 +816,8 @@ static size_t Gif_do_img_desc(DilloGif *gif, void *Buf,
/** \todo Gamma for GIF? */
a_Dicache_set_parms(gif->url, gif->version, gif->Image,
- gif->Width, gif->Height, DILLO_IMG_TYPE_INDEXED, 2.2);
+ gif->Width, gif->Height, DILLO_IMG_TYPE_INDEXED,
+ 1 / 2.2);
Flags = buf[8];
diff --git a/src/jpeg.c b/src/jpeg.c
index 7efdbfbb..625808fb 100644
--- a/src/jpeg.c
+++ b/src/jpeg.c
@@ -303,7 +303,7 @@ static void Jpeg_write(DilloJpeg *jpeg, void *Buf, uint_t BufSize)
a_Dicache_set_parms(jpeg->url, jpeg->version, jpeg->Image,
(uint_t)jpeg->cinfo.image_width,
(uint_t)jpeg->cinfo.image_height,
- type, 2.2);
+ type, 1 / 2.2);
/* decompression step 4 (see libjpeg.doc) */
jpeg->state = DILLO_JPEG_STARTING;
diff --git a/src/png.c b/src/png.c
index 767df994..44d55733 100644
--- a/src/png.c
+++ b/src/png.c
@@ -204,7 +204,7 @@ Png_datainfo_callback(png_structp png_ptr, png_infop info_ptr)
/** \todo Gamma for PNG? */
a_Dicache_set_parms(png->url, png->version, png->Image,
(uint_t)png->width, (uint_t)png->height,
- DILLO_IMG_TYPE_RGB, 2.2);
+ DILLO_IMG_TYPE_RGB, 1 / 2.2);
}
static void