12#ifndef LOADERS_GP_LOADER_H
13#define LOADERS_GP_LOADER_H
18#include <loaders/gp_io.h>
19#include <loaders/gp_data_storage.h>
29int gp_read_image_ex(gp_io *io,
gp_pixmap **img, gp_storage *meta_data,
39int gp_load_image_ex(
const char *src_path,
46int gp_load_meta_data(
const char *src_path, gp_storage *storage);
62int gp_save_image(
const gp_pixmap *src,
const char *dst_path,
65typedef struct gp_loader gp_loader;
74 int (*read)(gp_io *io,
gp_pixmap **img, gp_storage *storage,
82 int (*write)(
const gp_pixmap *src, gp_io *io,
97 int (*match)(
const void *buf);
102 const char *fmt_name;
107 const char *extensions[];
114const gp_loader *gp_loader_by_signature(
const void *buf);
120const gp_loader *gp_loader_by_filename(
const char *path);
127int gp_loader_register(
const gp_loader *self);
136void gp_loader_unregister(
const gp_loader *self);
144gp_pixmap *gp_loader_load_image(
const gp_loader *self,
const char *src_path,
152gp_pixmap *gp_loader_read_image(
const gp_loader *self, gp_io *io,
160int gp_loader_read_image_ex(
const gp_loader *self, gp_io *io,
170int gp_loader_load_image_ex(
const gp_loader *self,
const char *src_path,
180int gp_loader_save_image(
const gp_loader *self,
const gp_pixmap *src,
186void gp_loaders_list(
void);
gp_pixel_type
List of all pixel types.