Turbo C++ Graphic

I am using Borland C++ 5.02. Can anybody tell me that how to display my initgraph program, since I already specify my bgi folder is in C:\\BC\\BGI and a project is created.
***sorry that i wrongly type the title in "turbo".
chengmengAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

chengmengAuthor Commented:
Edited text of question.
0
AlexVirochovskyCommented:
Dou you have BGI example of
Borland? If not,i can send you
(write you EMail).
Next id snippet of code of initialize:
/*                                                                      */
/*      Begin main function                                             */
/*                                                                      */

int main()
{

  Initialize();                 /* Set system into Graphics mode        */
  ReportStatus();               /* Report results of the initialization */

  ColorDemo();                  /* Begin actual demonstration           */
  if( GraphDriver==EGA || GraphDriver==EGALO || GraphDriver==VGA )
    PaletteDemo();
  PutPixelDemo();
  PutImageDemo();
  Bar3DDemo();
  BarDemo();
  RandomBars();
  ArcDemo();
  CircleDemo();
  PieDemo();
  LineRelDemo();
  LineToDemo();
  LineStyleDemo();
  UserLineStyleDemo();
  TextDump();
  TextDemo();
  CRTModeDemo();
  FillStyleDemo();
  FillPatternDemo();
  PolyDemo();
  SayGoodbye();                 /* Give user the closing screen         */

  closegraph();                 /* Return the system to text mode       */
  return(0);
}
/*                                                                      */
/*      INITIALIZE: Initializes the graphics system and reports         */
/*      any errors which occured.                                       */
/*                                                                      */

void Initialize(void)
{
  int xasp, yasp;                       /* Used to read the aspect ratio*/

  GraphDriver = DETECT;                 /* Request auto-detection       */
  initgraph( &GraphDriver, &GraphMode, "" );
  ErrorCode = graphresult();            /* Read result of initialization*/
  if( ErrorCode != grOk ){              /* Error occured during init    */
    printf(" Graphics System Error: %s\n", grapherrormsg( ErrorCode ) );
    exit( 1 );
  }

  getpalette( &palette );               /* Read the palette from board  */
  MaxColors = getmaxcolor() + 1;        /* Read maximum number of colors*/

  MaxX = getmaxx();
  MaxY = getmaxy();                     /* Read size of screen          */

  getaspectratio( &xasp, &yasp );       /* read the hardware aspect     */
  AspectRatio = (double)xasp / (double)yasp; /* Get correction factor   */

}
Alex
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
KangaRooCommented:
Make sure your target platform is 16 Bit Dos. BGI is not supported under Win32 (inlcuding Win32 Console)
0
chengmengAuthor Commented:
What do u mean by target platform is 16 bit Dos? How i can make it?
0
KangaRooCommented:
When yo create a new project, check out the project dialog. In the lower left area you can select the target type. In the libraries part of the dialog check BGI
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C++

From novice to tech pro — start learning today.