annotate src/image-load.h @ 972:2ea1059a6091

set fallback pixbuf in case of missing file
author nadvornik
date Tue, 19 Aug 2008 21:01:29 +0000
parents bc9df0fecdc1
children dd311dae857a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
1 /*
196
f6e307c7bad6 rename GQview -> Geeqie over the code
nadvornik
parents: 138
diff changeset
2 * Geeqie
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
3 * (C) 2004 John Ellis
475
48c8e49b571c updated copyright in source files
nadvornik
parents: 446
diff changeset
4 * Copyright (C) 2008 The Geeqie Team
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
5 *
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
6 * Author: John Ellis
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
7 *
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
8 * This software is released under the GNU General Public License (GNU GPL).
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
9 * Please read the included file COPYING for more information.
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
10 * This software comes with no warranty of any kind, use at your own risk!
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
11 */
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
12
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
13
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
14 #ifndef IMAGE_LOAD_H
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
15 #define IMAGE_LOAD_H
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
16
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
17
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
18 ImageLoader *image_loader_new(FileData *fd);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
19
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
20 /* we don't want full FileData for thumbnails */
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
21 ImageLoader *image_loader_new_from_path(const gchar *path);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
22 void image_loader_free(ImageLoader *il);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
23
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
24 void image_loader_set_area_ready_func(ImageLoader *il,
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
25 void (*func_area_ready)(ImageLoader *, guint, guint, guint, guint, gpointer),
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
26 gpointer data_area_ready);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
27 void image_loader_set_error_func(ImageLoader *il,
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
28 void (*func_error)(ImageLoader *, gpointer),
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
29 gpointer data_error);
890
bc9df0fecdc1 Introduce image_loader_set_done_func().
zas_
parents: 475
diff changeset
30 void image_loader_set_done_func(ImageLoader *il,
bc9df0fecdc1 Introduce image_loader_set_done_func().
zas_
parents: 475
diff changeset
31 void (*func_done)(ImageLoader *, gpointer),
bc9df0fecdc1 Introduce image_loader_set_done_func().
zas_
parents: 475
diff changeset
32 gpointer data_done);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
33 void image_loader_set_percent_func(ImageLoader *il,
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
34 void (*func_percent)(ImageLoader *, gdouble, gpointer),
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
35 gpointer data_percent);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
36
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
37 /* Speed up loading when you only need at most width x height size image,
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
38 * only the jpeg GdkPixbuf loader benefits from it - so there is no
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
39 * guarantee that the image will scale down to the requested size..
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
40 */
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
41 void image_loader_set_requested_size(ImageLoader *il, gint width, gint height);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
42
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
43 void image_loader_set_buffer_size(ImageLoader *il, guint size);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
44
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
45 /* this only has effect if used before image_loader_start()
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
46 * default is G_PRIORITY_DEFAULT_IDLE
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
47 */
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
48 void image_loader_set_priority(ImageLoader *il, gint priority);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
49
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
50 gint image_loader_start(ImageLoader *il, void (*func_done)(ImageLoader *, gpointer), gpointer data_done);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
51
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
52
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
53 GdkPixbuf *image_loader_get_pixbuf(ImageLoader *il);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
54 gchar *image_loader_get_format(ImageLoader *il);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
55 gdouble image_loader_get_percent(ImageLoader *il);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
56 gint image_loader_get_is_done(ImageLoader *il);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
57
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
58 gint image_load_dimensions(FileData *fd, gint *width, gint *height);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
59
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
60 #endif