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
/** | |
@brief Returns true if images have same meta. Width, Height, bit depth. | |
@discussion Assumes images are non null. | |
*/ | |
func doImagesHaveSameMeta(#image1:CGImage, #image2:CGImage) -> Bool { | |
if CGImageGetWidth(image1) != CGImageGetWidth(image2) { | |
return false | |
} | |
if CGImageGetHeight(image1) != CGImageGetHeight(image2) { |
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
// | |
// SimpleScrollingStack.swift | |
// A super-simple demo of a scrolling UIStackView in iOS 9 | |
// | |
// Created by Paul Hudson on 10/06/2015. | |
// Learn Swift at www.hackingwithswift.com | |
// @twostraws | |
// | |
import UIKit |
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
// | |
// RecordAudio.swift | |
// | |
// This is a Swift class (updated for Swift 5) | |
// that uses the iOS RemoteIO Audio Unit | |
// to record audio input samples, | |
// (should be instantiated as a singleton object.) | |
// | |
// Created by Ronald Nicholson on 10/21/16. | |
// Copyright © 2017,2019 HotPaw Productions. All rights reserved. |
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
// | |
// TransitionComposition.swift | |
// MED | |
// | |
// Created by Limon on 7/26/16. | |
// Copyright © 2016 MED. All rights reserved. | |
// | |
import AVFoundation |
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
import Foundation | |
import UIKit | |
struct SFUIDisplayFontType : OptionSetType | |
{ | |
let rawValue: Int | |
init(rawValue: Int) { self.rawValue = rawValue } | |
static internal let None = SFUIDisplayFontType(rawValue: 0) | |
static internal let Bold = SFUIDisplayFontType(rawValue: 1) |
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
import AVFoundation | |
import Foundation | |
extension FileManager { | |
func removeFileIfNecessary(at url: URL) throws { | |
guard fileExists(atPath: url.path) else { | |
return | |
} | |
do { |