summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorMarko Niemelä <marko.a.niemela@nokia.com>2012-01-04 13:19:08 +0200
committerMarko Niemelä <marko.a.niemela@nokia.com>2012-01-04 13:19:08 +0200
commit51a0b0a9dc23b74357fa4698c58b44e0d6e36b3c (patch)
tree6896ff5f09288adf17fe033677e41c12714e02bf /doc
parent21918253460df39f8c1665648656b49d6729f5de (diff)
downloadqtgraphicaleffects-51a0b0a9dc23b74357fa4698c58b44e0d6e36b3c.tar.gz
Added LevelAdjust effect
Diffstat (limited to 'doc')
-rw-r--r--doc/src/images/LevelAdjust_butterfly.pngbin0 -> 18101 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_default_curve.pngbin0 -> 11478 bytes
-rw-r--r--doc/src/images/LevelAdjust_gamma1.pngbin0 -> 22502 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_gamma1_curve.pngbin0 -> 11478 bytes
-rw-r--r--doc/src/images/LevelAdjust_gamma2.pngbin0 -> 22179 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_gamma2_curve.pngbin0 -> 21388 bytes
-rw-r--r--doc/src/images/LevelAdjust_gamma3.pngbin0 -> 19273 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_gamma3_curve.pngbin0 -> 19752 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumInput1.pngbin0 -> 20946 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumInput2.pngbin0 -> 19353 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_maximumInput2_curve.pngbin0 -> 15189 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumInput3.pngbin0 -> 18810 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_maximumInput3_curve.pngbin0 -> 14310 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumOutput1.pngbin0 -> 20946 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumOutput2.pngbin0 -> 20571 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_maximumOutput2_curve.pngbin0 -> 15427 bytes
-rw-r--r--doc/src/images/LevelAdjust_maximumOutput3.pngbin0 -> 20152 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_maximumOutput3_curve.pngbin0 -> 14296 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumInput1.pngbin0 -> 20946 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumInput2.pngbin0 -> 21299 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_minimumInput2_curve.pngbin0 -> 15919 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumInput3.pngbin0 -> 21174 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_minimumInput3_curve.pngbin0 -> 15655 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumOutput1.pngbin0 -> 20946 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumOutput2.pngbin0 -> 20625 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_minimumOutput2_curve.pngbin0 -> 15679 bytes
-rw-r--r--doc/src/images/LevelAdjust_minimumOutput3.pngbin0 -> 20248 bytes
-rwxr-xr-xdoc/src/images/LevelAdjust_minimumOutput3_curve.pngbin0 -> 15106 bytes
-rw-r--r--doc/src/qtgraphicaleffects-leveladjust.qdoc414
-rw-r--r--doc/src/qtgraphicaleffects.qdoc3
-rw-r--r--doc/src/snippets/LevelAdjust-example.qml64
31 files changed, 480 insertions, 1 deletions
diff --git a/doc/src/images/LevelAdjust_butterfly.png b/doc/src/images/LevelAdjust_butterfly.png
new file mode 100644
index 0000000..2090bac
--- /dev/null
+++ b/doc/src/images/LevelAdjust_butterfly.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_default_curve.png b/doc/src/images/LevelAdjust_default_curve.png
new file mode 100755
index 0000000..4e98cc4
--- /dev/null
+++ b/doc/src/images/LevelAdjust_default_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma1.png b/doc/src/images/LevelAdjust_gamma1.png
new file mode 100644
index 0000000..83475bf
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma1.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma1_curve.png b/doc/src/images/LevelAdjust_gamma1_curve.png
new file mode 100755
index 0000000..a8434d9
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma1_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma2.png b/doc/src/images/LevelAdjust_gamma2.png
new file mode 100644
index 0000000..1f968a5
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma2.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma2_curve.png b/doc/src/images/LevelAdjust_gamma2_curve.png
new file mode 100755
index 0000000..3fd61b5
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma2_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma3.png b/doc/src/images/LevelAdjust_gamma3.png
new file mode 100644
index 0000000..d656513
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma3.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_gamma3_curve.png b/doc/src/images/LevelAdjust_gamma3_curve.png
new file mode 100755
index 0000000..90d3e92
--- /dev/null
+++ b/doc/src/images/LevelAdjust_gamma3_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumInput1.png b/doc/src/images/LevelAdjust_maximumInput1.png
new file mode 100644
index 0000000..ac3d2aa
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumInput1.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumInput2.png b/doc/src/images/LevelAdjust_maximumInput2.png
new file mode 100644
index 0000000..59ab858
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumInput2.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumInput2_curve.png b/doc/src/images/LevelAdjust_maximumInput2_curve.png
new file mode 100755
index 0000000..669dcd8
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumInput2_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumInput3.png b/doc/src/images/LevelAdjust_maximumInput3.png
new file mode 100644
index 0000000..309f60e
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumInput3.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumInput3_curve.png b/doc/src/images/LevelAdjust_maximumInput3_curve.png
new file mode 100755
index 0000000..7cc4316
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumInput3_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumOutput1.png b/doc/src/images/LevelAdjust_maximumOutput1.png
new file mode 100644
index 0000000..ac3d2aa
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumOutput1.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumOutput2.png b/doc/src/images/LevelAdjust_maximumOutput2.png
new file mode 100644
index 0000000..4c69453
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumOutput2.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumOutput2_curve.png b/doc/src/images/LevelAdjust_maximumOutput2_curve.png
new file mode 100755
index 0000000..467ff1f
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumOutput2_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumOutput3.png b/doc/src/images/LevelAdjust_maximumOutput3.png
new file mode 100644
index 0000000..3039b56
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumOutput3.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_maximumOutput3_curve.png b/doc/src/images/LevelAdjust_maximumOutput3_curve.png
new file mode 100755
index 0000000..c94123b
--- /dev/null
+++ b/doc/src/images/LevelAdjust_maximumOutput3_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumInput1.png b/doc/src/images/LevelAdjust_minimumInput1.png
new file mode 100644
index 0000000..ac3d2aa
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumInput1.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumInput2.png b/doc/src/images/LevelAdjust_minimumInput2.png
new file mode 100644
index 0000000..aa317d0
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumInput2.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumInput2_curve.png b/doc/src/images/LevelAdjust_minimumInput2_curve.png
new file mode 100755
index 0000000..bea83c2
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumInput2_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumInput3.png b/doc/src/images/LevelAdjust_minimumInput3.png
new file mode 100644
index 0000000..be62f73
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumInput3.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumInput3_curve.png b/doc/src/images/LevelAdjust_minimumInput3_curve.png
new file mode 100755
index 0000000..5663a81
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumInput3_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumOutput1.png b/doc/src/images/LevelAdjust_minimumOutput1.png
new file mode 100644
index 0000000..ac3d2aa
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumOutput1.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumOutput2.png b/doc/src/images/LevelAdjust_minimumOutput2.png
new file mode 100644
index 0000000..6124df1
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumOutput2.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumOutput2_curve.png b/doc/src/images/LevelAdjust_minimumOutput2_curve.png
new file mode 100755
index 0000000..f0e6b09
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumOutput2_curve.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumOutput3.png b/doc/src/images/LevelAdjust_minimumOutput3.png
new file mode 100644
index 0000000..43fe2b7
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumOutput3.png
Binary files differ
diff --git a/doc/src/images/LevelAdjust_minimumOutput3_curve.png b/doc/src/images/LevelAdjust_minimumOutput3_curve.png
new file mode 100755
index 0000000..26c9211
--- /dev/null
+++ b/doc/src/images/LevelAdjust_minimumOutput3_curve.png
Binary files differ
diff --git a/doc/src/qtgraphicaleffects-leveladjust.qdoc b/doc/src/qtgraphicaleffects-leveladjust.qdoc
new file mode 100644
index 0000000..41e8c60
--- /dev/null
+++ b/doc/src/qtgraphicaleffects-leveladjust.qdoc
@@ -0,0 +1,414 @@
+/****************************************************************************
+**
+** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the documentation of the Qt Graphical Effects module.
+**
+** $QT_BEGIN_LICENSE:FDL$
+** GNU Free Documentation License
+** Alternatively, this file may be used under the terms of the GNU Free
+** Documentation License version 1.3 as published by the Free Software
+** Foundation and appearing in the file included in the packaging of
+** this file.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms
+** and conditions contained in a signed written agreement between you
+** and Nokia.
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/*!
+ \qmlclass LevelAdjust
+ \inqmlmodule QtGraphicalEffects
+ \brief Adjusts color levels in the RGBA color space.
+
+ This effect adjusts the source item colors separately for each color channel.
+ Source item contrast can be adjusted and color balance altered.
+
+ \table
+ \header
+ \o Source
+ \o Effect applied
+ \row
+ \o \image Original_butterfly.png
+ \o \image LevelAdjust_butterfly.png
+ \endtable
+
+ \section1 Example
+
+ The following example shows how to apply the effect.
+ \snippet snippets/LevelAdjust-example.qml example
+ \section1 Memory Consumption
+
+ The internal memory consumption is small.
+ If source item is not Image or ShaderEffectSource, then effect internally creates one ShaderEffectSource item per source.
+ The ShaderEffectSource memory consumption is approximately the same as the memory consumption of the the
+ source item area in pixels. Enabling the effect cache increases the memory
+ consumption.
+
+ \table
+ \header
+ \o Estimated memory usage for an effect with a size of 640x480 pixels with 32 bits per pixel (bpp)
+ \o
+ \row
+ \o Effect internal
+ \o 0 MB
+ \row
+ \o ShaderEffectSource (if used)
+ \o 1.2 MB
+ \row
+ \o Effect internal cache (if enabled)
+ \o 1.2 MB
+ \row
+ \o TOTAL (max)
+ \o 2.4 MB
+ \endtable
+
+*/
+
+/*!
+ \qmlproperty variant QtGraphicalEffects::LevelAdjust::source
+
+ This property defines the source item that provides the source pixels for
+ the effect.
+
+*/
+
+/*!
+ \qmlproperty color QtGraphicalEffects::LevelAdjust::minimumInput
+
+ This property defines the minimum input level for each color channel. It sets
+ the black-point, all pixels having lower value than this property are rendered
+ as black (per color channel). Increasing the value darkens the dark areas.
+
+ The value ranges from "#00000000" to "#ffffffff". By default, the property
+ is set to \c "#00000000" (no change).
+
+ \table
+ \header
+ \o Output examples with different minimumInput values
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_minimumInput1.png
+ \o \image LevelAdjust_minimumInput2.png
+ \o \image LevelAdjust_minimumInput3.png
+ \row
+ \o \bold { minimumInput: #00000000 }
+ \o \bold { minimumInput: #00000040 }
+ \o \bold { minimumInput: #00000070 }
+ \row
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \row
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \row
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \row
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \endtable
+
+ \table
+ \header
+ \o Pixel color channel luminance curves of the above images.
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_default_curve.png
+ \o \image LevelAdjust_minimumInput2_curve.png
+ \o \image LevelAdjust_minimumInput3_curve.png
+ \row
+ \o X-axis: pixel original luminance
+ \o
+ \o
+ \row
+ \o Y-axis: color channel luminance with effect applied
+ \o
+ \o
+ \endtable
+
+*/
+
+/*!
+ \qmlproperty color QtGraphicalEffects::LevelAdjust::maximumInput
+
+ This property defines the maximum input level for each color channel.
+ It sets the white-point, all pixels having higher value than this
+ property are rendered as white (per color channel).
+ Decreasing the value lightens the light areas.
+
+ The value ranges from "#ffffffff" to "#00000000". By default, the property
+ is set to \c "#ffffffff" (no change).
+
+ \table
+ \header
+ \o Output examples with different maximumInput values
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_maximumInput1.png
+ \o \image LevelAdjust_maximumInput2.png
+ \o \image LevelAdjust_maximumInput3.png
+ \row
+ \o \bold { maximumInput: #FFFFFFFF }
+ \o \bold { maximumInput: #FFFFFF80 }
+ \o \bold { maximumInput: #FFFFFF30 }
+ \row
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \row
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \row
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \row
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \endtable
+
+ \table
+ \header
+ \o Pixel color channel luminance curves of the above images.
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_default_curve.png
+ \o \image LevelAdjust_maximumInput2_curve.png
+ \o \image LevelAdjust_maximumInput3_curve.png
+ \row
+ \o X-axis: pixel original luminance
+ \o
+ \o
+ \row
+ \o Y-axis: color channel luminance with effect applied
+ \o
+ \o
+ \endtable
+
+*/
+
+/*!
+ \qmlproperty color QtGraphicalEffects::LevelAdjust::minimumOutput
+
+ This property defines the minimum output level for each color channel.
+ Increasing the value lightens the dark areas, reducing the contrast.
+
+ The value ranges from "#00000000" to "#ffffffff". By default, the property
+ is set to \c "#00000000" (no change).
+
+ \table
+ \header
+ \o Output examples with different minimumOutput values
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_minimumOutput1.png
+ \o \image LevelAdjust_minimumOutput2.png
+ \o \image LevelAdjust_minimumOutput3.png
+ \row
+ \o \bold { minimumOutput: #00000000 }
+ \o \bold { minimumOutput: #00000070 }
+ \o \bold { minimumOutput: #000000A0 }
+ \row
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \row
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \row
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \row
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \endtable
+
+ \table
+ \header
+ \o Pixel color channel luminance curves of the above images.
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_default_curve.png
+ \o \image LevelAdjust_minimumOutput2_curve.png
+ \o \image LevelAdjust_minimumOutput3_curve.png
+ \row
+ \o X-axis: pixel original luminance
+ \o
+ \o
+ \row
+ \o Y-axis: color channel luminance with effect applied
+ \o
+ \o
+ \endtable
+
+*/
+
+/*!
+ \qmlproperty color QtGraphicalEffects::LevelAdjust::maximumOutput
+
+ This property defines the maximum output level for each color channel.
+ Decreasing the value darkens the light areas, reducing the contrast.
+
+ The value ranges from "#ffffffff" to "#00000000". By default, the property
+ is set to \c "#ffffffff" (no change).
+
+ \table
+ \header
+ \o Output examples with different maximumOutput values
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_maximumOutput1.png
+ \o \image LevelAdjust_maximumOutput2.png
+ \o \image LevelAdjust_maximumOutput3.png
+ \row
+ \o \bold { maximumOutput: #FFFFFFFF }
+ \o \bold { maximumOutput: #FFFFFF80 }
+ \o \bold { maximumOutput: #FFFFFF30 }
+ \row
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \row
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \row
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \row
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \o \l gamma: Qt.vector3d(1.0, 1.0, 1.0)
+ \endtable
+
+ \table
+ \header
+ \o Pixel color channel luminance curves of the above images.
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_default_curve.png
+ \o \image LevelAdjust_maximumOutput2_curve.png
+ \o \image LevelAdjust_maximumOutput3_curve.png
+ \row
+ \o X-axis: pixel original luminance
+ \o
+ \o
+ \row
+ \o Y-axis: color channel luminance with effect applied
+ \o
+ \o
+ \endtable
+
+
+*/
+
+/*!
+ \qmlproperty variant QtGraphicalEffects::LevelAdjust::gamma
+
+ This property defines the change factor for how the value of each pixel
+ color channel is altered according to the equation:
+
+ \code result.rgb = pow(original.rgb, 1.0 / gamma.rgb); \endcode
+
+ Setting the gamma values under QtVector3d(1.0, 1.0, 1.0) makes the image darker, the values
+ above QtVector3d(1.0, 1.0, 1.0) lighten it.
+
+ The value ranges from QtVector3d(0.0, 0.0, 0.0) (darkest) to inf (lightest). By default, the property
+ is set to \c QtVector3d(1.0, 1.0, 1.0) (no change).
+
+ \table
+ \header
+ \o Output examples with different gamma values
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_gamma1.png
+ \o \image LevelAdjust_gamma2.png
+ \o \image LevelAdjust_gamma3.png
+ \row
+ \o \bold { gamma: Qt.vector3d(1.0, 1.0, 1.0) }
+ \o \bold { gamma: Qt.vector3d(1.0, 0.4, 2.0) }
+ \o \bold { gamma: Qt.vector3d(1.0, 0.1, 4.0) }
+ \row
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \o \l minimumInput: #000000
+ \row
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \o \l maximumInput: #ffffff
+ \row
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \o \l minimumOutput: #000000
+ \row
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \o \l maximumOutput: #ffffff
+ \endtable
+
+ \table
+ \header
+ \o Pixel color channel luminance curves of the above images.
+ \o
+ \o
+ \row
+ \o \image LevelAdjust_default_curve.png
+ \o \image LevelAdjust_gamma2_curve.png
+ \o \image LevelAdjust_gamma3_curve.png
+ \row
+ \o X-axis: pixel original luminance
+ \o
+ \o
+ \row
+ \o Y-axis: color channel luminance with effect applied
+ \o
+ \o
+ \endtable
+
+*/
+
+/*!
+ \qmlproperty bool QtGraphicalEffects::LevelAdjust::cached
+
+ This property allows the effect output pixels to be cached in order to
+ improve the rendering performance.
+
+ Every time the source or effect properties are changed, the pixels in the
+ cache must be updated. Memory consumption is increased, because an extra
+ buffer of memory is required for storing the effect output.
+
+ It is recommended to disable the cache when the source or the effect
+ properties are animated.
+
+ By default, the property is set to \c false.
+
+*/
diff --git a/doc/src/qtgraphicaleffects.qdoc b/doc/src/qtgraphicaleffects.qdoc
index 7e39a92..445938b 100644
--- a/doc/src/qtgraphicaleffects.qdoc
+++ b/doc/src/qtgraphicaleffects.qdoc
@@ -31,7 +31,7 @@
\brief Qt Graphical Effects module is a Qt Quick Add-On module.
The Qt Graphical Effects module provides a set of QML components for building
-visually impressive user interfaces. You can implement the effects inside QML applications with QML and GLSL.
+visually impressive user interfaces. Effects are implemented with QML and GLSL.
\section1 Getting started
Install the Qt Graphical Effects module, and simply add the following import statement to your .qml file:
@@ -54,6 +54,7 @@ Color
\o \l {QtGraphicalEffects::Desaturate}{Desaturate} - reduces color saturation
\o \l {QtGraphicalEffects::GammaAdjust}{GammaAdjust} - adjusts luminance
\o \l {QtGraphicalEffects::HueSaturation}{HueSaturation} - adjusts colors in the HSL color space
+\o \l {QtGraphicalEffects::LevelAdjust}{LevelAdjust} - adjusts colors in the RGB color space
\endlist
Gradient
diff --git a/doc/src/snippets/LevelAdjust-example.qml b/doc/src/snippets/LevelAdjust-example.qml
new file mode 100644
index 0000000..0580745
--- /dev/null
+++ b/doc/src/snippets/LevelAdjust-example.qml
@@ -0,0 +1,64 @@
+/****************************************************************************
+**
+** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the Qt Graphical Effects module.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+//! [example]
+import QtQuick 2.0
+import QtGraphicalEffects 0.1
+
+Item {
+ width: 300
+ height: 300
+
+ Image {
+ id: levelAdjustSourceItem
+ source: "images/butterfly.png"
+ sourceSize: Qt.size(parent.width, parent.height)
+ smooth: true
+ visible: false
+ }
+
+ LevelAdjust {
+ anchors.fill: levelAdjustSourceItem
+ source: levelAdjustSourceItem
+ minimumOutput: "#00000000"
+ maximumOutput: "#FF1010FF"
+ }
+}
+//! [example]