summaryrefslogtreecommitdiff
path: root/image/bmpread.h
diff options
context:
space:
mode:
authorRichard Wilson <rjw@netsurf-browser.org>2006-02-26 02:25:19 +0000
committerRichard Wilson <rjw@netsurf-browser.org>2006-02-26 02:25:19 +0000
commit60ea34ad48f604c96f228d8f7942c5527e8a5b15 (patch)
tree81afbe5a766c42b7cc1b3036be990c8fcda299c5 /image/bmpread.h
parentda4a9313f1260531ec3dde07b32c122f120f695c (diff)
downloadnetsurf-60ea34ad48f604c96f228d8f7942c5527e8a5b15.tar.gz
netsurf-60ea34ad48f604c96f228d8f7942c5527e8a5b15.tar.bz2
[project @ 2006-02-26 02:25:19 by rjw]
Add support for ICO files. svn path=/import/netsurf/; revision=2096
Diffstat (limited to 'image/bmpread.h')
-rw-r--r--image/bmpread.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/image/bmpread.h b/image/bmpread.h
index 45468a9ed..275374e5a 100644
--- a/image/bmpread.h
+++ b/image/bmpread.h
@@ -44,11 +44,29 @@ struct bmp_image {
unsigned int *colour_table; /** colour table */
bool reversed; /** scanlines are top to bottom */
bool decoded; /** whether the image has been decoded */
+ bool ico; /** image is part of an ICO, mask follows */
struct bitmap *bitmap; /** decoded image */
};
+struct ico_image {
+ struct bmp_image bmp;
+ struct ico_image *next;
+};
+
+struct ico_collection {
+ unsigned char *ico_data; /** pointer to ICO data */
+ unsigned int buffer_size; /** total number of bytes of ICO data available */
+ unsigned int width; /** width of largest BMP */
+ unsigned int height; /** heigth of largest BMP */
+ struct ico_image *first;
+};
+
bmp_result bmp_analyse(struct bmp_image *bmp);
bmp_result bmp_decode(struct bmp_image *bmp);
void bmp_finalise(struct bmp_image *bmp);
+bmp_result ico_analyse(struct ico_collection *ico);
+struct bmp_image *ico_find(struct ico_collection *ico, int width, int height);
+void ico_finalise(struct ico_collection *ico);
+
#endif