Skip to content

Commit 76cd9ba

Browse files
committed
v.1.5.7
* Blend GLSL filter * automatic threshold pass threshold as meta * GLSL support dimensions changing during run
1 parent 72e5342 commit 76cd9ba

14 files changed

+642
-121
lines changed

api-reference.md

+13-10
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ new FILTER.BlendFilter(blendMatrix:Array);
709709

710710
The filter blends multiple images together with svg-like blending modes using a `blendMatrix` that is a (flat) array of rows (each row having `4` items, total = `4N` for `N` images) describing the `blendMode`, start `x,y` positions and `enabled` flag for each of the blend images to be blended with the main image (see below).
711711

712-
**Blend Filter is not implemented in GLSL**
712+
**NEW Blend Filter supports WebGL**
713713

714714
**Supported Blend Modes:**
715715

@@ -734,19 +734,24 @@ The filter blends multiple images together with svg-like blending modes using a
734734
In order to use a blend filter do the following:
735735

736736
````javascript
737-
/* blendMode, startX, startY, enabled, .. */
738-
var blend3Images = new FILTER.BlendFilter(["screen", 0, 0, 1,/*input1*/
739-
"overlay", 10, 10, 1 /*input2*/]).setInput(1, blendImg).setInput(2, anotherBlendImg);
740-
// this also works
741-
var blend3Images = FILTER.BlendFilter.setInput(1, blendImg).setInput(2, anotherBlendImg).set(["screen", 0, 0, 1,
742-
"overlay", 10, 10, 1]);
737+
var blend3Images = FILTER.BlendFilter([
738+
/* blendMode, startX, startY, enabled */
739+
"screen", 0, 0, 1, /*input1*/
740+
"overlay", 10, 10, 1 /*input2*/
741+
])
742+
.setInput(1, blendImg) /*input1*/
743+
.setInput(2, anotherBlendImg) /*input2*/
744+
;
743745

744746
// if you want to make this filter work in another thread in parallel through a worker, do:
745747
blend3Images.worker();
746748

747749
// if you want to stop and dispose the worker for this filter, do:
748750
blend3Images.worker(false);
749751

752+
// if you want to make this filter work in webgl do:
753+
blend3Images.makeGLSL(true);
754+
750755
// this is same even if filter uses a parallel worker filter
751756
blend3Images.apply(image); // image is a FILTER.Image instance, see examples
752757
// this will also work:
@@ -768,8 +773,6 @@ if `mode` is `"scale"`, `a` is new width or zero, `b` is new height or zero, `c`
768773

769774
If complicated cropping, padding and scaling is needed use multiple Dimension Filters.
770775

771-
**Dimension Filter is not implemented in GLSL**
772-
773776

774777
### Composite Filter
775778

@@ -911,7 +914,7 @@ Included Plugins support parallel thread/worker filters (see code and examples)
911914
<tbody>
912915
<tr><td>Noise</td> <td>generate uniform noise</td></tr>
913916
<tr><td>PerlinNoise</td> <td>generate perlin noise</td></tr>
914-
<tr><td>Threshold</td> <td>Automatic Threshold (Otsu method)</td></tr>
917+
<tr><td>Threshold</td> <td>automatic threshold (Otsu method)</td></tr>
915918
<tr><td>HistogramEqualize</td> <td>apply fast histogram equalization (intensity-based, grayscale-based or per separate rgb channel)</td></tr>
916919
<tr><td>Pixelate</td> <td>fast pixelate the image to the given scale using various patterns<br />"rectangular" (default)<br />"triangular"<br />"rhomboidal"<br />"hexagonal"<br><b>supports WebGL</b></td></tr>
917920
<tr><td>Halftone</td> <td>create a halftone/dithered black-white or colored image from target image</td></tr>

beeld.config

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ tasks =[{}]
7575
# Text replacements
7676
replace =[{}]
7777

78-
"@@VERSION@@" = "1.5.6"
78+
"@@VERSION@@" = "1.5.7"
7979
"@@DATE@@" = Xpresion::date("Y-m-d H:i:s")
8080

8181
@

0 commit comments

Comments
 (0)