I am struggling to understand how to approach resize problem. I see there are alot of codes available for me to use directly. I do understand the problem, Zymal's pesudocode, but the lack of clarity lies in understanding how bimap files are read. And I do not find any sources that can clearly explain the details on the datatypes used in BITMAPs. Can someone please explain: 1) How bitmap file is read? 2) The information regarding BITMAPFILEHEADER (https://docs.microsoft.com/en-us/windows/win32/api/wingdi/ns-wingdi-bitmapfileheader) and BITMAPINFOHEADER (https://docs.microsoft.com/en-us/windows/win32/api/wingdi/ns-wingdi-bitmapinfoheader).

Many thanks, Indu


Basically you need to modify the headers so they are the right size but not all the information contained in the headers needs to change. Than you need to iterate over the printing of the pictures so that it prints twice for the height and wight and it accounts for the new padding.

  • Yes, thanks. But I wanted more information regarding the overall structure of bitmaps. The datatype and the syntax is very new to me.
    – Indu
    Dec 18 '19 at 22:54
  • If you want a more specific answer about the data structure and it’s syntax please ask a more specific question. The two link you posted have all you need but it’s really hard to read and understand. Sorry I couldn’t be of more help.
    – Chris
    Dec 18 '19 at 23:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .