mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 04:57:00 -04:00
Added saturate script function (+documentation), it also desaturates
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@800 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
@@ -67,7 +67,8 @@ These functions are built into the program, other [[type:function]]s can be defi
|
||||
| [[fun:combine_blend]] Blend two images together using a given [[type:combine|combining mode]].
|
||||
| [[fun:set_mask]] Set the transparancy mask of an image.
|
||||
| [[fun:set_alpha]] Change the transparency of an image.
|
||||
| [[fun:set_combine]] Chnage how the image should be combined with the background.
|
||||
| [[fun:set_combine]] Change how the image should be combined with the background.
|
||||
| [[fun:saturate]] Saturate/desaturate an image.
|
||||
| [[fun:enlarge]] Enlarge an image by putting a border around it.
|
||||
| [[fun:crop]] Crop an image, giving only a small subset of it.
|
||||
| [[fun:drop_shadow]] Add a drop shadow to an image.
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
Function: saturate
|
||||
|
||||
--Usage--
|
||||
> saturate(input: image, amount: saturation amount)
|
||||
|
||||
Saturate or desaturate an image. Saturation makes the colors brighter, desaturation makes the image more grey.
|
||||
|
||||
To saturate use an amount between @0@ (no saturation) and @1@ (super crazy, too much saturation).
|
||||
|
||||
To desaturate use an amount between @0@ (no desaturation) and @-1@ (convert to greyscale).
|
||||
|
||||
--Parameters--
|
||||
! Parameter Type Description
|
||||
| @input@ [[type:image]] Image to (de)saturate.
|
||||
| @alpha@ [[type:double]] Saturation factor.
|
||||
|
||||
--Examples--
|
||||
> saturate("image5.png", amount: 0.5) == [[Image]]
|
||||
>>> saturate(<img src="image5.png" alt='"image5.png"' style="border:1px solid black;vertical-align:middle;margin:1px;" />, amount: 0.5) == <img src="image_saturate1.png" alt='"image_saturate1.png"' style="border:1px solid black;vertical-align:middle;margin:1px;" />
|
||||
> saturate("image5.png", amount: -0.5) == [[Image]]
|
||||
>>> saturate(<img src="image5.png" alt='"image5.png"' style="border:1px solid black;vertical-align:middle;margin:1px;" />, amount: -0.5) == <img src="image_saturate2.png" alt='"image_saturate2.png"' style="border:1px solid black;vertical-align:middle;margin:1px;" />
|
||||
Reference in New Issue
Block a user