This file is indexed.

/usr/share/gimp/2.0/scripts/tissier-diffusion-filter.scm is in gimp-plugin-registry 7.20140602ubuntu2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
;
; The GIMP -- an image manipulation program
; Copyright (C) 1995 Spencer Kimball and Peter Mattis
;
; diffusion filter script  for GIMP 2.4
; Original author: Antoine Tissier
; http://antoine.tissier.lost-oasis.net/gimp/
;
; Tags: effect, filter
;
; Author statement:
;
; This 'script-fu' fakes a diffusion filter.
;
; --------------------------------------------------------------------
; Distributed by Gimp FX Foundry project
; --------------------------------------------------------------------
;   - Changelog -
; Changelog
; 0.2->0.3 :
;    the intensity parameter has been added
;    the layers are now renamed
;    an intensity mask has been added
;    comments added
; 0.1->0.2 :
;     english translation
;     the level parametre has been added
;
; --------------------------------------------------------------------
;
;    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 3 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, see <http://www.gnu.org/licenses/>.
;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


(define (photo-diffusion_filter image drawable levels radius intensity negative)
    (let* (
        (width (car (gimp-image-width image)))
        (height (car (gimp-image-height image)))
        (blur_layer  (car (gimp-image-get-active-layer image)))
        (old_fg_color (car (gimp-context-get-foreground)))
        (old_bg_color (car (gimp-context-get-background)))
        (grey_color (/ (* (abs (- 100 intensity)) 255) 100)))

    (gimp-image-undo-group-start image)

    ;duplication of the background layer
    (gimp-selection-all image)
    (gimp-edit-copy drawable)
    (let ((floating-sel (car (gimp-edit-paste drawable FALSE))))
    (gimp-floating-sel-to-layer floating-sel))

    ;the foreground layer mode is changed
    (let ((orig_layer (car (gimp-image-get-active-layer image))))
    (gimp-drawable-set-name orig_layer _"Original")

    (if (= negative FALSE)
        (gimp-layer-set-mode orig_layer OVERLAY-MODE))

    (if (= negative TRUE)
        (gimp-layer-set-mode orig_layer MULTIPLY-MODE))

    ;duplication of the foreground layer
    (let ((floating-sel (car (gimp-edit-paste drawable FALSE))))
    (gimp-floating-sel-to-layer floating-sel))
    (let ((inte_layer (car (gimp-image-get-active-layer image))))
    (gimp-drawable-set-name inte_layer _"Intensity")
    (gimp-layer-set-mode inte_layer NORMAL-MODE)

    ;creation of the intensity mask
    ;(it is better to create an editable mask than just using opacity )
    (gimp-context-set-background (list grey_color grey_color grey_color))
    (let ((inte_mask (car (gimp-layer-create-mask inte_layer 0))))
    (gimp-layer-add-mask inte_layer inte_mask)
    (gimp-edit-fill inte_mask BACKGROUND-FILL)

    ;the background layer is blurred and brigthened
    (gimp-drawable-set-visible orig_layer FALSE)
    (gimp-drawable-set-visible inte_layer FALSE)
    (gimp-image-set-active-layer image blur_layer)
    (plug-in-gauss-iir2 TRUE image drawable radius radius)
    (gimp-levels drawable 0 0 255 levels 0 255)
    (gimp-drawable-set-name blur_layer _"Blur")

    (gimp-drawable-set-visible orig_layer TRUE)
    (gimp-drawable-set-visible inte_layer TRUE)
    (gimp-context-set-background old_bg_color)
    (gimp-context-set-foreground old_fg_color)
    (gimp-image-undo-group-end image)
    (gimp-displays-flush)))))
)

(script-fu-register "photo-diffusion_filter"
	_"Diffusion filter"
	_"Fakes a diffusion filter"
	"Antoine Tissier"
	"Antoine Tissier"
	"September 2003"
	"RGB RGBA GRAY GRAYA"
	SF-IMAGE	"Image" 0
	SF-DRAWABLE	"Drawable" 0
	SF-ADJUSTMENT	_"Levels" '(1.5  0.1  10   1  10   1   0)
	SF-ADJUSTMENT	_"Radius" '( 15    1 100   1   1   0   0)
	SF-ADJUSTMENT	_"Intensity" '(75  1 100   1   1   0   0)
	SF-TOGGLE	_"Negative" FALSE )

(script-fu-menu-register "photo-diffusion_filter"
                         "<Image>/FX-Foundry/Photo/Effects")