Skip to content

Commit 3c9ddbd

Browse files
committed
pass tile mode per edge
1 parent 31e989a commit 3c9ddbd

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

lib/src/edge_blur.dart

+5
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ class EdgeBlur {
1212
required this.sigma,
1313
required this.controlPoints,
1414
this.tintColor,
15+
this.tileMode =
16+
TileMode.clamp, // Add the tileMode parameter with a default value
1517
});
1618

1719
/// The edge on which the blur will be applied.
@@ -28,4 +30,7 @@ class EdgeBlur {
2830

2931
/// The tint color to be applied to the blur effect.
3032
final Color? tintColor;
33+
34+
/// The tile mode to be used in the blur effect.
35+
final TileMode tileMode;
3136
}

lib/src/soft_edge_blur.dart

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ class SoftEdgeBlur extends StatelessWidget {
7474
..imageFilter = ui.ImageFilter.blur(
7575
sigmaX: edge.sigma,
7676
sigmaY: edge.sigma,
77-
tileMode: TileMode.clamp,
77+
tileMode: edge.tileMode,
7878
);
7979

8080
canvas.drawImage(image, Offset.zero, blurredPaint);

0 commit comments

Comments
 (0)