TORCS  1.3.9
The Open Racing Car Simulator
ssggraph.cpp
Go to the documentation of this file.
1 /***************************************************************************
2 
3  file : ssggraph.cpp
4  created : Thu Aug 17 23:19:19 CEST 2000
5  copyright : (C) 2000-2013 by Eric Espie, Bernhard Wymann
6  email : torcs@free.fr
7  version : $Id$
8 
9  ***************************************************************************/
10 
11 /***************************************************************************
12  * *
13  * This program is free software; you can redistribute it and/or modify *
14  * it under the terms of the GNU General Public License as published by *
15  * the Free Software Foundation; either version 2 of the License, or *
16  * (at your option) any later version. *
17  * *
18  ***************************************************************************/
19 
20 #ifdef WIN32
21 #include <windows.h>
22 #endif
23 #include <GL/gl.h>
24 
25 #include <tgfclient.h>
26 
27 #include "grmain.h"
28 
29 #ifdef DMALLOC
30 #include "dmalloc.h"
31 #endif
32 
33 static int
34 graphInit(int /* idx */, void *pt)
35 {
36  tGraphicItf *itf = (tGraphicItf*)pt;
37 
38  itf->inittrack = initTrack;
39  itf->initcars = initCars;
40  itf->initview = initView;
41  itf->refresh = refresh;
44  itf->muteformenu = muteForMenu;
45  //itf->bendcar = bendCar;
46  return 0;
47 }
48 
49 /*
50  * Function
51  * ssggraph
52  *
53  * Description
54  * module entry point
55  *
56  * Parameters
57  *
58  *
59  * Return
60  *
61  */
62 extern "C" int
63 ssggraph(tModInfo *modInfo)
64 {
65  modInfo->name = strdup("ssggraph"); /* name of the module (short) */
66  modInfo->desc = strdup("The Graphic Library using PLIB ssg"); /* description of the module (can be long) */
67  modInfo->fctInit = graphInit; /* init function */
68  modInfo->gfId = 1; /* v 1 */
69 
70  return 0;
71 }
tfGraphicInitView initview
Definition: graphic.h:176
int initView(int x, int y, int width, int height, int, void *screen)
Definition: grmain.cpp:229
unsigned int gfId
supported framework version
Definition: tgf.h:192
int initCars(tSituation *s)
Definition: grmain.cpp:347
tfGraphicShutdwnCars shutdowncars
Definition: graphic.h:179
tfGraphicShutdwnTrack shutdowntrack
Definition: graphic.h:180
int initTrack(tTrack *track)
Definition: grmain.cpp:452
tfGraphicRefresh refresh
Definition: graphic.h:178
tfGraphicInitCars initcars
Definition: graphic.h:177
The Gaming Framework API (client part).
int refresh(tSituation *s)
Definition: grmain.cpp:309
tfModPrivInit fctInit
init function
Definition: tgf.h:191
static int graphInit(int, void *pt)
Definition: ssggraph.cpp:34
tGraphicMuteForMenu muteformenu
Definition: graphic.h:181
void shutdownCars(void)
Definition: grmain.cpp:416
char * name
name of the module (short) (NULL if no module)
Definition: tgf.h:189
void muteForMenu(void)
Definition: grmain.cpp:496
tfGraphicInitTrack inittrack
Definition: graphic.h:175
int ssggraph(tModInfo *modInfo)
Definition: ssggraph.cpp:63
void shutdownTrack(void)
Definition: grmain.cpp:472
char * desc
description of the module (can be long)
Definition: tgf.h:190
Interface Structure for Graphic Renering Module.
Definition: graphic.h:174
Module information structure.
Definition: tgf.h:188