Skip to content

Instantly share code, notes, and snippets.

View jsharp83's full-sized avatar

EunchulJeon jsharp83

View GitHub Profile
@jsharp83
jsharp83 / CoreMLLoader.swift
Last active June 10, 2020 22:46
When we use CoreML models, we need to handle downloading and loading the model from Web URL in runtime. More specific usage, See this repo: https://github.com/jsharp83/MetalCamera
//
// CoreMLLoader.swift
// MetalCamera
//
// Created by Eric on 2020/06/10.
//
import Foundation
import CoreML
@jsharp83
jsharp83 / CameraManager.swift
Last active August 31, 2024 23:42
Basic camera code using AVCaptureSession in iOS
import Foundation
import AVFoundation
@objc
protocol CameraCaptureDelegate: class {
func captureVideoOutput(sampleBuffer: CMSampleBuffer)
@objc optional func captureAudioOutput(sampleBuffer: CMSampleBuffer)
}
class CameraManager: NSObject {