/*   GPDriver source image.h
 *   $Id: image.h 1.6 2004/02/12 18:06:43 root Exp root $
 *
 *   GPDriver - gimp-print based printer spooler for RISC OS
 *   Copyright (C) 2004 Martin Wuerthner
 *
 *   This program is free software; you can redistribute it and/or modify it
 *   under the terms of the GNU General Public License as published by the Free
 *   Software Foundation; either version 2 of the License, or (at your option)
 *   any later version.
 *
 *   This program is distributed in the hope that it will be useful, but
 *   WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
 *   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 *   for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 *
 *   Martin Wuerthner <ro-printing@mw-software.com>
 *   Mannheimer Str. 18, 67655 Kaiserslautern, Germany
 */

/* a gpd_image_t is an opaque type */
struct gpd_image_s;
typedef struct gpd_image_s gpd_image_t;

/* create a stp_image_t object based on a ROUGPS print job file */
extern gpd_image_t* gpdi_create_image(os_fw job_file_h, void (*progress_func)(int,int));
extern void gpdi_dispose(gpd_image_t* img);

/* reset the image, so it can be printed again */
extern int gpdi_reset_image(gpd_image_t* img);

/* get the short printer name used to create the image */
extern const char* gpdi_get_short_name(gpd_image_t* img);
/* get the long printer name used to create the image */
extern const char* gpdi_get_long_name(gpd_image_t* img);
/* get the resolution name used to create the image */
extern const char* gpdi_get_resolution_name(gpd_image_t* img);

/* get the x coordinate of the left edge of the printable area in millipoints */
extern int gpdi_get_page_x0_mp(gpd_image_t* img);
/* get the y coordinate of the bottom edge of the printable area in millipoints */
extern int gpdi_get_page_y0_mp(gpd_image_t* img);
/* get the x coordinate of the right edge of the printable area in millipoints */
extern int gpdi_get_page_x1_mp(gpd_image_t* img);
/* get the y coordinate of the top edge of the printable area in millipoints */
extern int gpdi_get_page_y1_mp(gpd_image_t* img);

/* get the media width in millipoints */
extern int gpdi_get_pwidth_mp(gpd_image_t* img);
/* get the media heigth in millipoints */
extern int gpdi_get_pheight_mp(gpd_image_t* img);

/* get the width of the bitmap in pixels */
extern int gpdi_get_width(gpd_image_t* img);
/* get the height of the bitmap in pixels */
extern int gpdi_get_height(gpd_image_t* img);

/* get the x resolution of the bitmap */
extern int gpdi_get_xres(gpd_image_t* img);
/* get the y resolution of the bitmap */
extern int gpdi_get_yres(gpd_image_t* img);

/* get the first non-empty row on the page */
extern int gpdi_get_firstp(gpd_image_t* img);
/* get the first non-empty column on the page */
extern int gpdi_get_firstr(gpd_image_t* img);

/* get the number of pixel rows to skip at top of page */
extern int gpdi_get_topm(gpd_image_t* img);
/* get the number of pixels to skip at the left margin */
extern int gpdi_get_leftm(gpd_image_t* img);

/* get the number of copies requested */
extern int gpdi_get_copies(gpd_image_t* img);

/* get the virtual resolution of the bitmap (uniform) */
extern int gpdi_get_virtual_res(gpd_image_t* img);

/* get the underlying stp_image pointer */
extern stp_image_t* gpdi_get_stp_image(gpd_image_t* img);
