1
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/* GdkPixbuf library - Win32 GDI+ Pixbuf Loader
4
* Copyright (C) 2008 Dominic Lachowicz
5
* Copyright (C) 2008 Alberto Ruiz
7
* Authors: Dominic Lachowicz <domlachowicz@gmail.com>
8
* Alberto Ruiz <aruiz@gnome.org>
10
* This library is free software; you can redistribute it and/or
11
* modify it under the terms of the GNU Lesser General Public
12
* License as published by the Free Software Foundation; either
13
* version 2 of the License, or (at your option) any later version.
15
* This library is distributed in the hope that it will be useful,
16
* but WITHOUT ANY WARRANTY; without even the implied warranty of
17
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18
* Lesser General Public License for more * You should have received a copy of the GNU Lesser General Public
19
* License along with this library; if not, write to the
20
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21
* Boston, MA 02111-1307, USA.
24
#include "io-gdip-utils.h"
27
gdk_pixbuf__gdip_image_save_TIFF_to_callback (GdkPixbufSaveFunc save_func,
34
return gdip_save_pixbuf (pixbuf, L"image/tiff", NULL, save_func, user_data, error);
38
gdk_pixbuf__gdip_image_save_TIFF (FILE *f,
44
return gdk_pixbuf__gdip_image_save_TIFF_to_callback (gdip_save_to_file_callback, f, pixbuf, keys, values, error);
47
#ifndef INCLUDE_gdiplus
48
#define MODULE_ENTRY(function) G_MODULE_EXPORT void function
50
#define MODULE_ENTRY(function) void _gdk_pixbuf__gdip_tiff_ ## function
53
MODULE_ENTRY (fill_vtable) (GdkPixbufModule *module)
55
gdip_fill_vtable (module);
57
module->save_to_callback = gdk_pixbuf__gdip_image_save_TIFF_to_callback;
58
module->save = gdk_pixbuf__gdip_image_save_TIFF; /* for gtk < 2.14, you need to implement both. otherwise gdk-pixbuf-queryloaders fails */
61
MODULE_ENTRY (fill_info) (GdkPixbufFormat *info)
63
static GdkPixbufModulePattern signature[] = {
64
{ "MM \x2a", " z ", 100 }, /* TIFF */
65
{ "II\x2a ", " z", 100 }, /* TIFF */
69
static gchar *mime_types[] = {
74
static gchar *extensions[] = {
81
info->signature = signature;
82
info->description = "The TIFF image format";
83
info->mime_types = mime_types;
84
info->extensions = extensions;
85
info->flags = GDK_PIXBUF_FORMAT_WRITABLE | GDK_PIXBUF_FORMAT_THREADSAFE;
86
info->license = "LGPL";