Skip to content

Instantly share code, notes, and snippets.

View dmrschmidt's full-sized avatar

Dennis Schmidt dmrschmidt

View GitHub Profile
@interface UIImage (fixOrientation)
- (UIImage *)fixOrientation;
@end
@akhilcb
akhilcb / CGPoint+Extension.swift
Created May 7, 2017 23:22
CGPoint extension with some useful functions for angle and point calculation on arc and circles
// Taken from ACBRadialMenuView Project
// BSD 3-Clause License
// Copyright (c) 2017, akhilcb (https://github.com/akhilcb)
extension CGPoint {
static func pointOnCircle(center: CGPoint, radius: CGFloat, angle: CGFloat) -> CGPoint {
let x = center.x + radius * cos(angle)
let y = center.y + radius * sin(angle)