PlayReady only works when compiled to x64 (not AnyCPU)

Topics: Windows 8 Xaml
Aug 20, 2012 at 4:05 PM

We have an Win8/Metro application which uses Media Framework (Preview5 v1.4.1) and PlayReady Client SDK (v1.0)

If we compile the application for "Any CPU", playing any DRMed WMV content will immediately result in:

MediaFailed: MF_MEDIA_ENGINE_ERR_SRC_NOT_SUPPORTED : HRESULT - 0x800700C1

even before the protectionManager is initialized (before Enter Playback.ProtectionManager_ServiceRequested() )

However, if we compile for target "x64" only, the ProtectionManager is correctly loaded, initialized and correctly performs the PlayReady licence acquisition.

Note that when we use the "Simple PlayReady sample for Windows 8" sample, we can use the "Any CPU" compilation and, on same Win8 (x6) PC, it works correctly.

The only difference we see is that we use the Media Framework, whereas the sample uses a simple MediaElement.

Is that the expected behavior, is we need to compile app/package for specific CPU target?

If so, does it mean we need to submit multiple (target-dependent) packages?

Thank you.

Coordinator
Sep 5, 2012 at 8:50 PM

scrainic, I believe the reason for this is the "Prefer 32-bit" setting in the simple PlayReady sample on MSDN is not checked by default. If you go to the project properties for the MSDN PlayReady sample you'll see this is different from the default Xaml project template.

Furthermore, you should be able to get the player framework to behave the same way if you uncheck this.

However, you will still need to check all 3 platforms (x64, x86, & ARM) when you build your appx package for the store to ensure the correct PlayReady binaries are used for any given machine. The PlayReady SDK is built in C++ and therefore has unique binaries per platform.

Tim

Sep 5, 2012 at 8:54 PM

Thanks, indeed we did figure that out eventually.

Sep 6, 2012 at 4:57 PM

Hi Tim,

I have the same problem of Scrainic, so I tried to apply your suggested solution (based on "Prefer 32-bit" settings) but it still doesn't work.

I don't know if Scrainic was able to make the DRM working. @Scrainic: could you please give me an answer? In positive case, could you give me a useful suggestion?

I hope you could help me, unfortunately for me it's a very urgent matter.

Thank you,

Best regard.

Biagio

 

Sep 6, 2012 at 5:00 PM

Yes, we can copile AnyCPU, just like we can compile the Simple C# PlayReady Sample for AnyCPU.

Sep 6, 2012 at 5:08 PM

Thank you for your answer.

I'm stille able to compile x86 and x64 but the problem is stille when you I using x86, because I have still the same error (MF_MEDIA_ENGINE_ERR_SRC_NOT_SUPPORTED).

So you can confirm that your player, when it's compiled using x86, works correctly also with Drm ? In that case what configuration did you use?

(Platform and Platform target)

 

 

 

Coordinator
Sep 6, 2012 at 5:51 PM

Running an app (with PlayReady) that is compiled for x86 will not work if the version of Windows is x64 (and vice versa). But, if you compile for all platforms, the store will take care of installing the correct version so it will be a non-issue in production. Is this what you are encountering?