Update of /cvsroot/freevo/freevo/lib/pyimlib2
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28411

Modified Files:
        epeg.c 
Log Message:
add missing encode (did not work until now)

Index: epeg.c
===================================================================
RCS file: /cvsroot/freevo/freevo/lib/pyimlib2/epeg.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** epeg.c      11 Apr 2005 18:46:26 -0000      1.2
--- epeg.c      16 Apr 2005 17:02:41 -0000      1.3
***************
*** 47,50 ****
--- 47,51 ----
  #ifdef USE_EPEG
      Epeg_Image *im;
+     Epeg_Thumbnail_Info info;
  
      if (!PyArg_ParseTuple(args, "ss(ii)", &source, &dest, &dest_w, &dest_h))
***************
*** 55,58 ****
--- 56,60 ----
          return PyErr_SetString(PyExc_IOError, "unable to load image"), NULL;
  
+     epeg_thumbnail_comments_get (im, &info);
      epeg_size_get(im, &w, &h);
  
***************
*** 68,75 ****
  
      epeg_decode_size_set(im, dest_w, dest_h);
!     epeg_quality_set(im, 80);
      epeg_thumbnail_comments_enable(im, 1);
  
      epeg_file_output_set(im, dest);
      epeg_close(im);
  
--- 70,82 ----
  
      epeg_decode_size_set(im, dest_w, dest_h);
!     epeg_quality_set(im, 100);
      epeg_thumbnail_comments_enable(im, 1);
  
      epeg_file_output_set(im, dest);
+     if(epeg_encode (im)) {
+         epeg_close(im);
+         PyErr_SetString(PyExc_IOError, "unable to encode image");
+       return NULL;
+     }
      epeg_close(im);
  



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to