Skip to content

Instantly share code, notes, and snippets.

View nwtgck's full-sized avatar
:octocat:
Feel free to make my English natural by native speakers

Ryo Ota nwtgck

:octocat:
Feel free to make my English natural by native speakers
View GitHub Profile
@nwtgck
nwtgck / compose_video.md
Created February 25, 2019 08:54 — forked from kazz12211/compose_video.md
AVCaptureVideoOutputDataを使ってキャプチャーしたビデオに文字を合成する方法 (iOS & Swift)

ビデオ映像にテキストを合成して保存する方法 (iOS & Swift)

AVCaptureVideoDataOutputとAVAssetWriterを使ったビデオキャプチャー。

This code snippet describes how to capture video using AVCaptureVideoDataOutpput and AVAssetWriter and how to compose video frame.

インスタンス変数

var captureSession: AVCaptureSession()
var camera: AVCaptureDevice!
import scala.collection.mutable
trait Memorized[T,R] {
val cache = new mutable.HashMap[T,R]
def cacheOrApply( t:T )( f: => R ): R = cache.getOrElse(t, {
val rv = f
cache += t -> rv
rv
})
}
@nwtgck
nwtgck / README.md
Created May 10, 2018 23:05 — forked from shimizu/README.md
Summer Wars - World Clock -

サマーウォーズのアレです。