sharp 0.32.6 → 0.33.0-alpha.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,151 +0,0 @@
1
- /* Object part of the VSource and VTarget class
2
- */
3
-
4
- /*
5
-
6
- Copyright (C) 1991-2001 The National Gallery
7
-
8
- This program is free software; you can redistribute it and/or modify
9
- it under the terms of the GNU Lesser General Public License as published by
10
- the Free Software Foundation; either version 2 of the License, or
11
- (at your option) any later version.
12
-
13
- This program is distributed in the hope that it will be useful,
14
- but WITHOUT ANY WARRANTY; without even the implied warranty of
15
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
- GNU Lesser General Public License for more details.
17
-
18
- You should have received a copy of the GNU Lesser General Public License
19
- along with this program; if not, write to the Free Software
20
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21
- 02110-1301 USA
22
-
23
- */
24
-
25
- /*
26
-
27
- These files are distributed with VIPS - http://www.vips.ecs.soton.ac.uk
28
-
29
- */
30
-
31
- #ifdef HAVE_CONFIG_H
32
- #include <config.h>
33
- #endif /*HAVE_CONFIG_H*/
34
-
35
- #include <vips/vips8>
36
-
37
- #include <vips/debug.h>
38
-
39
- /*
40
- #define VIPS_DEBUG
41
- #define VIPS_DEBUG_VERBOSE
42
- */
43
-
44
- VIPS_NAMESPACE_START
45
-
46
- VSource
47
- VSource::new_from_descriptor( int descriptor )
48
- {
49
- VipsSource *input;
50
-
51
- if( !(input = vips_source_new_from_descriptor( descriptor )) )
52
- throw VError();
53
-
54
- VSource out( input );
55
-
56
- return( out );
57
- }
58
-
59
- VSource
60
- VSource::new_from_file( const char *filename )
61
- {
62
- VipsSource *input;
63
-
64
- if( !(input = vips_source_new_from_file( filename )) )
65
- throw VError();
66
-
67
- VSource out( input );
68
-
69
- return( out );
70
- }
71
-
72
- VSource
73
- VSource::new_from_blob( VipsBlob *blob )
74
- {
75
- VipsSource *input;
76
-
77
- if( !(input = vips_source_new_from_blob( blob )) )
78
- throw VError();
79
-
80
- VSource out( input );
81
-
82
- return( out );
83
- }
84
-
85
- VSource
86
- VSource::new_from_memory( const void *data,
87
- size_t size )
88
- {
89
- VipsSource *input;
90
-
91
- if( !(input = vips_source_new_from_memory( data, size )) )
92
- throw VError();
93
-
94
- VSource out( input );
95
-
96
- return( out );
97
- }
98
-
99
- VSource
100
- VSource::new_from_options( const char *options )
101
- {
102
- VipsSource *input;
103
-
104
- if( !(input = vips_source_new_from_options( options )) )
105
- throw VError();
106
-
107
- VSource out( input );
108
-
109
- return( out );
110
- }
111
-
112
- VTarget
113
- VTarget::new_to_descriptor( int descriptor )
114
- {
115
- VipsTarget *output;
116
-
117
- if( !(output = vips_target_new_to_descriptor( descriptor )) )
118
- throw VError();
119
-
120
- VTarget out( output );
121
-
122
- return( out );
123
- }
124
-
125
- VTarget
126
- VTarget::new_to_file( const char *filename )
127
- {
128
- VipsTarget *output;
129
-
130
- if( !(output = vips_target_new_to_file( filename )) )
131
- throw VError();
132
-
133
- VTarget out( output );
134
-
135
- return( out );
136
- }
137
-
138
- VTarget
139
- VTarget::new_to_memory()
140
- {
141
- VipsTarget *output;
142
-
143
- if( !(output = vips_target_new_to_memory()) )
144
- throw VError();
145
-
146
- VTarget out( output );
147
-
148
- return( out );
149
- }
150
-
151
- VIPS_NAMESPACE_END
@@ -1,49 +0,0 @@
1
- // Code for error type
2
-
3
- /*
4
-
5
- Copyright (C) 1991-2001 The National Gallery
6
-
7
- This program is free software; you can redistribute it and/or modify
8
- it under the terms of the GNU Lesser General Public License as published by
9
- the Free Software Foundation; either version 2 of the License, or
10
- (at your option) any later version.
11
-
12
- This program is distributed in the hope that it will be useful,
13
- but WITHOUT ANY WARRANTY; without even the implied warranty of
14
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
- GNU Lesser General Public License for more details.
16
-
17
- You should have received a copy of the GNU Lesser General Public License
18
- along with this program; if not, write to the Free Software
19
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20
- 02110-1301 USA
21
-
22
- */
23
-
24
- /*
25
-
26
- These files are distributed with VIPS - http://www.vips.ecs.soton.ac.uk
27
-
28
- */
29
-
30
- #ifdef HAVE_CONFIG_H
31
- #include <config.h>
32
- #endif /*HAVE_CONFIG_H*/
33
-
34
- #include <vips/vips8>
35
-
36
- VIPS_NAMESPACE_START
37
-
38
- std::ostream &operator<<( std::ostream &file, const VError &err )
39
- {
40
- err.ostream_print( file );
41
- return( file );
42
- }
43
-
44
- void VError::ostream_print( std::ostream &file ) const
45
- {
46
- file << _what;
47
- }
48
-
49
- VIPS_NAMESPACE_END