Subgroup: other
Class: QgsBlurEffect¶
-
class
qgis.core.
QgsBlurEffect
¶ Bases:
qgis._core.QgsPaintEffect
A paint effect which blurs a source picture, using a number of different blur methods.
New in version 2.9: Methods
begin
Begins intercepting paint operations to a render context. blendMode
Returns the blend mode for the effect blurLevel
Returns the blur level (strength) blurMethod
Returns the blur method (algorithm) used for performing the blur. boundingRect
clone
create
Creates a new QgsBlurEffect effect from a properties string map. draw
drawMode
Returns the draw mode for the effect. drawSource
enabled
Returns whether the effect is enabled end
Ends interception of paint operations to a render context, and draws the result to the render context after being modified by the effect. fixQPictureDpi
imageOffset
opacity
Returns the opacity for the effect. properties
readProperties
render
Renders a picture using the effect. saveProperties
Saves the current state of the effect to a DOM element. setBlendMode
Sets the blend mode for the effect setBlurLevel
Sets blur level (strength) setBlurMethod
Sets the blur method (algorithm) to use for performing the blur. setDrawMode
Sets the draw mode for the effect. setEnabled
Sets whether the effect is enabled setOpacity
Sets the opacity
for the effect.source
sourceAsImage
type
Attributes
GaussianBlur
Modifier
ModifyAndRender
Render
StackBlur
-
class
BlurMethod
¶ Bases:
int
-
GaussianBlur
= 1¶
-
StackBlur
= 0¶
-
blendMode
(self) → QPainter.CompositionMode¶ Returns the blend mode for the effect
Returns: blend mode used for drawing the effect on to a destination paint device
See also
-
blurLevel
(self) → int¶ Returns the blur level (strength)
Returns: blur level. Depending on the current blurMethod(), this parameter has different effects
See also
See also
-
blurMethod
(self) → QgsBlurEffect.BlurMethod¶ Returns the blur method (algorithm) used for performing the blur.
Returns: blur method See also
-
boundingRect
(self, rect: QRectF, context: QgsRenderContext) → QRectF¶
-
clone
(self) → QgsBlurEffect¶
-
create
(map: Dict[str, str]) → QgsPaintEffect¶ Creates a new QgsBlurEffect effect from a properties string map.
Parameters: map – encoded properties string map Returns: new QgsBlurEffect
-
draw
(self, context: QgsRenderContext)¶
-
drawSource
()¶
-
fixQPictureDpi
()¶
-
imageOffset
()¶
-
opacity
(self) → float¶ Returns the opacity for the effect.
Returns: opacity value between 0 and 1 inclusive, where 0 is fully transparent and 1 is fully opaque
See also
-
properties
(self) → Dict[str, str]¶
-
readProperties
(self, props: Dict[str, str])¶
-
setBlendMode
(self, mode: QPainter.CompositionMode)¶ Sets the blend mode for the effect
Parameters: mode – blend mode used for drawing the effect on to a destination paint device
See also
-
setBlurLevel
(self, level: int)¶ Sets blur level (strength)
Parameters: level – blur level. Depending on the current blurMethod(), this parameter has different effects
See also
See also
-
setBlurMethod
(self, method: QgsBlurEffect.BlurMethod)¶ Sets the blur method (algorithm) to use for performing the blur.
Parameters: method – blur method See also
-
setOpacity
(self, opacity: float)¶ Sets the
opacity
for the effect.Parameters: opacity – double between 0 and 1 inclusive, where 0 is fully transparent and 1 is fully opaque
See also
-
source
()¶
-
sourceAsImage
()¶
-
type
(self) → str¶
-
class