AVFoundation (AVPlayer) supported formats? No .vob or .mpg containers?

The AVURLAsset class has a static methods that you can query for supported video UTIs: + (NSArray *)audiovisualTypes On 10.9.1 it returns these system defined UTIs: public.mpeg public.mpeg-2-video public.avi public.aifc-audio public.aac-audio public.mpeg-4 public.au-audio public.aiff-audio public.mp2 public.3gpp2 public.ac3-audio public.mp3 public.mpeg-2-transport-stream public.3gpp public.mpeg-4-audio Here is an explanation of system UTIs. So it seems that at least the … Read more

Run a script only at shutdown (not log off or restart) on Mac OS X

Few days ago I published on github a configuration/script able to be executed at boot/shutdown. Basically on Mac OS X you could/should use a System wide and per-user daemon/agent configuration file (plist) in conjunction with a bash script file. This is a sample of the plist file you could use: <?xml version=”1.0″ encoding=”UTF-8″?> <!DOCTYPE plist … Read more

macOS SwiftUI Navigation for a Single View

Here is a simple demo of possible approach for custom navigation-like solution. Tested with Xcode 11.4 / macOS 10.15.4 Note: background colors are used for better visibility. struct ContentView: View { @State private var show = false var body: some View { VStack{ if !show { RootView(show: $show) .frame(maxWidth: .infinity, maxHeight: .infinity) .background(Color.blue) .transition(AnyTransition.move(edge: .leading)).animation(.default) … Read more

How to create virtual hosts in MAMP?

While googling, I found these steps to easily create virtual hosts on MAMP: Open your console in mac and edit your hosts file like this sudo vim /etc/hosts This opens a system file that contains the following line: localhost add your desired host name after local host: localhost mysite.loc press ESC, then :wq! … Read more