🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: sci.image.processing
Article #632

Re: Turbo C Library Graphics Help

#632
From: Michael Cree
Date: Fri, 02 Oct 1992 01:44
32 lines
2413 bytes
Steve Bryant (bryant@neural.Kodak.COM) wrote:
: I am using Turbo C for some Image analysis. Unfortunately the 
: graphics library that comes with Turbo C does not include a driver
: for the 256 color mode. I am trying to display a bit map monochrome
: image with 256 grey scale levels.

Be wary, standard VGA does not do 256 grey scale levels. It has 256 colour
modes but only 64 grey scales since there are normally 6 bits per colour. If
you are one of those who do have more sophisticated vga cards capable of 24
bit colour then ignore my above comment.

: Does anyone know of a good inexpensive graphics library for Turbo C 
: running under DOS 5.0 that will allow me to use my  super VGA card 
: in the 256 color mode. The library has to be for the large memory 
: model.

If you can't locate a library, it is pretty easy to write a driver to drive
the vga modes. The easiest way is to call the BIOS video calls, though not
very computationally efficient, it is easy to implement. The other choice is
to hit the hardware yourself, but if you need extended vga modes then you
need to know the hardware you are running on which is nothing but a right
pain. I do have code for drawing to the vga screens but it's in modula-2 and
since I vowed never to programme an IBM AT (unless it was running unix) due
to the horrific system it is, I'm not about to translate it to C. However, if
would be any help I could email it to you.

-----------------------------------------------------------------------------
Michael Cree                              Gold there is
cree@elec.canterbury.ac.nz                 and rubies in abundance;
                                          But lips that speak knowledge
                                           are a rare jewel. (Prov 20:15)
------------------------------------------------------------------------------
Technical Details
Message-ID: <BvH0u9.AEM@cantua.canterbury.ac.nz>
Path: arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!wupost!waikato.ac.nz!canterbury.ac.nz!betelgeux!cree
References: <1992Oct1.122617.10918@kodak.kodak.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!wupost!waikato.ac.nz!canterbury.ac.nz!betelgeux!cree
Newsgroups: sci.image.processing
Subject: Re: Turbo C Library Graphics Help
Message-ID: <BvH0u9.AEM@cantua.canterbury.ac.nz>
From: cree@elec.canterbury.ac.nz (Michael Cree)
Date: Fri, 2 Oct 1992 01:44:33 GMT
References: <1992Oct1.122617.10918@kodak.kodak.com>
Organization: Electrical Engineering, University of Canterbury, New Zealand
Nntp-Posting-Host: betelgeux.canterbury.ac.nz
X-Newsreader: TIN [version 1.1 PL6]
Lines: 32