; The GIMP -- an image manipulation program ; Copyright (C) 1995 Spencer Kimball and Peter Mattis ; ; Remove red eyes from photographs for GIMP 1.2 ; Copyright (C) 2003 mpro ; -------------------------------------------------------------------- ; ; version 0.1 by mpro 2003/11/29 ; - Initial relase ; -------------------------------------------------------------------- ; ; This program is free software; you can redistribute it and/or modify ; it under the terms of the GNU General Public License as published by ; the Free Software Foundation; either version 2 of the License, or ; (at your option) any later version. ; ; This program is distributed in the hope that it will be useful, ; but WITHOUT ANY WARRANTY; without even the implied warranty of ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ; GNU General Public License for more details. ; ; You should have received a copy of the GNU General Public License ; along with this program; if not, write to the Free Software ; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. (define (script-fu-red-eyes image drawable ShrinkSelection FeatherSelection GrayLevel ) (gimp-undo-push-group-start image) (gimp-desaturate drawable) (gimp-selection-shrink image ShrinkSelection) (gimp-selection-feather image FeatherSelection) (gimp-levels drawable 0 0 255 GrayLevel 0 255) (gimp-selection-none image) (gimp-undo-push-group-end image) (gimp-displays-flush) ) ; Register the function with the GIMP: ; ------------------------------------ (script-fu-register "script-fu-red-eyes" _"/Script-Fu/Color/Red eye..." "Remove red eye from photographs shot with flash." "mpro " "mpro" "2003, Nov" "RGB*" SF-IMAGE "Image" 0 SF-DRAWABLE "Drawable" 0 SF-ADJUSTMENT _"Shrink Selection for Level" '( 2 0 30 1 10 0 1) SF-ADJUSTMENT _"Feather Selection for Level" '( 2 0 30 1 10 0 1) SF-ADJUSTMENT _"Set Gray Point Level" '( 0.6 0 1 0.05 10 2 0) ) ;---end of file red_eye.scm---