[svlug] Er, what compiler was your program written for? -- Re: graphics programme

Bryan -TheBS- Smith thebs at theseus.com
Mon May 22 11:19:57 PDT 2000

Er, what compiler was your program written for? -- Re: graphics programme

On Mon, 22 May 2000, rangeela wrote:
> What are the counter part of initgraph() and other graphics call in
> Linux? I have a graphics programme in C++ and what to run it on linux
> machine.

Er, what compiler was your program written for?  I'm guessing by
the "initgraph()" function call it was Borland C++ for DOS -- I'm
rusty here so bare with me ;-).  I never did much Win32 programming

In most, contemporary OSes I don't believe you initialize the
graphics subsystem anymore.  You interface with the graphics APIs
of the running operating environment (OE) and GUI framework.  This
is true whether you're running Windows 2000 (e.g., Windows NT),
Linux or even Windows 98 (which is nothing more than Windows 4.1
atop of MS-DOS 7.1).

Under Linux, the OE is the X-Windows system (OE), X11R6.3 (c/o XFree is the latest in most distros with X11R6.4 (c/o XFree 4.0)
just released several weeks ago (and hasn't made it into distros). 
The later features the new Direct Rendering Infrastructure (DRI)
API and support which allows you to bypass all the advanced
capabilities of X (e.g., remote displays, not exactly idea for
gaming ;-).

The GUI framework, if you choose to use it, varies in Linux (unlike
Windows).  It's up to you to choose.  GTK+ and Qt are the two most
popular and are commonly found in the presentation of the
Gnome/Enlightenment and KDE/kwm environments and window managers. 
Another popular cross-platform framework (Linux, Windows, SGI/Irix)
is the Fast-Light Toolkit (fltk) which has full OpenGL support. 
And there are others still.  I'm learning the GTK+ APIs now (with
Sam's "GTK+ Programming 24 Hours" book), but my focus is on
non-gaming apps.

I guess at this point you'll want to narrow your question specifics
and go from there.  It's kinda hard to help someone with such a
broad question.  I cannot even really point you to a good book
since there are so many different choices under Linux (and no one
book covers them all)

-- TheBS

 Bryan "TheBS" Smith -- Engineer, IT Professional and Hacker
      E-mail:  mailto:thebs at theseus.com,b.j.smith at ieee.org
  Disclaimer:  http://www.SmithConcepts.com/legal.html
  TheBS ... Serving E-mail filters to /dev/null since 1989

More information about the svlug mailing list