Roel
Roel

Reputation: 3

Missing System.Media.Capture.Frames namespace

I'm trying to develop a barcode reader app for the Microsoft HoloLens (using this tutorial) but I'm encountering a problem. In the code of this tutorial, there's being referenced to the System.Media.Capture.Frames namespace and it seems like I'm missing this namespace. Looking at the Windows universal samples from Microsoft, there's also being referenced to this namespace. However, I cannot import this namespace.

Does anyone have any idea how I can get access to this namespace?

Upvotes: 0

Views: 1942

Answers (1)

Rob Caplan - MSFT
Rob Caplan - MSFT

Reputation: 21899

Two likely problems:

  1. You need Windows.Media.Capture.Frames not System.Media.Capture.Frames

  2. Windows.Media.Capture.Frames is new for build 14393 so you'll need to make sure your app targets at least that high:

Go to your app's project properties and make sure your target version is set to Build 14393 on the Application tab. Alternatively open the csproj in a text or XML editor and set the TargetPlatformVersion there:

<TargetPlatformVersion>10.0.14393.0</TargetPlatformVersion>

If your minimum version is less than 14393 then make sure you do feature detection with the ApiInformation class before calling the Frames functions to make sure they exist.

Upvotes: 1

Related Questions