Add Math module and an extension to float4 to make a float3
This commit is contained in:
parent
43e42f5374
commit
55f7c6fe78
2 changed files with 20 additions and 0 deletions
16
Terrain2/Math.swift
Normal file
16
Terrain2/Math.swift
Normal file
|
@ -0,0 +1,16 @@
|
|||
//
|
||||
// Math.swift
|
||||
// Terrain2
|
||||
//
|
||||
// Created by Eryn Wells on 11/20/18.
|
||||
// Copyright © 2018 Eryn Wells. All rights reserved.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import simd
|
||||
|
||||
extension float4 {
|
||||
var xyz: float3 {
|
||||
return float3(x, y, z)
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue