Tag: UWP

DRM-enabled streaming media playback bug with UWP MediaElement

Addition of another crazy thing into internal tooling uncovered new interesting bug. An application is creating audiovisual HLS (HTTP Live Streaming – adaptive streaming developed by Apple) stream on the fly now with Microsoft PlayReady DRM encryption attached. UWP samples offer a sample application for playback: PlayReady sample. The playback looks this: Oops, no video!…

Read the full article

1 GB limit for Windows::Storage::FileIO::ReadLinesAsync?

There seem to be a limit of 1GB for FileIO::ReadLinesAsync API even though documentation is silent on this. The exception message itself adds no clarity: WinRT originate error – 0x80070057 : ‘The parameter is incorrect.’. The function starts working well when the input file is slightly reduced in size (under 1050 MB).

Another API exception which should not have been thrown

From the documentation on StorageFolder.TryGetItemAsync(String) Method: Tries to get the file or folder with the specified name from the current folder. Returns null instead of raising a FileNotFoundException if the specified file or folder is not found. Exception thrown at 0x00007FFB06BDA799 (KernelBase.dll) in DownloadIssue.exe: WinRT originate error – 0x80070002 : ‘An item cannot be found with the specified name…

Read the full article

Best JSON and Base64 libraries for C++ and Windows

The application in previous post Is my system a hybrid (switchable) graphics system? is implemented in C++/WinRT, which I finally decided to give a try. For authoring and consuming Windows Runtime APIs using C++, there is C++/WinRT. This is Microsoft’s recommended replacement for the C++/CX language projection, and the Windows Runtime C++ Template Library (WRL). The real question…

Read the full article

Media Foundation API primitive styling of WinRT windows.mediaCodec

An interesting Media Foundation question on StackOverflow: Weird connection between CoInitializeSecurity() and Media Foundation Encoders A developer has reasons to discard standard COM security and go RPC_C_IMP_LEVEL_ANONYMOUS. Surprisingly this has effect on Windows Media Foundation API in the part of available codecs (Media Foundation Transforms). Sample code: CoInitializeSecurity line in the code above removes the…

Read the full article

Infrared Camera in Media Foundation

The screenshot above shows Surface Pro tablet’s infrared camera (known as “Microsoft IR Camera Front” on the device) captured live, encoded and streamed (everything is hosted by Microsoft Media Foundation Media Session by this point) over network using WebSockets into Chrome’s HTML5 video tag by means of Media Source Extensions (MSE). Why? Because why not.…

Read the full article