Thread: OpenGL or DirectX

  1. #1
    Registered User
    Join Date
    Jul 2011

    OpenGL or DirectX

    Hello. I'm slowly progressing through C++ and I'm at the point of wanting to make GUIs / interactive interfaces.
    I've done a few things with Window API, and now I wish to move on to either OpenGL or DirectX. Could anyone please explain the technical difference between them (which does what better) and post tutorials for each?

  2. #2
    Gawking at stupidity
    Join Date
    Jul 2004
    Oregon, USA
    This is all stuff that 30 seconds of googling can get you...
    If you understand what you're doing, you're not learning anything.

  3. #3
    Registered User
    Join Date
    Jan 2010
    OpenGL is portable and focused around C
    DirectX is windows only and focused around C++
    As for which to choose.. If you want to code for more than windows, OpenGL.
    If windows only, look at some tutorials for both APIs and decide with syntax you prefer the most. You can produce the same end result in both.

  4. #4
    Registered User
    Join Date
    Jul 2011


    Ok. After looking into this I decided to give DirectX a try.

    First of all, how exactly do I enable the library for use in projects? (I didn't find any ".pc" files for pkg-config)

    And secondly, any good tutorials for it? I've mostly found this- DirectX - Game Programming with DirectX
    but it has premium-only features, which I dislike. If it's the only good one, say so though ^^ ty.

  5. #5
    Unregistered User Yarin's Avatar
    Join Date
    Jul 2007
    Ehgh. While DX is more than capable for what you need... Use OGL. Just because

  6. #6
    Programming Wraith GReaper's Avatar
    Join Date
    Apr 2009
    OGL is easier to start with, but along the way both it and DX because almost equally difficult. I would choose by thinking performance first. All decent programmers know that in Windows, DirectX tires the CPU much less. On the other hand, trying to cut my way through the COM interface is too much for me...

    EDIT: Above all, OpenGL is what it says only, while DirectX is DirectDraw, Direct3D, DirectSound, (DirectMusic?), and some more i don't remember.
    Last edited by GReaper; 07-25-2011 at 03:27 PM.
    Devoted my life to programming...

  7. #7
    Registered User
    Join Date
    Jul 2011
    Above all, OpenGL is what it says only, while DirectX is DirectDraw, Direct3D, DirectSound, (DirectMusic?), and some more i don't remember.
    OpenGL is not just it. In fact, there is quite a bit of them:
    - OpenGL, a cross-platform computer graphics API
    - OpenCL, a cross-platform computation API.[5]
    - COLLADA, a file-format intended to facilitate interchange of 3D assets.
    - OpenGL SC, a safety critical profile of OpenGL ES designed to meet the needs of the safety-critical market
    - OpenKODE, an API for providing abstracted, portable access to operating system resources such as file systems, networks and math libraries
    - OpenGL ES, a derivative of OpenGL for use on mobile and embedded systems, such as cell phones, portable gaming devices, and more
    - OpenVG, an API for accelerating processing of 2D vector graphics .
    - OpenMAX, a layered set of three programming interfaces of various abstraction levels, providing access to multimedia functionality
    - OpenSL ES, an audio API tuned for embedded systems, standardizing access to features such as 3D positional audio and MIDI playback
    - EGL, an interface between Khronos rendering APIs such as OpenGL ES or OpenVG and the underlying native platform window system [6]
    - OpenWF, APIs for 2D graphics composition and display control
    - OpenML, an API for capturing, transporting, processing, displaying, and synchronizing digital media
    - WebGL, a JavaScript binding to OpenGL ES within a browser on any platform supporting the OpenGL or OpenGL ES graphics standards
    These are all the sources are provided by "Khronos Group", the owner of the OpenGL API since July 2006.

    There is also OpenAL (for audio) provided by Loki Software, which has the same look and feel of OpenGL and friends.

    The best part of OpenGL is that it is a cross platform API that is supported by:
    Apple Inc.
    ARM Holdings
    Creative Labs
    id Software
    Intel Corporation
    Samsung Electronics
    Sony Computer Entertainment
    Oracle/Sun Microsystems
    Texas Instruments
    OpenGL and friends can work on Windows, Linux, Mac, iPhone, iPad, Android and more. Not just limited to a Windows computer and xbox.

    Full list of all of its supporters & contributors at:
    Khronos Contributing Members
    Khronos Academic Members

  8. #8
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Please do not bump old threads.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. OpenGL vs DirectX
    By WDT in forum Game Programming
    Replies: 9
    Last Post: 10-01-2006, 03:19 AM
  2. OpenGL DirectX 2D
    By c++.prog.newbie in forum Game Programming
    Replies: 11
    Last Post: 03-01-2005, 01:54 PM
  3. OpenGL vs. DirectX ???
    By Grumpy_Old_Man in forum Game Programming
    Replies: 55
    Last Post: 08-18-2003, 11:52 AM
  4. OpenGL 2 or DirectX ?
    By alex6852 in forum A Brief History of
    Replies: 9
    Last Post: 01-02-2003, 02:31 PM
  5. DirectX or OpenGL
    By Unregistered in forum Game Programming
    Replies: 1
    Last Post: 12-08-2001, 01:48 PM

Tags for this Thread