Thread: C++ on opengl & direct3d

  1. #1
    Registered User SAMSAM's Avatar
    Join Date
    Nov 2001
    Posts
    218

    Smile C++ on opengl & direct3d

    Hi everyone;

    why is it that any book or tutorial i read on either opengl or direct3d is done with C++?

    is it because thats the native language to both or its done easier by using C++?

    if i want to try it in c is there a tutorial which is c friedly?i like to have the latest directgraphic tutorial.

    i thought opengl was C friendly,well c u all!

  2. #2
    Registered User
    Join Date
    Sep 2002
    Posts
    1,640
    OpenGL is usable with almost any language on the planet.
    The reason why the tutorial is done in C++ is just a preference
    of the writer, Nothin else.

  3. #3
    Banned
    Join Date
    Jan 2003
    Posts
    1,708
    NeHe's tutorials has the code in everything from assembly to delphi to c to ada to visual SNOBOL++. I guess you can kind of think of a library file as a database that contains all of the information for methods, and the linker/interpreter/assembler/zaphoider extracts that information from that file so you can do stuff with it! I'm drunk!

  4. #4
    Registered User SAMSAM's Avatar
    Join Date
    Nov 2001
    Posts
    218
    can we use win32 sound functions or for that matter GDI functions
    in conjuction with a program that is graphicaly based on opengl?

    did QUAKE for instance used directmusic and input and sound while using opengl for graphics?

  5. #5
    Of course you can mix Win32 and (Opengl or DirectX) - that's what the dialogues, windows, and buttons - as well as the program is win32 architecture. However, mixing OpenGL and DirectX together is not recommended - remember u have to load the libraries of the things you use so having a DirectX and OpenGL module/dll loaded in mem at the same time is self-defeating.

    When u use OpenGL or DirectX u r telling the comp to use Hardware instead of software rendering, that's all it is - wrapped up in a nice API. If ur using DirectX then use DirectX for all - if u decide on OpenGL find some nice 2D and Audio API's to supplement.

    Or use hardware specific API's and assembly from Nvidia or similar company.
    My Avatar says: "Stay in School"

    Rocco is the Boy!
    "SHUT YOUR LIPS..."

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Direct3D vs OpenGL Interview
    By Darklighter in forum Game Programming
    Replies: 0
    Last Post: 11-25-2006, 09:37 AM
  2. OpenGL Window
    By Morgul in forum Game Programming
    Replies: 1
    Last Post: 05-15-2005, 12:34 PM
  3. OpenGL .dll vs video card dll
    By Silvercord in forum Game Programming
    Replies: 14
    Last Post: 02-12-2003, 07:57 PM
  4. Direct3D vs. OpenGL
    By PorkyChop in forum Game Programming
    Replies: 22
    Last Post: 12-08-2002, 12:41 AM
  5. opengl code not working
    By Unregistered in forum Windows Programming
    Replies: 4
    Last Post: 02-14-2002, 10:01 PM