]> git.pld-linux.org Git - packages/abiword.git/blame - abiword-oldmagick.patch
- updated for 2.4.4
[packages/abiword.git] / abiword-oldmagick.patch
CommitLineData
2af01931
AM
1diff -urN abiword-plugins/wp/impexp/graphics/magick/xp/AbiMagick.cpp abiword-plugins-old/wp/impexp/graphics/magick/xp/AbiMagick.cpp
2--- abiword-plugins/wp/impexp/graphics/magick/xp/AbiMagick.cpp Mon Apr 29 19:45:35 2002
3+++ abiword-plugins-old/wp/impexp/graphics/magick/xp/AbiMagick.cpp Wed Mar 27 19:31:42 2002
4@@ -44,16 +44,11 @@
5 static Magick::Image ImageFromPNGByteBuf ( const UT_ByteBuf * pBB )
6 {
7 Magick::Blob inBlob ( pBB->getPointer (0), pBB->getLength () );
8-
9- // not Magick::Image ( inBlob ) which doesn't work on win32 for some reason
10- Magick::Image img ;
11- img.read ( inBlob ) ;
12-
13- return img ;
14+ return Magick::Image ( inBlob );
15 }
16
17-static UT_Error PNGByteBufFromImage ( Magick::Image & inImage,
18- UT_ByteBuf ** outByteBuf )
19+static void PNGByteBufFromImage ( Magick::Image & inImage,
20+ UT_ByteBuf ** outByteBuf )
21 {
22 Magick::Blob outBlob;
23 inImage.write ( &outBlob, "png" );
24@@ -63,8 +58,6 @@
25 buf->append ( (const UT_Byte*)outBlob.data (), outBlob.length () );
26
27 *outByteBuf = buf ;
28-
29- return UT_OK ;
30 }
31
32 // -----------------------------------------------------------------------
33@@ -128,7 +121,9 @@
34 {
35 try
36 {
37- return PNGByteBufFromImage ( ImageFromPNGByteBuf ( pBB ), ppBB ) ;
38+ Magick::Image img ( ImageFromPNGByteBuf ( pBB ) ) ;
39+ PNGByteBufFromImage ( img, ppBB ) ;
40+ return UT_OK;
41 }
42 catch (...)
43 {
This page took 0.06304 seconds and 4 git commands to generate.