-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add SwiftPackageIndex configueration file
- Loading branch information
Showing
11 changed files
with
140 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
version: 1 | ||
builder: | ||
configs: | ||
- documentation_targets: [Target1, Target2] | ||
platform: ios |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
Sources/VariableBlurImageView/Documentation.docc/Documentation.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# ``VariableBlurImageView`` | ||
|
||
Add variable blur to images on iOS and MacCatalyst. Works with UIKit using Metal. | ||
|
||
## Overview | ||
|
||
This frameworks provides an UIImageView subclass and a class to apply variable blur to CGImages. | ||
|
||
![iOS app with a vertical variable blur from the top to the middle](iOSAppDemo1.png) | ||
|
||
#### Vertical | ||
![Vertical progressive blur](VariableBlurTestImage-VerticalBlur.png) | ||
|
||
#### Horizontal | ||
![Horizontal progressive blur](VariableBlurTestImage-HorizontalBlur.png) | ||
|
||
#### Between two points | ||
![Progressive blur between two points](VariableBlurTestImage-VariableBlur.png) | ||
|
||
## Topics | ||
|
||
### Variable blur ImageView | ||
|
||
- ``VariableBlurImageView/VariableBlurImageView/variableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurImageView/VariableBlurImageView/verticalVariableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurImageView/VariableBlurImageView/horizontalVariableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` | ||
|
||
### Applying variable blur to images | ||
|
||
- ``VariableBlurEngine/applyVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurEngine/applyVerticalVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurEngine/applyHorizontalVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` |
Binary file added
BIN
+156 KB
...ImageView/Documentation.docc/Resources/VariableBlurTestImage-HorizontalBlur.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+160 KB
...urImageView/Documentation.docc/Resources/VariableBlurTestImage-VariableBlur.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+146 KB
...urImageView/Documentation.docc/Resources/VariableBlurTestImage-VerticalBlur.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+131 KB
Sources/VariableBlurImageView/Documentation.docc/Resources/iOSAppDemo1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions
27
Sources/VariableBlurImageView/Documentation.docc/VariableBlurEngine.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# ``VariableBlurImageView/VariableBlurEngine`` | ||
|
||
Apply variable blur to CGImages. | ||
|
||
## Overview | ||
|
||
You provide a CGImage, start point, end point, and their respective blur radiuses. A new CGImage is returned with the variable blur effect. | ||
|
||
### Example | ||
|
||
```swift | ||
let variableBlurEngine = VariableBlurEngine() | ||
let leavesImage = UIImage(resource: .leaves) | ||
let blurredImage = variableBlurEngine.applyVerticalVariableBlur( | ||
toImage: leavesImage, | ||
startPoint: 0, | ||
endPoint: leavesImage.size.height / 4, | ||
startRadius: 15, | ||
endRadius: 0 | ||
) | ||
``` | ||
|
||
## Topics | ||
|
||
- ``VariableBlurEngine/applyVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurEngine/applyVerticalVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurEngine/applyHorizontalVariableBlur(toImage:startPoint:endPoint:startRadius:endRadius:)`` |
28 changes: 28 additions & 0 deletions
28
Sources/VariableBlurImageView/Documentation.docc/VariableBlurImageView.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# ``VariableBlurImageView/VariableBlurImageView`` | ||
|
||
Subclass of `UIImageView` which asynchronously applies the wanted progressive blur. | ||
|
||
## Overview | ||
|
||
You provide an image, start point, end point, and their respective blur radiuses. | ||
|
||
### Example | ||
|
||
```swift | ||
let imageView = VariableBlurImageView() | ||
imageView.contentMode = .scaleAspectFill | ||
let backgroundImage = UIImage(resource: .onboardingBackground) | ||
imageView.verticalVariableBlur( | ||
image: backgroundImage, | ||
startPoint: 0, | ||
endPoint: backgroundImage.size.height / 4, | ||
startRadius: 15, | ||
endRadius: 0 | ||
) | ||
``` | ||
|
||
## Topics | ||
|
||
- ``VariableBlurImageView/VariableBlurImageView/variableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurImageView/VariableBlurImageView/verticalVariableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` | ||
- ``VariableBlurImageView/VariableBlurImageView/horizontalVariableBlur(image:startPoint:endPoint:startRadius:endRadius:)`` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters