Path: utzoo!attcan!uunet!wuarchive!julius.cs.uiuc.edu!ux1.cso.uiuc.edu!uxa.cso.uiuc.edu!dslg0849 From: dslg0849@uxa.cso.uiuc.edu (Daniel S. Lewart) Newsgroups: comp.binaries.ibm.pc.d Subject: Re: Borland BGI question Message-ID: <1990Dec10.190516.12984@ux1.cso.uiuc.edu> Date: 10 Dec 90 19:05:16 GMT References: <1990Dec7.121658.25371@aplcen.apl.jhu.edu> <2505@mentor.cc.purdue.edu> Sender: news@ux1.cso.uiuc.edu (News) Organization: University of Illinois at Urbana Lines: 37 dd26+@andrew.cmu.edu (Douglas F. DeJulio) writes: > I've gotten several programs that use BGI files and can choose between > different display types when they start up. They're *supposed* to > auto-detect the correct display type and use it. On my machine they > don't. I've got an AT&T PC6300 which should use the ATT400 BGI > module. Programs that autodetect invariably choose CGA. Ugh. I own > Turbo-C and I've checked the manuals, but I couldn't find a way to > force a particular display type at run time. Can it be done with an > environment variable or something? Any help would be appreciated. > -- > Doug DeJulio > dd26@andrew.cmu.edu The following Turbo Pascal routine works for my AT&T PC6300. It should be trivial to translate it to Turbo C. ------------------------------------------------------------------------------- Uses Graph; procedure DetectGraph(var GraphDriver,GraphMode: Integer); const ATTLogo = 'OLIVETTI'; ATTLen = Length(ATTLogo); var RomId: array[1..ATTLen] of Char absolute $FC00:$0050; begin if RomId <> ATTLogo then Graph.DetectGraph(GraphDriver,GraphMode) else begin GraphDriver := ATT400; GraphMode := ATT400Hi; end; end; ------------------------------------------------------------------------------- Daniel Lewart d-lewart@uiuc.edu