macos-mojave

OpenCV command line app can't access camera under macOS Mojave

冷暖自知 提交于 2020-06-25 09:34:13
问题 I'm unable to access the iMac camera from a command line OpenCV program. (I'm compiling and running the program under CodeRunner, not Xcode.) I've read that Mojave requires NSCameraUsageDescription in Info.plist and I think I'm embedding it correctly in the binary. I added -sectcreate __TEXT __info_plist Info.plist (which I learned about here) to the compile flags and when I run otool -X -s __TEXT __info_plist videotest | xxd -r (from the same blog post) it outputs: -?<?xml ve.0" encoding=

PyObjC “Notifications are not allowed for this application”

隐身守侯 提交于 2020-06-17 09:54:28
问题 I'm trying to test a simple Python script to send out a macOS notification: import objc import UserNotifications from PyObjCTools import AppHelper def notif_callback(err): print("Error in notification callback:",err) def auth_callback(granted, err): print("Granted: ",granted,) print("Error in authorization request: ",err) content=UserNotifications.UNMutableNotificationContent.alloc().init() content.setTitle_("Test") r=UserNotifications.UNNotificationRequest.requestWithIdentifier_content

Application doesn't ask for permission to access microphone in MacOS 10.14 Mojave

会有一股神秘感。 提交于 2020-05-13 08:05:15
问题 I'm part of a team developing applications for flight simulation. One of these applications is running also on MacOS and needs access to the microphone to communicate with online virtual air traffic control. Starting with MacOS 10.14 microphone access is no longer working. It used to work perfectly in any previous version of MacOS. I've read that starting with 10.14, MacOS will ask the user for permission, but this dialog never appears. Using portaudio as the audio library, audio input stream

What is CoreMediaIo DAL virtual camera alternative in macOS Mojave

跟風遠走 提交于 2020-05-11 07:56:20
问题 I try to implement the virtual camera using CoreMediaIO DAL plugin, the virtual device won't show up in Mojave with Photo Booth and other application, is CoreMediaIO plugin method deprecated in Mojave? what is the replacement? The virtual camera I created is basically based on https://developer.apple.com/library/archive/samplecode/CoreMediaIO and some samples in github. I expected when I open the Photo Booth application, the virtual device would show on the Camera list, but it is not. (Mojave

What is CoreMediaIo DAL virtual camera alternative in macOS Mojave

£可爱£侵袭症+ 提交于 2020-05-11 07:54:54
问题 I try to implement the virtual camera using CoreMediaIO DAL plugin, the virtual device won't show up in Mojave with Photo Booth and other application, is CoreMediaIO plugin method deprecated in Mojave? what is the replacement? The virtual camera I created is basically based on https://developer.apple.com/library/archive/samplecode/CoreMediaIO and some samples in github. I expected when I open the Photo Booth application, the virtual device would show on the Camera list, but it is not. (Mojave

Is there any API to get Full Disk Access info for an application in macOS?

拥有回忆 提交于 2020-03-25 04:00:08
问题 Applications which require Full Disk Access in macOS 10.14 Mojave must instruct their users to navigate into System Preferences > Security & Privacy > Full Disk Access and add the application to the whitelist. This procedure is complicated and will frustrate new users of such an app. There should be a API for this – an asynchronous function which, when called by an app, would present the user with a dialog requesting Full Disk Access and, if the user clicks OK, automatically enter the calling

“macOS_SDK_headers_for_macOS_10.14.pkg is incompatible with this version of macOS” while installing Haskell on OS X mojave

大兔子大兔子 提交于 2020-02-20 10:32:59
问题 While running the following code block, $ cd /Library/Developer/CommandLineTools/Packages/ $ open macOS_SDK_headers_for_macOS_10.14.pkg The installer warned This package is incompatible with this version of macOS and may fail to install. And when I choose 'Install Anyway', it fails. How can I possibly get it work? Some possibly relevant environmental versions: OS: macOS 10.14.5 xcodebuild -version: Xcode 11.2.1 gcc --version: gcc (Homebrew GCC 9.2.0_1) 9.2.0 Bigger Context: I was setting up

“macOS_SDK_headers_for_macOS_10.14.pkg is incompatible with this version of macOS” while installing Haskell on OS X mojave

半城伤御伤魂 提交于 2020-02-20 10:31:08
问题 While running the following code block, $ cd /Library/Developer/CommandLineTools/Packages/ $ open macOS_SDK_headers_for_macOS_10.14.pkg The installer warned This package is incompatible with this version of macOS and may fail to install. And when I choose 'Install Anyway', it fails. How can I possibly get it work? Some possibly relevant environmental versions: OS: macOS 10.14.5 xcodebuild -version: Xcode 11.2.1 gcc --version: gcc (Homebrew GCC 9.2.0_1) 9.2.0 Bigger Context: I was setting up

Android Studio Mojave not starting

為{幸葍}努か 提交于 2020-02-03 05:30:05
问题 I know that this is unlikely the correct place to ask, but I don't know where I should. So I have a normal macbook from 2016. I had Android studio installed a couple of months and worked with it just fine for a long time. Now upgrading to Mojave, Android Studio doesn't open anymore. I reinstalled it already 5 times, tried everything I found in the internet but still not able to start it. After installing and moving it to applications It asks me to open it, I accept and then it starts to

(PHP) How to detect that user's computer/browser is in Dark Mode?

↘锁芯ラ 提交于 2020-01-30 09:01:06
问题 Lately I am updating my software to support dark mode, in response to research that looking at a paper-white background display is bad for the eyes and for sleep rhythms. Is there a way to detect from PHP that a user's browser and/or OS are set to Dark Mode? How about detecting that it is set to nighttime mode (reduction of blue colors)? 回答1: Since PHP executes on the server without any knowledge of the client, there is no direct way of finding this out. If it is possible to detect the color