Move math modules to their own group
This commit is contained in:
parent
fb71d50b84
commit
cbc3f5b57a
3 changed files with 10 additions and 2 deletions
24
MetaballsKit/Math/Geometry.swift
Normal file
24
MetaballsKit/Math/Geometry.swift
Normal file
|
@ -0,0 +1,24 @@
|
|||
//
|
||||
// Geometry.swift
|
||||
// Metaballs
|
||||
//
|
||||
// Created by Eryn Wells on 8/5/17.
|
||||
// Copyright © 2017 Eryn Wells. All rights reserved.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import simd
|
||||
|
||||
public typealias Size = packed_uint2
|
||||
|
||||
extension Size {
|
||||
public init(size: CGSize) {
|
||||
self.init(UInt32(size.width), UInt32(size.height))
|
||||
}
|
||||
}
|
||||
|
||||
extension Size: CustomStringConvertible {
|
||||
public var description: String {
|
||||
return "(\(x), \(y))"
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue