Skip to content
Snippets Groups Projects
Commit 595c5b7d authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

sleep

parent eb403efa
No related branches found
No related tags found
No related merge requests found
%{ /* $Id: Gmsh.l,v 1.12 2000-12-07 08:46:27 geuzaine Exp $ */ %{ /* $Id: Gmsh.l,v 1.13 2000-12-07 09:21:33 geuzaine Exp $ */
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
...@@ -113,6 +113,8 @@ CatmullRom return tSpline; ...@@ -113,6 +113,8 @@ CatmullRom return tSpline;
Delete return tDelete; Delete return tDelete;
Dilate return tDilate; Dilate return tDilate;
Duplicata return tDuplicata; Duplicata return tDuplicata;
Draw return tDraw;
Sleep return tSleep;
Exp return tExp ; Exp return tExp ;
Ellipsis return tEllipsis; Ellipsis return tEllipsis;
......
This diff is collapsed.
...@@ -35,131 +35,133 @@ typedef union { ...@@ -35,131 +35,133 @@ typedef union {
#define tModulo 283 #define tModulo 283
#define tHypot 284 #define tHypot 284
#define tPrintf 285 #define tPrintf 285
#define tPoint 286 #define tDraw 286
#define tCircle 287 #define tSleep 287
#define tEllipsis 288 #define tPoint 288
#define tLine 289 #define tCircle 289
#define tSurface 290 #define tEllipsis 290
#define tSpline 291 #define tLine 291
#define tVolume 292 #define tSurface 292
#define tCharacteristic 293 #define tSpline 293
#define tLength 294 #define tVolume 294
#define tParametric 295 #define tCharacteristic 295
#define tElliptic 296 #define tLength 296
#define tPlane 297 #define tParametric 297
#define tRuled 298 #define tElliptic 298
#define tTransfinite 299 #define tPlane 299
#define tComplex 300 #define tRuled 300
#define tPhysical 301 #define tTransfinite 301
#define tUsing 302 #define tComplex 302
#define tBump 303 #define tPhysical 303
#define tProgression 304 #define tUsing 304
#define tRotate 305 #define tBump 305
#define tTranslate 306 #define tProgression 306
#define tSymmetry 307 #define tRotate 307
#define tDilate 308 #define tTranslate 308
#define tExtrude 309 #define tSymmetry 309
#define tDuplicata 310 #define tDilate 310
#define tLoop 311 #define tExtrude 311
#define tInclude 312 #define tDuplicata 312
#define tRecombine 313 #define tLoop 313
#define tDelete 314 #define tInclude 314
#define tCoherence 315 #define tRecombine 315
#define tView 316 #define tDelete 316
#define tAttractor 317 #define tCoherence 317
#define tLayers 318 #define tView 318
#define tScalarTetrahedron 319 #define tAttractor 319
#define tVectorTetrahedron 320 #define tLayers 320
#define tTensorTetrahedron 321 #define tScalarTetrahedron 321
#define tScalarTriangle 322 #define tVectorTetrahedron 322
#define tVectorTriangle 323 #define tTensorTetrahedron 323
#define tTensorTriangle 324 #define tScalarTriangle 324
#define tScalarLine 325 #define tVectorTriangle 325
#define tVectorLine 326 #define tTensorTriangle 326
#define tTensorLine 327 #define tScalarLine 327
#define tScalarPoint 328 #define tVectorLine 328
#define tVectorPoint 329 #define tTensorLine 329
#define tTensorPoint 330 #define tScalarPoint 330
#define tBSpline 331 #define tVectorPoint 331
#define tNurbs 332 #define tTensorPoint 332
#define tOrder 333 #define tBSpline 333
#define tWith 334 #define tNurbs 334
#define tBounds 335 #define tOrder 335
#define tKnots 336 #define tWith 336
#define tColor 337 #define tBounds 337
#define tFor 338 #define tKnots 338
#define tEndFor 339 #define tColor 339
#define tScript 340 #define tFor 340
#define tExit 341 #define tEndFor 341
#define tMerge 342 #define tScript 342
#define tB_SPLINE_SURFACE_WITH_KNOTS 343 #define tExit 343
#define tB_SPLINE_CURVE_WITH_KNOTS 344 #define tMerge 344
#define tCARTESIAN_POINT 345 #define tB_SPLINE_SURFACE_WITH_KNOTS 345
#define tTRUE 346 #define tB_SPLINE_CURVE_WITH_KNOTS 346
#define tFALSE 347 #define tCARTESIAN_POINT 347
#define tUNSPECIFIED 348 #define tTRUE 348
#define tU 349 #define tFALSE 349
#define tV 350 #define tUNSPECIFIED 350
#define tEDGE_CURVE 351 #define tU 351
#define tVERTEX_POINT 352 #define tV 352
#define tORIENTED_EDGE 353 #define tEDGE_CURVE 353
#define tPLANE 354 #define tVERTEX_POINT 354
#define tFACE_OUTER_BOUND 355 #define tORIENTED_EDGE 355
#define tEDGE_LOOP 356 #define tPLANE 356
#define tADVANCED_FACE 357 #define tFACE_OUTER_BOUND 357
#define tVECTOR 358 #define tEDGE_LOOP 358
#define tDIRECTION 359 #define tADVANCED_FACE 359
#define tAXIS2_PLACEMENT_3D 360 #define tVECTOR 360
#define tISO 361 #define tDIRECTION 361
#define tENDISO 362 #define tAXIS2_PLACEMENT_3D 362
#define tENDSEC 363 #define tISO 363
#define tDATA 364 #define tENDISO 364
#define tHEADER 365 #define tENDSEC 365
#define tFILE_DESCRIPTION 366 #define tDATA 366
#define tFILE_SCHEMA 367 #define tHEADER 367
#define tFILE_NAME 368 #define tFILE_DESCRIPTION 368
#define tMANIFOLD_SOLID_BREP 369 #define tFILE_SCHEMA 369
#define tCLOSED_SHELL 370 #define tFILE_NAME 370
#define tADVANCED_BREP_SHAPE_REPRESENTATION 371 #define tMANIFOLD_SOLID_BREP 371
#define tFACE_BOUND 372 #define tCLOSED_SHELL 372
#define tCYLINDRICAL_SURFACE 373 #define tADVANCED_BREP_SHAPE_REPRESENTATION 373
#define tCONICAL_SURFACE 374 #define tFACE_BOUND 374
#define tCIRCLE 375 #define tCYLINDRICAL_SURFACE 375
#define tTRIMMED_CURVE 376 #define tCONICAL_SURFACE 376
#define tGEOMETRIC_SET 377 #define tCIRCLE 377
#define tCOMPOSITE_CURVE_SEGMENT 378 #define tTRIMMED_CURVE 378
#define tCONTINUOUS 379 #define tGEOMETRIC_SET 379
#define tCOMPOSITE_CURVE 380 #define tCOMPOSITE_CURVE_SEGMENT 380
#define tTOROIDAL_SURFACE 381 #define tCONTINUOUS 381
#define tPRODUCT_DEFINITION 382 #define tCOMPOSITE_CURVE 382
#define tPRODUCT_DEFINITION_SHAPE 383 #define tTOROIDAL_SURFACE 383
#define tSHAPE_DEFINITION_REPRESENTATION 384 #define tPRODUCT_DEFINITION 384
#define tELLIPSE 385 #define tPRODUCT_DEFINITION_SHAPE 385
#define tTrimmed 386 #define tSHAPE_DEFINITION_REPRESENTATION 386
#define tSolid 387 #define tELLIPSE 387
#define tEndSolid 388 #define tTrimmed 388
#define tVertex 389 #define tSolid 389
#define tFacet 390 #define tEndSolid 390
#define tNormal 391 #define tVertex 391
#define tOuter 392 #define tFacet 392
#define tLoopSTL 393 #define tNormal 393
#define tEndLoop 394 #define tOuter 394
#define tEndFacet 395 #define tLoopSTL 395
#define tAND 396 #define tEndLoop 396
#define tOR 397 #define tEndFacet 397
#define tNOTEQUAL 398 #define tAND 398
#define tEQUAL 399 #define tOR 399
#define tAPPROXEQUAL 400 #define tNOTEQUAL 400
#define tAFFECTPLUS 401 #define tEQUAL 401
#define tAFFECTMINUS 402 #define tAPPROXEQUAL 402
#define tAFFECTTIMES 403 #define tAFFECTPLUS 403
#define tAFFECTDIVIDE 404 #define tAFFECTMINUS 404
#define tLESSOREQUAL 405 #define tAFFECTTIMES 405
#define tGREATEROREQUAL 406 #define tAFFECTDIVIDE 406
#define tCROSSPRODUCT 407 #define tLESSOREQUAL 407
#define UNARYPREC 408 #define tGREATEROREQUAL 408
#define tPLUSPLUS 409 #define tCROSSPRODUCT 409
#define tMINUSMINUS 410 #define UNARYPREC 410
#define tPLUSPLUS 411
#define tMINUSMINUS 412
extern YYSTYPE yylval; extern YYSTYPE yylval;
%{ /* $Id: Gmsh.y,v 1.24 2000-12-07 08:46:27 geuzaine Exp $ */ %{ /* $Id: Gmsh.y,v 1.25 2000-12-07 09:21:34 geuzaine Exp $ */
#include <stdarg.h> #include <stdarg.h>
...@@ -72,7 +72,7 @@ void vyyerror (char *fmt, ...); ...@@ -72,7 +72,7 @@ void vyyerror (char *fmt, ...);
%token tEND tAFFECT tDOTS tPi %token tEND tAFFECT tDOTS tPi
%token tExp tLog tLog10 tSqrt tSin tAsin tCos tAcos tTan %token tExp tLog tLog10 tSqrt tSin tAsin tCos tAcos tTan
%token tAtan tAtan2 tSinh tCosh tTanh tFabs tFloor tCeil %token tAtan tAtan2 tSinh tCosh tTanh tFabs tFloor tCeil
%token tFmod tModulo tHypot tPrintf %token tFmod tModulo tHypot tPrintf tDraw tSleep
%token tPoint tCircle tEllipsis tLine tSurface tSpline tVolume %token tPoint tCircle tEllipsis tLine tSurface tSpline tVolume
%token tCharacteristic tLength tParametric tElliptic %token tCharacteristic tLength tParametric tElliptic
%token tPlane tRuled tTransfinite tComplex tPhysical %token tPlane tRuled tTransfinite tComplex tPhysical
...@@ -1671,6 +1671,19 @@ Command : ...@@ -1671,6 +1671,19 @@ Command :
MergeProblem($2); MergeProblem($2);
yyin = ff; yyin = ff;
} }
| tDraw tEND
{
Init();
Draw();
}
| tSleep FExpr tEND
{
extern long Get_AnimTime();
long sleep_time = Get_AnimTime();
while(1){
if(Get_AnimTime() - sleep_time > (long)($2*1.e6)) break;
}
}
; ;
/* --------------- /* ---------------
......
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment