Polarized |
Original |
This will add a digital polarizing filter effect:
Here is the code -->
;***************************************************************************************
; Polarize script for GIMP 2.x
; --------------------------------------------------------------------
(define (script-fu-polarize
img
drawable
)
(gimp-undo-push-group-start img)
(let* (
(new-img (car (plug-in-decompose 1 img drawable "Red" 1)))
(new-layer (car (gimp-image-get-active-layer new-img)))
(TEMP0 (car (gimp-layer-copy drawable FALSE)))
(TEMP1 (car (gimp-layer-copy drawable FALSE)))
)
(gimp-image-add-layer img TEMP1 -1)
(gimp-image-add-layer img TEMP0 -1)
(gimp-edit-copy new-layer)
(gimp-floating-sel-anchor (car (gimp-edit-paste TEMP0 0)))
(gimp-layer-set-mode TEMP0 SOFTLIGHT-MODE)
(gimp-image-merge-down img TEMP0 EXPAND-AS-NECESSARY)
(set! TEMP0 (car (gimp-image-get-active-layer img)))
(gimp-layer-set-name TEMP0 "Polarize")
(gimp-image-delete new-img)
(gimp-undo-push-group-end img)
(gimp-displays-flush)
)
)
(script-fu-register
"script-fu-polarize"
_"<Image>/Script-Fu/Artistic/Polarize"
"Creates a Polarize filter Effect."
""
""
"2011"
"RGB*"
SF-IMAGE "Image" 0
SF-DRAWABLE "Drawable" 0
)
Looks just what I want. I'm not too familiar with this scripting language. Is it possible to perform this filtering effect through the gui?
ReplyDeleteError: eval: unbound variable: img
ReplyDelete