locked
Best way to announce that the hardware does not meet the minimum requirements

    Question

  •      Hi Everybody!!!

         I'm in the process of tiding my App up, and I stumbled into a requirement that needs to be addressed. I'm not quite familiar with the latest trends, so I was wondering if anybody could recommend a way to inform the user if the hardware to use does not meet the minumum requirements.

         In a nutshell:

     * I just created a game using Direct3D / DirectX 11,
     * I'm using "DrawIndexedInstanced", which means that the videocard to use should meet at least DirectX v10 (my shaders are using model 9_3 but I tested it in a computer with DirectX9 model 3 (or so the nvidia brochure said), and the game pretty much died in my arms).
     * According to the App Certification Requirements: "if you choose a minimum feature level higher than 9_1, your app must detect at launch whether or not the current hardware meets the minimum requirements. If not, the app must display a message to the customer detailing the Direct3D requirements."
     * I know how to detect the Direct3D level supported by the current videocard. What I would like to know is how to tell the user that the videocard does not support the minimum requirements.

         I don't have much knowledge about the current trends:

     * I assume that displaying a message box may not be the best option, as that would mean I need to link the MFC layer to do so (the game is in Visual C++ and that's what I would do if it were one of my day-job projects). I'm quite sure that is too much of a library just to show a message box... not to mention that most likelly the MFC is no longer supported in a Metro application...
     * I was thinking about displaying a nice graphic warning about the issue, but if the D3DDevice1 is not what I expect then I don't think I can be sure that at least it can display the graphic with the information.
     * I'm not quite sure if I should be linking to a .NET Library ("System.Windows.Forms" comes to mind), but then again maybe it's too much of a library for just a messagebox.
     * Then again, displaying that message in a command prompt may not be the best idea either.

         Any help is greatly appreciated!!!

         Best Regards,

         Tarh Ik


    Tarh ik

    Tuesday, December 2, 2014 2:32 AM

Answers

  • The easiest would be to use the MessageDialog class .

    The other alternate would be to draw a nice graphic in DirectX. Drawing a simple graphic dialog shouldn't require high feature levels. If you can't get a feature level 9_1 device then something is severely enough broken that you don't need to worry about a graceful failure mode and can just exit.

    Neither MFC nor WinForms are supported on Windows Store apps.

    • Marked as answer by Tarh ik Tuesday, December 2, 2014 8:52 PM
    Tuesday, December 2, 2014 3:55 AM
    Moderator

All replies

  • The easiest would be to use the MessageDialog class .

    The other alternate would be to draw a nice graphic in DirectX. Drawing a simple graphic dialog shouldn't require high feature levels. If you can't get a feature level 9_1 device then something is severely enough broken that you don't need to worry about a graceful failure mode and can just exit.

    Neither MFC nor WinForms are supported on Windows Store apps.

    • Marked as answer by Tarh ik Tuesday, December 2, 2014 8:52 PM
    Tuesday, December 2, 2014 3:55 AM
    Moderator
  •      Thanks Rob!!!

         I really like your suggestion about drawing a simple graphic dialog. If I find that the videocard's feature level is not supported, do you think it would be safe to destroy the device pointer and create it again, this time using D3D_DRIVER_TYPE_WARP? That would save me a lot of code, and I could use some of the features I already have like a "fade-to-dark" effect I created... not to mention the font to use to inform the user about the issue...

         Thanks for your suggestions!!!


    Tarh ik

    Tuesday, December 2, 2014 7:08 PM
  • The simplest thing to do is to create a Feature Level 9.1 HARDWARE device. That should work on all Windows 8.x systems.

    Note that if the system is in fact missing a video driver or a video card capable of Direct3D, there is already a 'Microsoft Basic Renderer' active which is in fact WARP with a simple VGA driver. See Anatomy of Direct3D 11 Create Device.

    Wednesday, December 3, 2014 8:18 AM
  •      Hi Chuck,

         I tried your idea, but the game always crashed when calling the DrawIndexedInstanced() function in a computer that only supported DirectX Level 9.1 (plenty of those computers at my day-job, sometimes I swear this office could be a museum). The crash started as a driver unload call, and after that everything goes down.

         I also tried using the WARP mode, but the performance was horrible, and after a minute of playing I started to have temperature issues with the CPU (I did not see that one coming)

         What I finished doing was to create two sets of shaders (pixel and vertex):

     * If the feature reported by D3D11CreateDevice was 9_3 or above, I'd use my very own and happy shaders, compiled in 9_3 model. Beautiful performance with DrawIndexedInstanced().

     * If on the other hand the feature reported by D3D11CreateDevice was either 9_2 or 9_1, I'd use a set of shaders compiled for level 9_1. That seemed to be enough to draw a couple of images on the screen and tell the user, using my own game elements, that the computer did not match the hardware requirements.

          It looks like this was a good approach. My game passed the certification test, and it is currently on the AppStore.

          Best Regards,

          Tarh Ik

    PS: This posting has been posted "AS IS"


    Tarh ik

    Thursday, February 19, 2015 9:50 PM