Skip to content

Instantly share code, notes, and snippets.

@Sannis
Created October 5, 2010 19:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Sannis/612155 to your computer and use it in GitHub Desktop.
Save Sannis/612155 to your computer and use it in GitHub Desktop.
Gimp script: add saturation and contrast, unsharp image
(define (script-fu-saturation-contrast-unsharp image drawable)
(let*
(
(saturation +20)
(contrast 3)
(unsharp-radius 3)
(unsharp-amount 0.5)
(unsharp-threshold 0)
)
; Start
(gimp-image-undo-group-start image)
(gimp-selection-none image)
; Saturation
(gimp-hue-saturation drawable 0 0 0 saturation)
; Contrast
(gimp-brightness-contrast drawable 0 contrast)
; Unsharp
(plug-in-unsharp-mask 1 image drawable unsharp-radius unsharp-amount unsharp-threshold)
; End
(gimp-image-undo-group-end image)
(gimp-displays-flush)
)
)
(script-fu-register "script-fu-saturation-contrast-unsharp"
"saturation-contrast-unsharp"
"Simple add saturation and contrast; unsharp image"
"Oleg Efimov <efimovov@yandex.ru>"
"Oleg Efimov"
"2010/10/05"
"*"
SF-IMAGE "Image" 0
SF-DRAWABLE "Drawable" 0
)
(script-fu-menu-register "script-fu-saturation-contrast-unsharp"
"<Image>/Filters")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment