DetectGraph (procedure) (Graph unit)


 DetectGraph (procedure)     (Graph unit)

Checks the hardware and determines which graphics driver and mode to use.


 procedure DetectGraph(var GraphDriver, GraphMode: Integer);


Real, Protected


DetectGraph returns the detected driver and mode value that can be passed to InitGraph, which will then load the correct driver. If no graphics hardware was detected, the GraphDriver parameter and GraphResult return a value of grNotDetected.

Unless instructed otherwise, InitGraph calls DetectGraph, finds and loads the correct driver, and initializes the graphics system. The only reason to call DetectGraph directly is to override the driver that DetectGraph recommends. When you pass InitGraph a GraphDriver other than Detect, you must also pass a valid GraphMode for the driver requested.

See Also

Sample Code

Тэги: DetectGraph
| G+
Код для вставки: :: :: :: ::
Поделиться: // //