Check if the built-in Mac camera is on
Switch branches/tags
Nothing to show
Clone or download
Latest commit 4212ac1 Oct 18, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Sources/IsCameraOn Upgrade to Swift 4.1 Jun 29, 2018
.editorconfig Init Apr 24, 2017
.gitattributes Upgrade to Swift 4.1 Jun 29, 2018
.gitignore Init Apr 24, 2017
Package.swift Upgrade to Swift 4.2 Sep 14, 2018
license Upgrade to Swift 4 Sep 13, 2017
readme.md SPM → SwiftPM Oct 18, 2018

readme.md

is-camera-on

Check if the built-in Mac camera is on

The camera is commonly known as FaceTime HD or iSight.

This module can be useful to check if the camera is already in use or notify you if it's turned on when you didn't intend it to be.

Requirements

  • macOS 10.11+
  • Xcode 10+
  • Swift 4.2+

Install

SwiftPM

.package(url: "https://github.com/sindresorhus/is-camera-on", from: "2.0.0")

Usage

import IsCameraOn

print(isCameraOn())
//=> true

Related

License

MIT © Sindre Sorhus