summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPrzemysław R. Pietraszczyk <przem@prymula.ct8.pl>2026-07-25 22:51:52 +0200
committerPrzemysław R. Pietraszczyk <przem@prymula.ct8.pl>2026-07-25 22:51:52 +0200
commit8061c842988aacb3693a30162c4f936c9de1396a (patch)
treee43dab15d50156bdda42c5b73d92ff21f325c6c2
parentb98ad8ec6096e90489a9c91b0d37775d0afd0688 (diff)
2.260725-1
-rw-r--r--script-fu/3.x/przem-apply-waves-effect-v3x.scm23
-rw-r--r--script-fu/changelog.md3
2 files changed, 14 insertions, 12 deletions
diff --git a/script-fu/3.x/przem-apply-waves-effect-v3x.scm b/script-fu/3.x/przem-apply-waves-effect-v3x.scm
index 7ea6ead..1059557 100644
--- a/script-fu/3.x/przem-apply-waves-effect-v3x.scm
+++ b/script-fu/3.x/przem-apply-waves-effect-v3x.scm
@@ -4,19 +4,21 @@
; Gdańsk - 25-02-2025
; ver. 1.260725-0
-(define (przem-apply-waves-effect-v3x image drawable amplitude frequency)
+;(define (przem-apply-waves-effect-v3x image drawable amplitude frequency)
+(define (przem-apply-waves-effect-v3x image drawable)
(let* (
         (width (car (gimp-image-get-width image)))
         (height (car (gimp-image-get-height image)))
         (new-image (car (gimp-image-duplicate image)))
(new-drawable 0)
- ;(brush (car (gimp-brush-new "TQ84 Brush")))
(brush (car (gimp-brush-new "Pixel Brush")))
(resize-y 0)
(resize-x 0)
(y 0)
(x 0)
+ (amplitude 5)
+ (frequency 0.1)
(phase 0)
(counter 0))
(gimp-selection-none new-image)
@@ -24,11 +26,16 @@
    (gimp-context-push)
    (gimp-context-set-defaults)
-    (gimp-context-set-brush brush)
+ (gimp-brush-set-shape brush BRUSH-GENERATED-CIRCLE)
+ (gimp-context-set-paint-method "gimp-paintbrush")
+ (gimp-context-set-paint-mode LAYER-MODE-NORMAL)
+ (gimp-brush-set-radius brush (/ 1 2))
(gimp-context-set-brush-size 1)
- (gimp-context-set-brush-angle 0.0)
+ ;(gimp-context-set-brush-angle 0.0)
(gimp-context-set-brush-hardness 1.0)
(gimp-context-set-opacity 100.0)
+    (gimp-context-set-brush brush)
+
; symulacja
(while (< y height)
@@ -44,7 +51,6 @@
(gimp-image-scale new-image resize-x resize-y)
-    ;(set! new-drawable (car (gimp-drawable-get-visible new-image)))
(set! new-drawable (vector-ref (car (gimp-image-get-selected-layers new-image)) 0))
(set! x 0)
@@ -64,17 +70,12 @@
;(gimp-brushes-refresh)
    (gimp-pencil new-drawable point how-many-points) ; Narysuj punkt
-
- (gimp-message "Wait...")
- ;(display "pixel: ") (displayln pixel)
)
(set! x (+ x 1))
)
(set! x 0)
(set! y (+ y 1))
)
- ;(gimp-image-set-resolution image newdpi newdpi)
-
    (gimp-context-pop)
    (gimp-display-new new-image)
@@ -96,8 +97,6 @@
"2025-02-25"
"RGB*, GRAY*"
SF-ONE-OR-MORE-DRAWABLE
- SF-ADJUSTMENT "Amplitude" '(10 1 100 1 10 0 0)
- SF-ADJUSTMENT "Frequency" '(0.1 0.0 1.0 0.1 0.1 1 0)
)
(script-fu-menu-register "przem-apply-waves-effect-v3x" "<Image>/Filters/PIETRASZCZYK")
diff --git a/script-fu/changelog.md b/script-fu/changelog.md
index 2273453..e849dd4 100644
--- a/script-fu/changelog.md
+++ b/script-fu/changelog.md
@@ -1,3 +1,6 @@
+# [2.260725-1] przem-apply-waves-effect-v3x.scm
+* Nie faluje obrazu
+
# [2.260725-0] przem-apply-waves-effect-v3x.scm
* Próba portu filtra dla Gimpa 3.
* Nie widzi argumentow