[vlc-commits] [Git][videolan/vlc][master] 2 commits: xwd: replace VLC_CODEC_RGB16 with RGB565LE/BE

Jean-Baptiste Kempf (@jbk) gitlab at videolan.org
Wed Oct 4 16:41:57 UTC 2023



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
06e8faf4 by Steve Lhomme at 2023-10-04T16:22:12+00:00
xwd: replace VLC_CODEC_RGB16 with RGB565LE/BE

This is the format depending on the host byte order.

- - - - -
77f57b05 by Steve Lhomme at 2023-10-04T16:22:12+00:00
xwd: replace VLC_CODEC_RGB15 with RGB555LE/BE

This is the format depending on the host byte order.

- - - - -


1 changed file:

- modules/codec/xwd.c


Changes:

=====================================
modules/codec/xwd.c
=====================================
@@ -68,11 +68,13 @@ static int Decode (decoder_t *dec, block_t *block)
             break;
         case 15:
             if (ntohl(hdr->bits_per_pixel) == 16)
-                chroma = VLC_CODEC_RGB15;
+                chroma = ntohl(hdr->byte_order) == 0 /* LSBFirst */ ?
+                    VLC_CODEC_RGB555LE : VLC_CODEC_RGB555BE;
             break;
         case 16:
             if (ntohl(hdr->bits_per_pixel) == 16)
-                chroma = VLC_CODEC_RGB16;
+                chroma = ntohl(hdr->byte_order) == 0 /* LSBFirst */ ?
+                    VLC_CODEC_RGB565LE : VLC_CODEC_RGB565BE;
             break;
         case 24:
             switch (ntohl(hdr->bits_per_pixel))



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/6d8a33705160a703ed46feb3068a1e1ea9e45bee...77f57b0592d9c5702db01f1e8acf772f6607c568

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/6d8a33705160a703ed46feb3068a1e1ea9e45bee...77f57b0592d9c5702db01f1e8acf772f6607c568
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list