mirror of
https://github.com/zhigang1992/PerspectiveTransform.git
synced 2026-01-12 17:32:51 +08:00
Merge branch 'xcode10.2'
* xcode10.2: update swift version in readme update pods update travis xcode version update podspec to swift 5.0 use latest iOS and macOS versions for testing migrate to swift 5 fix redudant public migrate to new SIMD and xcode project settings
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
language: swift
|
||||
osx_image: xcode10.1
|
||||
osx_image: xcode10.2
|
||||
xcode_workspace: Example/PerspectiveTransform.xcworkspace
|
||||
xcode_scheme: Example
|
||||
xcode_sdk: iphonesimulator12.1
|
||||
xcode_sdk: iphonesimulator12.2
|
||||
git:
|
||||
depth: 1 # use 1, as false cause travis lint server 500 exception
|
||||
cache:
|
||||
|
||||
@@ -94,6 +94,8 @@
|
||||
4B76EDD7205674CF009492EC /* FittingPolygon.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FittingPolygon.swift; sourceTree = "<group>"; };
|
||||
4B76EDD9205674F3009492EC /* PolygonLoader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PolygonLoader.swift; sourceTree = "<group>"; };
|
||||
4B84138A201DD90D00D17FE2 /* PerspectiveSpec.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PerspectiveSpec.swift; sourceTree = "<group>"; };
|
||||
4B96E125225C8C4600C7E49D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
|
||||
4B96E126225C8C4600C7E49D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = "<group>"; };
|
||||
4B97C3CC2047BAC1004C9782 /* AccelerateSolvePerfTest.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AccelerateSolvePerfTest.swift; sourceTree = "<group>"; };
|
||||
4B9A5BF021FBA91500979AFE /* install-opencv.sh */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; path = "install-opencv.sh"; sourceTree = "<group>"; };
|
||||
4BA3D17A1C771B2E0009B690 /* ProjectionSpec.swift */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 4; lastKnownFileType = sourcecode.swift; path = ProjectionSpec.swift; sourceTree = "<group>"; tabWidth = 4; };
|
||||
@@ -102,8 +104,6 @@
|
||||
4BA3D1871C7995630009B690 /* Visual.playground */ = {isa = PBXFileReference; lastKnownFileType = file.playground; path = Visual.playground; sourceTree = "<group>"; };
|
||||
4BA7B1481C7C7A0600933779 /* .travis.yml */ = {isa = PBXFileReference; indentWidth = 2; lastKnownFileType = text; name = .travis.yml; path = ../.travis.yml; sourceTree = "<group>"; tabWidth = 2; };
|
||||
4BA7B14D1C7D710D00933779 /* ReferenceImages */ = {isa = PBXFileReference; lastKnownFileType = folder; path = ReferenceImages; sourceTree = "<group>"; };
|
||||
4BB87C3B21F468CA00DABAED /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/LaunchScreen.xib; sourceTree = "<group>"; };
|
||||
4BB87C3C21F468CA00DABAED /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/Main.storyboard; sourceTree = "<group>"; };
|
||||
4BCA955E2237A7CE0091E312 /* CATransform3D+MatrixSpec.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "CATransform3D+MatrixSpec.swift"; sourceTree = "<group>"; };
|
||||
4BCA95622237B9880091E312 /* CATransform3D+MatrixPerformanceTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "CATransform3D+MatrixPerformanceTest.swift"; sourceTree = "<group>"; };
|
||||
4BD09EAD2046B05A006D2FA4 /* OpenCV_Spec.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OpenCV_Spec.swift; sourceTree = "<group>"; };
|
||||
@@ -422,33 +422,36 @@
|
||||
isa = PBXProject;
|
||||
attributes = {
|
||||
LastSwiftUpdateCheck = 0920;
|
||||
LastUpgradeCheck = 0940;
|
||||
LastUpgradeCheck = 1020;
|
||||
ORGANIZATIONNAME = CocoaPods;
|
||||
TargetAttributes = {
|
||||
4B74DB33203BD9C70030F41B = {
|
||||
CreatedOnToolsVersion = 9.2;
|
||||
LastSwiftMigration = 1020;
|
||||
};
|
||||
4BDF649A20469AB60022C5F8 = {
|
||||
CreatedOnToolsVersion = 9.2;
|
||||
LastSwiftMigration = 0920;
|
||||
LastSwiftMigration = 1020;
|
||||
ProvisioningStyle = Manual;
|
||||
};
|
||||
607FACCF1AFB9204008FA782 = {
|
||||
CreatedOnToolsVersion = 6.3.1;
|
||||
LastSwiftMigration = 0920;
|
||||
LastSwiftMigration = 1020;
|
||||
};
|
||||
607FACE41AFB9204008FA782 = {
|
||||
CreatedOnToolsVersion = 6.3.1;
|
||||
LastSwiftMigration = 1020;
|
||||
TestTargetID = 607FACCF1AFB9204008FA782;
|
||||
};
|
||||
};
|
||||
};
|
||||
buildConfigurationList = 607FACCB1AFB9204008FA782 /* Build configuration list for PBXProject "PerspectiveTransform" */;
|
||||
compatibilityVersion = "Xcode 8.0";
|
||||
developmentRegion = English;
|
||||
developmentRegion = en;
|
||||
hasScannedForEncodings = 0;
|
||||
knownRegions = (
|
||||
en,
|
||||
Base,
|
||||
);
|
||||
mainGroup = 607FACC71AFB9204008FA782;
|
||||
productRefGroup = 607FACD11AFB9204008FA782 /* Products */;
|
||||
@@ -761,7 +764,7 @@
|
||||
607FACD91AFB9204008FA782 /* Main.storyboard */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
4BB87C3C21F468CA00DABAED /* en */,
|
||||
4B96E125225C8C4600C7E49D /* Base */,
|
||||
);
|
||||
name = Main.storyboard;
|
||||
sourceTree = "<group>";
|
||||
@@ -769,7 +772,7 @@
|
||||
607FACDE1AFB9204008FA782 /* LaunchScreen.xib */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
4BB87C3B21F468CA00DABAED /* en */,
|
||||
4B96E126225C8C4600C7E49D /* Base */,
|
||||
);
|
||||
name = LaunchScreen.xib;
|
||||
sourceTree = "<group>";
|
||||
@@ -784,6 +787,7 @@
|
||||
INFOPLIST_FILE = Specs/Info.plist;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
@@ -794,6 +798,7 @@
|
||||
INFOPLIST_FILE = Specs/Info.plist;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
@@ -814,6 +819,7 @@
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SDKROOT = macosx;
|
||||
SWIFT_OBJC_BRIDGING_HEADER = "OpenCV-OSX-Tests/OpenCVWrapper.h";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
@@ -834,6 +840,7 @@
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SDKROOT = macosx;
|
||||
SWIFT_OBJC_BRIDGING_HEADER = "OpenCV-OSX-Tests/OpenCVWrapper.h";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
@@ -841,6 +848,7 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "compiler-default";
|
||||
@@ -885,8 +893,8 @@
|
||||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.2;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.13;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.14;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
SDKROOT = iphoneos;
|
||||
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
||||
@@ -900,6 +908,7 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "compiler-default";
|
||||
@@ -938,8 +947,8 @@
|
||||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.2;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.13;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 12.2;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.14;
|
||||
SDKROOT = iphoneos;
|
||||
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
|
||||
SWIFT_VERSION = 4.2;
|
||||
@@ -956,6 +965,7 @@
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
@@ -968,6 +978,7 @@
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
@@ -979,6 +990,7 @@
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example";
|
||||
};
|
||||
name = Debug;
|
||||
@@ -991,6 +1003,7 @@
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "paulz.github.io.PerspectiveTransform.$(PRODUCT_NAME:rfc1034identifier)";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
SWIFT_VERSION = 5.0;
|
||||
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example";
|
||||
};
|
||||
name = Release;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Scheme
|
||||
LastUpgradeVersion = "1010"
|
||||
LastUpgradeVersion = "1020"
|
||||
version = "1.3">
|
||||
<BuildAction
|
||||
parallelizeBuildables = "YES"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Scheme
|
||||
LastUpgradeVersion = "1010"
|
||||
LastUpgradeVersion = "1020"
|
||||
version = "1.3">
|
||||
<BuildAction
|
||||
parallelizeBuildables = "YES"
|
||||
|
||||
@@ -2,7 +2,7 @@ import UIKit
|
||||
import QuartzCore
|
||||
|
||||
public extension UIView {
|
||||
public func resetAnchorPoint() {
|
||||
func resetAnchorPoint() {
|
||||
let rect = frame
|
||||
layer.anchorPoint = CGPoint.zero
|
||||
frame = rect
|
||||
|
||||
@@ -2,7 +2,7 @@ import UIKit
|
||||
import QuartzCore
|
||||
|
||||
public extension UIView {
|
||||
public func resetAnchorPoint() {
|
||||
func resetAnchorPoint() {
|
||||
let rect = frame
|
||||
layer.anchorPoint = CGPoint.zero
|
||||
frame = rect
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
source 'https://github.com/CocoaPods/Specs.git'
|
||||
use_frameworks!
|
||||
platform :ios, '11.0'
|
||||
platform :ios, '12.2'
|
||||
|
||||
def DevelopmentPodAndDependencies
|
||||
pod 'PerspectiveTransform', :path => '../'
|
||||
@@ -24,7 +24,7 @@ target 'Example' do
|
||||
end
|
||||
|
||||
target 'OpenCV OSX Tests' do
|
||||
platform :osx, '10.13'
|
||||
platform :osx, '10.14'
|
||||
SwiftTestingPods()
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
PODS:
|
||||
- ImageCoordinateSpace (1.0.7)
|
||||
- ImageCoordinateSpace (1.1)
|
||||
- iOSSnapshotTestCase (6.0.3):
|
||||
- iOSSnapshotTestCase/SwiftSupport (= 6.0.3)
|
||||
- iOSSnapshotTestCase/Core (6.0.3)
|
||||
@@ -11,7 +11,7 @@ PODS:
|
||||
- Nimble-Snapshots/Core (7.0.0):
|
||||
- iOSSnapshotTestCase (~> 6.0)
|
||||
- Nimble (~> 8.0)
|
||||
- PerspectiveTransform (0.4)
|
||||
- PerspectiveTransform (1.0)
|
||||
- Quick (2.0.0)
|
||||
|
||||
DEPENDENCIES:
|
||||
@@ -34,13 +34,13 @@ EXTERNAL SOURCES:
|
||||
:path: "../"
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
ImageCoordinateSpace: 424e76be5db1cbd02a93cb0e97b0d3d46957b454
|
||||
ImageCoordinateSpace: 9e560a43a97375371f22343bb47e2c7e7fc428ae
|
||||
iOSSnapshotTestCase: 944a73f6d9676302811a86c0cf35f0e6ef5ab2a0
|
||||
Nimble: 45f786ae66faa9a709624227fae502db55a8bdd0
|
||||
Nimble-Snapshots: 2d6d712ceb2d1850d88f850fbd7c732618106022
|
||||
PerspectiveTransform: 4e823871c7fde15b776610dbdf102a3b00adb077
|
||||
PerspectiveTransform: 80047e1d02903cb3777f429492514978161a7203
|
||||
Quick: ce1276c7c27ba2da3cb2fd0cde053c3648b3b22d
|
||||
|
||||
PODFILE CHECKSUM: 882ce3558060409e596935d1d06dd5a6707894f9
|
||||
PODFILE CHECKSUM: 80ff60e539c07a49578d282438bd9e678f55ceff
|
||||
|
||||
COCOAPODS: 1.6.1
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Scheme
|
||||
LastUpgradeVersion = "1010"
|
||||
LastUpgradeVersion = "1020"
|
||||
version = "1.3">
|
||||
<BuildAction
|
||||
parallelizeBuildables = "YES"
|
||||
|
||||
@@ -10,10 +10,10 @@ class PerspectiveSpec: QuickSpec {
|
||||
it("should list all vectors") {
|
||||
let perspective = Perspective(.zero)
|
||||
expect(String(describing: perspective)) == "Perspective: [\n"
|
||||
+ "double3(0.0, 0.0, 1.0)\n"
|
||||
+ "double3(0.0, 0.0, 1.0)\n"
|
||||
+ "double3(0.0, 0.0, 1.0)\n"
|
||||
+ "double3(0.0, 0.0, 1.0)\n"
|
||||
+ "SIMD3<Double>(0.0, 0.0, 1.0)\n"
|
||||
+ "SIMD3<Double>(0.0, 0.0, 1.0)\n"
|
||||
+ "SIMD3<Double>(0.0, 0.0, 1.0)\n"
|
||||
+ "SIMD3<Double>(0.0, 0.0, 1.0)\n"
|
||||
+ "]"
|
||||
}
|
||||
}
|
||||
@@ -80,7 +80,7 @@ class PerspectiveSpec: QuickSpec {
|
||||
|
||||
context("pointsToBasisVectorsMap") {
|
||||
it("should result in identity when multiplied by basisVectorsToPointsMap") {
|
||||
let identity = Matrix3x3(diagonal: Vector3(1))
|
||||
let identity = Matrix3x3(diagonal: Vector3(repeating: 1))
|
||||
expect(perspective.basisVectorsToPointsMap * perspective.pointsToBasisVectorsMap) == identity
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
Pod::Spec.new do |s|
|
||||
s.cocoapods_version = '~> 1.5'
|
||||
s.name = 'PerspectiveTransform'
|
||||
s.version = '0.4'
|
||||
s.version = '1.0'
|
||||
s.summary = 'Perspective Transform calculates CATransform3D'
|
||||
s.description = <<-DESC
|
||||
Calculates CATransform3D to transform rectangular frame to convex quadrilateral
|
||||
@@ -14,15 +14,16 @@ Pod::Spec.new do |s|
|
||||
s.author = { 'Paul Zabelin' => authorPage }
|
||||
s.source = { :git => "#{s.homepage}.git", :tag => s.version.to_s }
|
||||
s.social_media_url = 'https://twitter.com/iospaulz'
|
||||
s.platform = :ios, '11.0'
|
||||
s.swift_version = '4.2'
|
||||
s.platform = :ios, '12.2'
|
||||
s.swift_version = '5.0'
|
||||
s.source_files = 'Pod/Classes/**/*'
|
||||
s.frameworks = 'UIKit', 'CoreGraphics', 'QuartzCore'
|
||||
s.test_spec 'UnitSpecs' do |ts|
|
||||
ts.requires_app_host = false
|
||||
ts.source_files = 'Example/Specs/**/*.{h,swift}', 'Example/Tests/*Helper.swift'
|
||||
ts.dependencies = {
|
||||
'Quick' => '~> 1.3',
|
||||
'Nimble' => '~> 7.1'
|
||||
'Quick' => '~> 2.0',
|
||||
'Nimble' => '~> 8.0'
|
||||
}
|
||||
end
|
||||
s.test_spec 'AppSpecs' do |ts|
|
||||
@@ -30,9 +31,9 @@ Pod::Spec.new do |s|
|
||||
ts.resources = 'Example/Tests/**/*.{png,jpg,svg}'
|
||||
ts.source_files = 'Example/Tests/**/*.{h,swift}', 'Example/PerspectiveTransform/resetAnchorPoint.swift'
|
||||
ts.dependencies = {
|
||||
'Quick' => '~> 1.3',
|
||||
'Nimble-Snapshots' => '~> 6.8',
|
||||
'iOSSnapshotTestCase' => '~> 4.0'
|
||||
'Quick' => '~> 2.0',
|
||||
'Nimble-Snapshots' => '~> 7.0',
|
||||
'iOSSnapshotTestCase' => '~> 6.0'
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
@@ -9,9 +9,9 @@
|
||||
import simd
|
||||
|
||||
extension Vector3 {
|
||||
static let one = Vector3(.one)
|
||||
static let zero = Vector3(0)
|
||||
static let lastIndex = Vector3().endIndex - 1
|
||||
static let one = Vector3(repeating: .one)
|
||||
static let zero = Vector3(repeating: 0)
|
||||
static let lastIndex = Vector3().scalarCount - 1
|
||||
static let indexSlice = 0...Vector3.lastIndex
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ public extension Perspective {
|
||||
- parameter bottomLeft: bottom left corner
|
||||
- parameter bottomRight: bottom right corner
|
||||
*/
|
||||
public convenience init(_ topLeft: CGPoint, _ topRight: CGPoint, _ bottomLeft: CGPoint, _ bottomRight: CGPoint) {
|
||||
convenience init(_ topLeft: CGPoint, _ topRight: CGPoint, _ bottomLeft: CGPoint, _ bottomRight: CGPoint) {
|
||||
self.init(.init(topLeft, topRight, bottomLeft, bottomRight))
|
||||
}
|
||||
/**
|
||||
@@ -23,7 +23,7 @@ public extension Perspective {
|
||||
|
||||
- parameter points: corner points, must be size 4
|
||||
*/
|
||||
public convenience init(_ points: [CGPoint]) {
|
||||
convenience init(_ points: [CGPoint]) {
|
||||
self.init(.init(points))
|
||||
}
|
||||
/**
|
||||
@@ -31,7 +31,7 @@ public extension Perspective {
|
||||
|
||||
- parameter rect: defines the corners
|
||||
*/
|
||||
public convenience init(_ rect: CGRect) {
|
||||
convenience init(_ rect: CGRect) {
|
||||
self.init(.init(rect))
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ public extension Perspective {
|
||||
- parameter destination: perspective to transform to
|
||||
- returns: tranformation matrix from this perspective to destination
|
||||
*/
|
||||
public func projectiveTransform(destination: Perspective) -> CATransform3D {
|
||||
func projectiveTransform(destination: Perspective) -> CATransform3D {
|
||||
return .init(projection(to: destination).to3d())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -117,6 +117,6 @@ Paul Zabelin, http://github.com/paulz
|
||||
|
||||
PerspectiveTransform is available under the MIT license. See the LICENSE file for more info.
|
||||
|
||||
[swift-badge]: https://img.shields.io/badge/Swift-4.2-orange.svg?style=flat
|
||||
[swift-badge]: https://img.shields.io/badge/Swift-5.0-orange.svg?style=flat
|
||||
[swift-url]: https://swift.org
|
||||
[carthage-badge]: https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat
|
||||
|
||||
Reference in New Issue
Block a user