ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/Client.xs
(Generate patch)

Comparing deliantra/Deliantra-Client/Client.xs (file contents):
Revision 1.53 by root, Wed Apr 19 21:38:04 2006 UTC vs.
Revision 1.54 by root, Wed Apr 19 23:37:48 2006 UTC

414 SDL_WM_SetCaption ("Crossfire+ Client " VERSION, "Crossfire+"); 414 SDL_WM_SetCaption ("Crossfire+ Client " VERSION, "Crossfire+");
415 OUTPUT: 415 OUTPUT:
416 RETVAL 416 RETVAL
417 417
418void 418void
419SDL_GL_SwapBuffers ()
420
421void
419SDL_PollEvent () 422SDL_PollEvent ()
420 PPCODE: 423 PPCODE:
421{ 424{
422 SDL_Event ev; 425 SDL_Event ev;
423 426
1268 CODE: 1271 CODE:
1269 RETVAL = Mix_PlayMusic (self, loops); 1272 RETVAL = Mix_PlayMusic (self, loops);
1270 OUTPUT: 1273 OUTPUT:
1271 RETVAL 1274 RETVAL
1272 1275
1276MODULE = CFClient PACKAGE = CFClient::OpenGL
1277
1278BOOT:
1279{
1280 HV *stash = gv_stashpv ("CFClient::OpenGL", 1);
1281 static const struct {
1282 const char *name;
1283 IV iv;
1284 } *civ, const_iv[] = {
1285# define const_iv(name) { # name, (IV)name }
1286 const_iv (GL_COLOR_MATERIAL),
1287 const_iv (GL_SMOOTH),
1288 const_iv (GL_FLAT),
1289 const_iv (GL_BLEND),
1290 const_iv (GL_AND),
1291 const_iv (GL_SRC_ALPHA),
1292 const_iv (GL_ONE_MINUS_SRC_ALPHA),
1293 const_iv (GL_RGB),
1294 const_iv (GL_RGBA),
1295 const_iv (GL_UNSIGNED_BYTE),
1296 const_iv (GL_ALPHA4),
1297 const_iv (GL_ALPHA),
1298 const_iv (GL_FLOAT),
1299 const_iv (GL_UNSIGNED_INT_8_8_8_8_REV),
1300 const_iv (GL_COMPILE),
1301 const_iv (GL_TEXTURE_1D),
1302 const_iv (GL_TEXTURE_2D),
1303 const_iv (GL_TEXTURE_ENV),
1304 const_iv (GL_TEXTURE_MAG_FILTER),
1305 const_iv (GL_TEXTURE_MIN_FILTER),
1306 const_iv (GL_TEXTURE_ENV_MODE),
1307 const_iv (GL_TEXTURE_WRAP_S),
1308 const_iv (GL_TEXTURE_WRAP_T),
1309 const_iv (GL_CLAMP),
1310 const_iv (GL_REPEAT),
1311 const_iv (GL_NEAREST),
1312 const_iv (GL_LINEAR),
1313 const_iv (GL_MODULATE),
1314 const_iv (GL_REPLACE),
1315 const_iv (GL_COLOR_BUFFER_BIT),
1316 const_iv (GL_PROJECTION),
1317 const_iv (GL_MODELVIEW),
1318 const_iv (GL_COLOR_LOGIC_OP),
1319 const_iv (GL_CONVOLUTION_2D),
1320 const_iv (GL_CONVOLUTION_BORDER_MODE),
1321 const_iv (GL_CONSTANT_BORDER),
1322 const_iv (GL_LINES),
1323 const_iv (GL_QUADS),
1324 const_iv (GL_PERSPECTIVE_CORRECTION_HINT),
1325 const_iv (GL_FASTEST),
1326# undef const_iv
1327 };
1328
1329 for (civ = const_iv + sizeof (const_iv) / sizeof (const_iv [0]); civ-- > const_iv; )
1330 newCONSTSUB (stash, (char *)civ->name, newSViv (civ->iv));
1331}
1332
1333int glGetError ()
1334
1335void glClear (int mask)
1336
1337void glClearColor (float r, float g, float b, float a = 1.0)
1338 PROTOTYPE: @
1339
1340void glEnable (int cap)
1341
1342void glDisable (int cap)
1343
1344void glShadeModel (int mode)
1345
1346void glHint (int target, int mode)
1347
1348void glBlendFunc (int sfactor, int dfactor)
1349
1350void glLogicOp (int opcode)
1351
1352void glMatrixMode (int mode)
1353
1354void glPushMatrix ()
1355
1356void glPopMatrix ()
1357
1358void glLoadIdentity ()
1359
1360void glOrtho (double left, double right, double bottom, double top, double near, double far)
1361
1362void glViewport (int x, int y, int width, int height)
1363
1364void glTranslate (float x, float y, float z = 0.)
1365 CODE:
1366 glTranslatef (x, y, z);
1367
1368void glScale (float x, float y, float z)
1369 CODE:
1370 glScalef (x, y, z);
1371
1372void glRotate (float angle, float x, float y, float z)
1373 CODE:
1374 glRotatef (angle, x, y, z);
1375
1376void glBegin (int mode)
1377
1378void glEnd ()
1379
1380void glColor (float r, float g, float b, float a = 1.0)
1381 PROTOTYPE: @
1382 CODE:
1383 glColor4f (r, g, b, a);
1384
1385void glVertex (float x, float y, float z = 0.)
1386 CODE:
1387 glVertex3f (x, y, z);
1388
1389void glTexCoord (float s, float t)
1390 CODE:
1391 glTexCoord2f (s, t);
1392
1393void glTexEnv (int target, int pname, float param)
1394 CODE:
1395 glTexEnvf (target, pname, param);
1396
1397void glTexParameter (int target, int pname, float param)
1398 CODE:
1399 glTexParameterf (target, pname, param);
1400
1401void glBindTexture (int target, int name)
1402
1403void glConvolutionParameter (int target, int pname, float params)
1404 CODE:
1405 glConvolutionParameterf (target, pname, params);
1406
1407void glConvolutionFilter2D (int target, int internalformat, int width, int height, int format, int type, char *data)
1408
1409void glTexImage2D (int target, int level, int internalformat, int width, int height, int border, int format, int type, char *data)
1410
1411void glCopyTexImage2D (int target, int level, int internalformat, int x, int y, int width, int height, int border)
1412
1413int glGenTexture ()
1414 CODE:
1415{
1416 GLuint name;
1417 glGenTextures (1, &name);
1418 RETVAL = name;
1419}
1420 OUTPUT:
1421 RETVAL
1422
1423void glDeleteTexture (int name)
1424 CODE:
1425{
1426 GLuint name_ = name;
1427 glDeleteTextures (1, &name_);
1428}
1429
1430int glGenList ()
1431 CODE:
1432 RETVAL = glGenLists (1);
1433 OUTPUT:
1434 RETVAL
1435
1436void glDeleteList (int list)
1437 CODE:
1438 glDeleteLists (list, 1);
1439
1440void glNewList (int list, int mode = GL_COMPILE)
1441
1442void glEndList ()
1443
1444void glCallList (int list)
1445

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines