Commit Graph

1005 Commits (56392668cba41ca6427073ab0fc1bd200981ad8b)

Author SHA1 Message Date
snagar 56392668cb stbi__bmp_load() might not return correct Channel
Struct stbi__bmp_data in stbi__bmp_load() does not have initialize code for the: mr,mg,mb,ma, all_a as the code does in the beginning of " stbi__bmp_load()" function.
When I tried to load 24bit BMP image, the number of channels returned was 4. Image displayed wrongly.
When I done the same on the old stb_image (v1.33) image displayed correctly. On that code, the channel number returned was: 3.
After debugging, I found out that difference was in the use of the named struct. The values of the parameters above were not initialized for the 24bit BMP when calling "stbi__bmp_parse_header()" function.

Proposed solution:
I added an init() function to the struct, and called it just before we initialized the "info.all_a" in "stbi__bmp_load()" function.
Since the "stbi__bmp_parse_header()" is called only from  stbi__bmp_load(), I think my suggestion is safe.
2016-02-11 21:35:48 +02:00
Sean Barrett 955dfe991b Merge pull request #238 from dbohdan/master
other_libs.md: Update Picol
2016-01-28 13:07:09 -08:00
Danyil Bohdan d35dbc4368 other_libs.md: Update Picol 2016-01-28 16:42:13 +02:00
Sean Barrett a78bc165b9 Update other_libs.md 2016-01-26 12:29:13 -08:00
Sean Barrett 124669a8f5 Update other_libs.md 2016-01-26 12:28:23 -08:00
Sean Barrett 6fb2270617 Update other_libs.md 2016-01-26 12:27:51 -08:00
Sean Barrett 1d95d24ae9 Update other_libs.md 2016-01-26 12:26:47 -08:00
Sean Barrett b8a9e19f86 Update other_libs.md 2016-01-26 12:23:45 -08:00
Sean Barrett a1169d90d0 Update other_libs.md 2016-01-26 12:22:16 -08:00
Sean Barrett 6e556fe757 Update other_libs.md 2016-01-26 12:08:20 -08:00
Sean Barrett c63e608497 Update other_libs.md 2016-01-26 11:42:11 -08:00
Sean Barrett b9504633b9 Update other_libs.md 2016-01-26 10:23:34 -08:00
Sean Barrett ccfca5a5da Update other_libs.md 2016-01-26 08:45:05 -08:00
Sean Barrett 547c951091 Update other_libs.md 2016-01-26 08:43:34 -08:00
Sean Barrett f4a878dbf9 Update other_libs.md 2016-01-26 08:40:04 -08:00
Sean Barrett 49f971110f Update other_libs.md 2016-01-26 08:39:30 -08:00
Sean Barrett a4a27ea3cd Update other_libs.md 2016-01-26 08:36:59 -08:00
Sean Barrett 47796836b6 Update other_libs.md 2016-01-26 08:02:05 -08:00
Sean Barrett 229ebfa4ff Update other_libs.md 2016-01-26 07:15:03 -08:00
Sean Barrett 78befd33e9 Update other_libs.md 2016-01-26 06:57:37 -08:00
Sean Barrett 4dd8cf9ae8 Update other_libs.md 2016-01-26 06:25:38 -08:00
Sean Barrett 7a889d272a Update other_libs.md 2016-01-26 06:16:48 -08:00
Sean Barrett 420c68ac83 Update other_libs.md 2016-01-26 06:07:23 -08:00
Sean Barrett 983630e7b0 Update other_libs.md 2016-01-26 05:59:25 -08:00
Sean Barrett bb7355f4b1 Update other_libs.md 2016-01-26 05:50:38 -08:00
Sean Barrett e1bc6029b9 Update other_libs.md 2016-01-26 05:48:34 -08:00
Sean Barrett cbbd2d053f Update other_libs.md 2016-01-26 05:47:02 -08:00
Sean Barrett 94106a8fdd Update other_libs.md 2016-01-26 05:38:05 -08:00
Sean Barrett 91402d1a0d Update other_libs.md 2016-01-26 05:36:11 -08:00
Sean Barrett fc5009027d Update other_libs.md 2016-01-26 05:31:12 -08:00
Sean Barrett 1de2492002 Update other_libs.md 2016-01-23 23:44:21 -08:00
Sean Barrett b0b3c2633d Update other_libs.md 2016-01-23 14:39:54 -08:00
Sean Barrett 0e76e2ca84 Merge pull request #235 from dbohdan/master
other_libs.md: Add Picol
2016-01-23 14:38:29 -08:00
Danyil Bohdan 02b90e8fb5 other_libs.md: Add Picol 2016-01-23 23:13:31 +02:00
Sean Barrett a3278496a8 Merge pull request #234 from dbohdan/master
other_libs.md: Add LIL
2016-01-23 10:19:51 -08:00
Sean Barrett 6a5590e11e Update other_libs.md 2016-01-23 10:16:34 -08:00
Danyil Bohdan 97a7c1ba9b other_libs.md: Add LIL 2016-01-23 20:16:03 +02:00
Sean Barrett 97b614a080 Update other_libs.md 2016-01-23 10:14:43 -08:00
Sean Barrett c2a4ff554d Update other_libs.md 2016-01-23 09:40:42 -08:00
Sean Barrett 3a4e6485b4 Update other_libs.md 2016-01-23 09:39:51 -08:00
Sean Barrett 143834ed42 Update other_libs.md 2016-01-23 09:38:32 -08:00
Sean Barrett 4aff4632f3 Update other_libs.md 2016-01-23 09:37:32 -08:00
Sean Barrett 9fe0dc93a4 other_libs gets more guidelines 2016-01-23 09:30:37 -08:00
Sean Barrett d177013061 add submission notes, cleanup easyexif 2016-01-23 09:21:29 -08:00
Mayank Lahiri d9552a9c51 Add easy_exif to other_libs.md
EasyEXIF is a tiny, lightweight C++ library that parses basic information out of JPEG files. It uses only the std::string library and is otherwise pure C++. You pass it the binary contents of a JPEG file, and it parses out a few of the most important EXIF fields for you.
2016-01-23 09:11:31 -08:00
Sean Barrett 6308d725f4 update other_libs.md 2016-01-23 08:55:28 -08:00
Sean Barrett 32b07e331f Merge branch 'master' of https://github.com/codeplea/stb
Conflicts:
	docs/other_libs.md
2016-01-23 08:48:02 -08:00
Sean Barrett 5de39a0365 Merge branch 'master' of https://github.com/nothings/stb
Conflicts:
	docs/other_libs.md
2016-01-23 08:45:50 -08:00
Sean Barrett 9c8762a156 update other_libs.md 2016-01-23 08:44:27 -08:00
Lewis Van Winkle c26f400e6f Added minctest and tinyexpr. 2016-01-23 10:25:23 -06:00