Results 1 to 2 of 2

Thread: how to detect different windows operating systems

  1. #1
    Junior Member
    Join Date
    Oct 2005

    how to detect different windows operating systems


    I need to develop an application which can run on both pocket pc and a desktop pc. When it runs on a desktop pc, I want it to automatically detect the os and thus enable OpenGL and all the related libraries. When it runs on a pocket pc (windows mobile 2003), it can detect the os and enable OpenGL ES and the related libraries. Do anyone know how I can do this?



  2. #2
    The PC application won't run on a Pocket PC and vice-versa because one is an x86 binary and the other an ARM binary, so you're going to end up creating two separate executables. You could isolate all of the platform-specific code (eg. rendering calls) in a separate DLL that is explicitly loaded by your application depending on the platform. This would allow you to keep the majority of the source code of your application the same for both operating systems.

    The API to use to determine what version of the operating system that is currently running is GetVersionEx (look at the returned OSVERSIONINFO::dwPlatformId). This API is available on Windows and WinCE.

Similar Threads

  1. Replies: 4
    Last Post: 05-19-2005, 03:20 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Proudly hosted by Digital Ocean