diff options
author | Owen Taylor <otaylor@redhat.com> | 2000-01-05 21:33:58 +0000 |
---|---|---|
committer | Owen Taylor <otaylor@src.gnome.org> | 2000-01-05 21:33:58 +0000 |
commit | 830727f8c75c0ef7df49d1b08c406ffd110b525e (patch) | |
tree | d722f7714107fe8564c94828af90685a512da273 /gdk-pixbuf/pixops/pixops.h | |
parent | f14c1f286d46d1a7b78e6243083a651abcbf709f (diff) | |
download | gdk-pixbuf-830727f8c75c0ef7df49d1b08c406ffd110b525e.tar.gz |
Directory full of pixel data scaling code that will eventually migrate
2000-01-05 Owen Taylor <otaylor@redhat.com>
* gdk-pixbuf/pixops/: Directory full of pixel data scaling
code that will eventually migrate into libart.
* configure.in acconfig.h: Add checks for MMX compiler support
* gdk-pixbuf/gdk-pixbuf.h gdk-pixbuf/gdk-pixbuf-scale.c:
Nice wrapper routines for the code in pixops that operate
on pixbufs instead of raw data.
* gdk-pixbuf/testpixbuf-scale: Test program for scaling
routines.
Diffstat (limited to 'gdk-pixbuf/pixops/pixops.h')
-rw-r--r-- | gdk-pixbuf/pixops/pixops.h | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/gdk-pixbuf/pixops/pixops.h b/gdk-pixbuf/pixops/pixops.h new file mode 100644 index 000000000..387b46bc1 --- /dev/null +++ b/gdk-pixbuf/pixops/pixops.h @@ -0,0 +1,80 @@ +#include <libart_lgpl/art_misc.h> +#include <libart_lgpl/art_filterlevel.h> + +/* Scale src_buf from src_width / src_height by factors scale_x, scale_y + * and composite the portion corresponding to + * render_x, render_y, render_width, render_height in the new + * coordinate system into dest_buf starting at 0, 0 + */ +void pixops_composite (art_u8 *dest_buf, + int render_x0, + int render_y0, + int render_x1, + int render_y1, + int dest_rowstride, + int dest_channels, + int dest_has_alpha, + art_u8 *src_buf, + int src_width, + int src_height, + int src_rowstride, + int src_channels, + int src_has_alpha, + double scale_x, + double scale_y, + ArtFilterLevel filter_level, + int overall_alpha); + +/* Scale src_buf from src_width / src_height by factors scale_x, scale_y + * and composite the portion corresponding to + * render_x, render_y, render_width, render_height in the new + * coordinate system against a checkboard with checks of size check_size + * of the colors color1 and color2 into dest_buf starting at 0, 0 + */ +void pixops_composite_color (art_u8 *dest_buf, + int render_x0, + int render_y0, + int render_x1, + int render_y1, + int dest_rowstride, + int dest_channels, + int dest_has_alpha, + art_u8 *src_buf, + int src_width, + int src_height, + int src_rowstride, + int src_channels, + int src_has_alpha, + double scale_x, + double scale_y, + ArtFilterLevel filter_level, + int overall_alpha, + int check_x, + int check_y, + int check_size, + art_u32 color1, + art_u32 color2); + +/* Scale src_buf from src_width / src_height by factors scale_x, scale_y + * and composite the portion corresponding to + * render_x, render_y, render_width, render_height in the new + * coordinate system into dest_buf starting at 0, 0 + */ +void pixops_scale (art_u8 *dest_buf, + int render_x0, + int render_y0, + int render_x1, + int render_y1, + int dest_rowstride, + int dest_channels, + int dest_has_alpha, + art_u8 *src_buf, + int src_width, + int src_height, + int src_rowstride, + int src_channels, + int src_has_alpha, + double scale_x, + double scale_y, + ArtFilterLevel filter_level); + |