How is a JPEG image’s color type determined?

In order to decode and display a JPEG image, you have to know what "color type" (or "color model") it uses. There are several possibilities that your software probably ought to handle: Grayscale YCbCr (transformed from RGB) RGB YCCK (transformed from CMYK) CMYK Unfortunately, if you look at all the bits and bytes that make … Continue reading How is a JPEG image’s color type determined?

Summary of some Win32 I/O character encoding behavior

This is the first of a series of post. Here are the others: Part 2 (chcp 65001) Part 3 (the Unicode API) Supplement 1 (A Cygwin issue) Supplement 2 (setlocale enhancement) Supplement 3 (UTF-8 manifest) This post is about programming a Windows Win32 application, mainly one that uses the console (command line). It summarizes the … Continue reading Summary of some Win32 I/O character encoding behavior