All Projects → manuelCarlos → Easing

manuelCarlos / Easing

Licence: mit
Easing functions in Swift 5

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Easing

Containercontroller
UI Component. This is a copy swipe-panel from app: Apple Maps, Stocks. Swift version
Stars: ✭ 273 (+155.14%)
Mutual labels:  xcode, swift-package-manager
Swiftlyext
SwiftlyExt is a collection of useful extensions for Swift 3 standard classes and types 🚀
Stars: ✭ 31 (-71.03%)
Mutual labels:  xcode, swift-package-manager
Swift5 Module Template
An opinionated starting point for awesome, reusable Swift 5 modules
Stars: ✭ 331 (+209.35%)
Mutual labels:  xcode, swift-package-manager
Dtphotoviewercontroller
A fully customizable photo viewer ViewController to display single photo or collection of photos, inspired by Facebook photo viewer.
Stars: ✭ 212 (+98.13%)
Mutual labels:  xcode, swift-package-manager
Loadingshimmer
An easy way to add a shimmering effect to any view with just one line of code. It is useful as an unobtrusive loading indicator.
Stars: ✭ 1,180 (+1002.8%)
Mutual labels:  xcode, swift-package-manager
Dtpagercontroller
A fully customizable container view controller to display a set of ViewControllers in a horizontal scroll view. Written in Swift.
Stars: ✭ 240 (+124.3%)
Mutual labels:  xcode, swift-package-manager
Brisk
A proof of concept scripting library for Swift
Stars: ✭ 478 (+346.73%)
Mutual labels:  xcode, swift-package-manager
Natrium
A pre-build (Swift) script to alter your Xcode project at pre-build-time per environment, build configuration and target.
Stars: ✭ 131 (+22.43%)
Mutual labels:  xcode, swift-package-manager
Mockswift
MockSwift is a Mock library written in Swift.
Stars: ✭ 56 (-47.66%)
Mutual labels:  xcode, swift-package-manager
Xclogparser
Tool to parse Xcode and xcodebuild logs stored in the xcactivitylog format
Stars: ✭ 978 (+814.02%)
Mutual labels:  xcode, swift-package-manager
Carting
🚘 A simple tool for updating Carthage script phase
Stars: ✭ 182 (+70.09%)
Mutual labels:  xcode, swift-package-manager
Statefultabview
A SwiftUI TabView that retains the state of each tab as well as some other goodies.
Stars: ✭ 83 (-22.43%)
Mutual labels:  xcode, swift-package-manager
Cdmarkdownkit
An extensive Swift framework providing simple and customizable markdown parsing.
Stars: ✭ 158 (+47.66%)
Mutual labels:  xcode, swift-package-manager
Roundcode
Custom rounded QR code with lots of customization.
Stars: ✭ 267 (+149.53%)
Mutual labels:  xcode, swift-package-manager
Licenseplist
A license list generator of all your dependencies for iOS applications
Stars: ✭ 1,996 (+1765.42%)
Mutual labels:  xcode, swift-package-manager
Xcbeautify
A little beautifier tool for xcodebuild
Stars: ✭ 372 (+247.66%)
Mutual labels:  xcode, swift-package-manager
Surmagic
🚀 The better way to deal with Binary Frameworks on iOS, Mac Catalyst, tvOS, macOS, and watchOS. Create XCFrameworks with ease.
Stars: ✭ 119 (+11.21%)
Mutual labels:  xcode, swift-package-manager
Swift Xcode
Use Swift Package Manager directly from within Xcode, w/o the cmdline
Stars: ✭ 121 (+13.08%)
Mutual labels:  xcode, swift-package-manager
Bfkit Swift
BFKit-Swift is a collection of useful classes, structs and extensions to develop Apps faster.
Stars: ✭ 963 (+800%)
Mutual labels:  xcode, swift-package-manager
Dtgradientbutton
Easy way to set gradient background to your buttons.
Stars: ✭ 76 (-28.97%)
Mutual labels:  xcode, swift-package-manager

License: MIT release

Easing

A library that implements easing functions in Swift.

Supported platforms:

  • iOS, macOS, tvOS, watchOS and Linux (latest Ubuntu).

Type of supported functions:

  • Quadratic
  • Cubic
  • Quartic
  • Quintic
  • Sine
  • Circular
  • Exponential
  • Elastic
  • Back
  • Bounce

Each type has its own separate ease-In, ease-Out and ease-In-Out form.

The functions are design to accept a generic floating-point input parameter, and return a floating-point, denoting the rate of change of a property over time.

Supported argument types:

  • Any type that conforms to the Real protocol, e.g.
    • Float
    • Float80
    • Double

Usage:

The Curve type allows access to all the different functions, for example:

let x: Float = 0.3
let y = Curve.quadratic.easeIn(x) // y = 0.09
let x: Double = 0.5
let y = Curve.sine.easeOut(x2) // y = 0.7071067811865    

Here's an example of the use of the elastic ease-in-out function in an array of 75 points in the [0, 1] interval.

Installation:

Swift Package Manager (iOS, macOS, tvOS, watchOS and Linux)

Add Easing to your package manifest as a dependency, by adding the github URL to your Package.swift, e.g.:

// swift-tools-version:4.0

import PackageDescription

let package = Package(
   name: "MyAwsomeProject",
   dependencies: [
      .package(url: "https://github.com/manuelCarlos/Easing.git", .upToNextMajor(from: "2.0.0"))
   ],
   targets: [
      .target(
         name: "MyAwsomeProject",
         dependencies: ["Easing"])
   ]
)
  • To quickly generate a Xcode project, navigate to the project folder in the terminal and run:

    swift package generate-xcodeproj

    (In order to generate an Easing.xcodeprojfrom the project's Package.swift, be sure to have the Swift compiler installed and Swift added to your $PATH)

  • To quickly run the tests:

    swift test

    swift test --enable-test-discovery (in Linux).

Dependencies:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].