Skip to content

Commit

Permalink
gdiplus: Add pixel conversions to 4bpp indexed.
Browse files Browse the repository at this point in the history
Signed-off-by: Bernhard Kölbl <besentv@gmail.com>
Signed-off-by: Esme Povirk <esme@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
  • Loading branch information
besentv authored and julliard committed Nov 19, 2021
1 parent 9321d52 commit 77121b3
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions dlls/gdiplus/image.c
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_16bppGrayScale, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_16bppGrayScale, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_16bppGrayScale, setpixel_8bppIndexed);
case PixelFormat16bppRGB555:
Expand Down Expand Up @@ -755,6 +757,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB555, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB555, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB555, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -784,6 +788,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB565, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB565, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_16bppRGB565, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -813,6 +819,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_16bppARGB1555, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_16bppARGB1555, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_16bppARGB1555, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -842,6 +850,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_24bppRGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_24bppRGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_24bppRGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -871,6 +881,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_32bppRGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_32bppRGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_32bppRGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -900,6 +912,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_32bppARGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_32bppARGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_32bppARGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -928,6 +942,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_32bppPARGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_32bppPARGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_32bppPARGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -957,6 +973,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_48bppRGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_48bppRGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_48bppRGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -986,6 +1004,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_64bppARGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_64bppARGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_64bppARGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down Expand Up @@ -1015,6 +1035,8 @@ GpStatus convert_pixels(INT width, INT height,
{
case PixelFormat1bppIndexed:
convert_rgb_to_indexed(getpixel_64bppPARGB, setpixel_1bppIndexed);
case PixelFormat4bppIndexed:
convert_rgb_to_indexed(getpixel_64bppPARGB, setpixel_4bppIndexed);
case PixelFormat8bppIndexed:
convert_rgb_to_indexed(getpixel_64bppPARGB, setpixel_8bppIndexed);
case PixelFormat16bppGrayScale:
Expand Down

0 comments on commit 77121b3

Please sign in to comment.