Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.bmp file saves incorrectly #339

Open
Ducklord42 opened this issue Apr 8, 2024 · 0 comments
Open

.bmp file saves incorrectly #339

Ducklord42 opened this issue Apr 8, 2024 · 0 comments
Labels

Comments

@Ducklord42
Copy link

When I save a .bmp file (24-bit color depth) the format is all messed up. The height bytes where "f8 ff ff ff" instead of "08 00 00 00" and the image was 8 by 8 pixels. Also the image was upside down when I reopened it and by own photo viewer program. It might be that the program doesn't take into account that bitmap files store the data upside down; from left to right then bottom to top. Here is the hex file (I fixed the height coordinates but not the photo being upside down):

0000000 4d42 00f6 0000 0000 0000 0036 0000 0028
0000010 0000 0008 0000 0008 0000 0001 0018 0000
0000020 0000 00c0 0000 0000 0000 0000 0000 0000
0000030 0000 0000 0000 ffff ffff ffff ffff ffff
0000040 ffff ffff ffff ffff ffff ffff ffff ffff
0000050 00ff 0000 0000 0000 0000 0000 0000 0000
0000060 0000 ff00 ffff ffff ffff ffff ffff ffff
0000070 ffff 0000 ff00 ffff ffff ffff ffff ffff
0000080 ffff ffff ffff ffff ffff 0000 2400 ed1c
0000090 1c24 ffed ffff ffff ffff ffff 0000 ff00
00000a0 ffff 0000 2400 ed1c 1c24 ffed ffff ffff
00000b0 ffff ffff ffff ffff ffff 0000 2400 ed1c
00000c0 1c24 ffed ffff ffff 00ff 0000 0000 0000
00000d0 0000 0000 2400 ed1c 1c24 ffed ffff ffff
00000e0 ffff ffff ffff ffff ffff ffff ffff ffff
00000f0 ffff ffff ffff

@1j01 1j01 added the bug label Apr 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants