David Mennenoh
David Mennenoh

Reputation: 290

Control Windows 8 Camera app with Powershell?

I am wanting to use a webcam to record video and have two options. First is using Flash/AS3 with Flash Media Server - I have this one done really and it works fine but I can't quite get the quality I'd like. Well, the Win8 camera app will record 1920x1080 video at 30fps with the same webcam. So, I was thinking I could use powershell to control the app - I'd need to send space to start/stop the recording, and be able to swap the camera application back and forth with another, gallery application, that shows the recordings. I also need to be able to send the start/stop recording command on input from a tcp socket - which from reading seems to be doable. So, is this something for powershell? I've been experimenting and can't reliably access the camera app. Maybe because it's a metro app? Thanks for any tips.

Upvotes: 1

Views: 1759

Answers (1)

Keith Hill
Keith Hill

Reputation: 201942

You can't really access or interact with Metro apps from PowerShell. There are a limited number of WinRT APIs that can be accessed from the desktop. The Windows.Media.Capture.MediaCapture type is accessible from the desktop. However using WinRT in PowerShell is really challenging given that there are a lot of async APIs in WinRT. Take a look at this blog post I wrote on what it takes to use WinRT APIs in PowerShell.

Upvotes: 1

Related Questions