diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2024-01-28 20:26:52 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2024-01-28 20:26:52 +0000 |
commit | 28efa62ba175998cde7b922145e0b40e68a2674e (patch) | |
tree | d64401fe3f054f46ead216abb322f082928ddae5 /converter/ppm/ppmtowinicon.c | |
parent | f900db12f6cd4e361b37cf2c6739ac469b6fcafb (diff) | |
download | netpbm-mirror-28efa62ba175998cde7b922145e0b40e68a2674e.tar.gz netpbm-mirror-28efa62ba175998cde7b922145e0b40e68a2674e.tar.xz netpbm-mirror-28efa62ba175998cde7b922145e0b40e68a2674e.zip |
Release 11.05.02
git-svn-id: http://svn.code.sf.net/p/netpbm/code/advanced@4839 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/ppm/ppmtowinicon.c')
-rw-r--r-- | converter/ppm/ppmtowinicon.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/converter/ppm/ppmtowinicon.c b/converter/ppm/ppmtowinicon.c index 0e2751f3..bd478b1e 100644 --- a/converter/ppm/ppmtowinicon.c +++ b/converter/ppm/ppmtowinicon.c @@ -395,9 +395,9 @@ newBitmap(unsigned int const bpp, unsigned int const rows, colorhash_table const cht) { - unsigned int const xByteCt = ROUNDUP(cols, 32)/8; - /* How wide the u1 string for each row should be -- Each byte is 8 - pixels, but must be a multiple of 4 bytes. + unsigned int const xByteCt = ROUNDUP(cols * bpp, 32)/8; + /* How wide the u1 string for each row should be. Pixels are packed + into bytes, padded to a multiple of 4 bytes. */ ICON_bmp * icBitmapP; /* malloc'ed */ u1 ** rowData; /* malloc'ed */ |