1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
|
#include "main.h"
#include "state.h"
#include "shapes.h"
#include "lua_core.h"
#include "textures.h"
/*
## Shapes - Basic shapes drawing functions
*/
/*
> RL.SetShapesTexture( Texture texture, Rectangle source )
Set texture and rectangle to be used on shapes drawing
NOTE: It can be useful when using basic shapes and one single font,
defining a font char white rectangle would allow drawing everything in a single draw call
*/
int lshapesSetShapesTexture( lua_State *L ) {
Texture *texture = uluaGetTexture( L, 1 );
Rectangle source = uluaGetRectangle( L, 2 );
SetShapesTexture( *texture, source );
return 0;
}
/*
> RL.DrawPixel( Vector2 pos, Color color )
Draw a pixel
*/
int lshapesDrawPixel( lua_State *L ) {
Vector2 pos = uluaGetVector2( L, 1 );
Color color = uluaGetColor( L, 2 );
DrawPixelV( pos, color );
return 0;
}
/*
> RL.DrawLine( Vector2 startPos, Vector2 endPos, float thickness, Color color )
Draw a line defining thickness
*/
int lshapesDrawLine( lua_State *L ) {
Vector2 startPos = uluaGetVector2( L, 1 );
Vector2 endPos = uluaGetVector2( L, 2 );
float thickness = luaL_checknumber( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawLineEx( startPos, endPos, thickness, color );
return 0;
}
/*
> RL.DrawLineStrip( Vector2{} points, Color color )
Draw lines sequence
*/
int lshapesDrawLineStrip( lua_State *L ) {
int pointsCount = uluaGetTableLen( L, 1 );
Color color = uluaGetColor( L, 2 );
Vector2 points[ pointsCount ];
/* t = points index. */
int t = 1, i = 0;
lua_pushnil( L );
while ( lua_next( L, t ) != 0 ) {
points[i] = uluaGetVector2( L, lua_gettop( L ) );
i++;
lua_pop( L, 1 );
}
DrawLineStrip( points, pointsCount, color );
return 0;
}
/*
> RL.DrawLineBezier( Vector2 startPos, Vector2 endPos, float thickness, Color color )
Draw a line using cubic-bezier curves in-out
*/
int lshapesDrawLineBezier( lua_State *L ) {
Vector2 startPos = uluaGetVector2( L, 1 );
Vector2 endPos = uluaGetVector2( L, 2 );
float thickness = luaL_checknumber( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawLineBezier( startPos, endPos, thickness, color );
return 0;
}
/*
> RL.DrawCircle( Vector2 center, float radius, Color color )
Draw a color-filled circle
*/
int lshapesDrawCircle( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
Color color = uluaGetColor( L, 3 );
DrawCircleV( center, radius, color );
return 0;
}
/*
> RL.DrawCircleSector( Vector2 center, float radius, float startAngle, float endAngle, int segments, Color color )
Draw a piece of a circle
*/
int lshapesDrawCircleSector( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
float startAngle = luaL_checknumber( L, 3 );
float endAngle = luaL_checknumber( L, 4 );
int segments = luaL_checkinteger( L, 5 );
Color color = uluaGetColor( L, 6 );
DrawCircleSector( center, radius, startAngle, endAngle, segments, color );
return 0;
}
/*
> RL.DrawCircleSectorLines( Vector2 center, float radius, float startAngle, float endAngle, int segments, Color color )
Draw circle sector outline
*/
int lshapesDrawCircleSectorLines( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
float startAngle = luaL_checknumber( L, 3 );
float endAngle = luaL_checknumber( L, 4 );
int segments = luaL_checkinteger( L, 5 );
Color color = uluaGetColor( L, 6 );
DrawCircleSectorLines( center, radius, startAngle, endAngle, segments, color );
return 0;
}
/*
> RL.DrawCircleGradient( Vector2 center, float radius, Color color1, Color color2 )
Draw a gradient-filled circle
*/
int lshapesDrawCircleGradient( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
Color color1 = uluaGetColor( L, 3 );
Color color2 = uluaGetColor( L, 4 );
DrawCircleGradient( center.x, center.y, radius, color1, color2 );
return 0;
}
/*
> RL.DrawCircleLines( Vector2 center, float radius, Color color )
Draw circle outline
*/
int lshapesDrawCircleLines( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
Color color = uluaGetColor( L, 3 );
DrawCircleLines( center.x, center.y, radius, color );
return 0;
}
/*
> RL.DrawEllipse( Vector2 center, float radiusH, float radiusV, Color color )
Draw ellipse
*/
int lshapesDrawEllipse( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radiusH = luaL_checknumber( L, 2 );
float radiusV = luaL_checknumber( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawEllipse( center.x, center.y, radiusH, radiusV, color );
return 0;
}
/*
> RL.DrawEllipseLines( Vector2 center, float radiusH, float radiusV, Color color )
Draw ellipse outline
*/
int lshapesDrawEllipseLines( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radiusH = luaL_checknumber( L, 2 );
float radiusV = luaL_checknumber( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawEllipseLines( center.x, center.y, radiusH, radiusV, color );
return 0;
}
/*
> RL.DrawRing( Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, Color color )
Draw ring
*/
int lshapesDrawRing( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float innerRadius = luaL_checknumber( L, 2 );
float outerRadius = luaL_checknumber( L, 3 );
float startAngle = luaL_checknumber( L, 4 );
float endAngle = luaL_checknumber( L, 5 );
int segments = luaL_checkinteger( L, 6 );
Color color = uluaGetColor( L, 7 );
DrawRing( center, innerRadius, outerRadius, startAngle, endAngle, segments, color );
return 0;
}
/*
> RL.DrawRingLines( Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, Color color )
Draw ring outline
*/
int lshapesDrawRingLines( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float innerRadius = luaL_checknumber( L, 2 );
float outerRadius = luaL_checknumber( L, 3 );
float startAngle = luaL_checknumber( L, 4 );
float endAngle = luaL_checknumber( L, 5 );
int segments = luaL_checkinteger( L, 6 );
Color color = uluaGetColor( L, 7 );
DrawRingLines( center, innerRadius, outerRadius, startAngle, endAngle, segments, color );
return 0;
}
/*
> RL.DrawRectangle( Rectangle rec, Color color )
Draw a color-filled rectangle
*/
int lshapesDrawRectangle( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
Color color = uluaGetColor( L, 2 );
DrawRectangleRec( rect, color );
return 0;
}
/*
> RL.DrawRectanglePro( Rectangle rec, Vector2 origin, float rotation, Color color )
Draw a color-filled rectangle with pro parameters
*/
int lshapesDrawRectanglePro( lua_State *L ) {
Rectangle rec = uluaGetRectangle( L, 1 );
Vector2 origin = uluaGetVector2( L, 2 );
float rotation = luaL_checknumber( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawRectanglePro( rec, origin, rotation, color );
return 0;
}
/*
> RL.DrawRectangleGradientV( Rectangle rectangle, Color color1, Color color2 )
Draw a vertical-gradient-filled rectangle
*/
int lshapesDrawRectangleGradientV( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
Color color1 = uluaGetColor( L, 2 );
Color color2 = uluaGetColor( L, 3 );
DrawRectangleGradientV( rect.x, rect.y, rect.width, rect.height, color1, color2 );
return 0;
}
/*
> RL.DrawRectangleGradientH( Rectangle rectangle, Color color1, Color color2 )
Draw a horizontal-gradient-filled rectangle
*/
int lshapesDrawRectangleGradientH( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
Color color1 = uluaGetColor( L, 2 );
Color color2 = uluaGetColor( L, 3 );
DrawRectangleGradientH( rect.x, rect.y, rect.width, rect.height, color1, color2 );
return 0;
}
/*
> RL.DrawRectangleGradientEx( Rectangle rectangle, Color col1, Color col2, Color col3, Color col4 )
Draw a gradient-filled rectangle with custom vertex colors
*/
int lshapesDrawRectangleGradientEx( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
Color color1 = uluaGetColor( L, 2 );
Color color2 = uluaGetColor( L, 3 );
Color color3 = uluaGetColor( L, 4 );
Color color4 = uluaGetColor( L, 5 );
DrawRectangleGradientEx( rect, color1, color2, color3, color4 );
return 0;
}
/*
> RL.DrawRectangleLines( Rectangle rec, Color color )
Draw rectangle outline
*/
int lshapesDrawRectangleLines( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
Color color = uluaGetColor( L, 2 );
DrawRectangleLines( rect.x, rect.y, rect.width, rect.height, color );
return 0;
}
/*
> RL.DrawRectangleLinesEx( Rectangle rec, int lineThick, Color color )
Draw rectangle outline with extended parameters
*/
int lshapesDrawRectangleLinesEx( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
int lineThick = luaL_checkinteger( L, 2 );
Color color = uluaGetColor( L, 3 );
DrawRectangleLinesEx( rect, lineThick, color );
return 0;
}
/*
> RL.DrawRectangleRounded( Rectangle rec, float roundness, int segments, Color color )
Draw rectangle with rounded edges
*/
int lshapesDrawRectangleRounded( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
float roundness = luaL_checknumber( L, 2 );
int segments = luaL_checkinteger( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawRectangleRounded( rect, roundness, segments, color );
return 0;
}
/*
> RL.DrawRectangleRoundedLines( Rectangle rec, float roundness, int segments, int lineThick, Color color )
Draw rectangle with rounded edges outline
*/
int lshapesDrawRectangleRoundedLines( lua_State *L ) {
Rectangle rect = uluaGetRectangle( L, 1 );
float roundness = luaL_checknumber( L, 2 );
int segments = luaL_checkinteger( L, 3 );
int lineThick = luaL_checkinteger( L, 4 );
Color color = uluaGetColor( L, 5 );
DrawRectangleRoundedLines( rect, roundness, segments, lineThick, color );
return 0;
}
/*
> RL.DrawTriangle( Vector2 v1, Vector2 v2, Vector2 v3, Color color )
Draw a color-filled triangle (Vertex in counter-clockwise order!)
*/
int lshapesDrawTriangle( lua_State *L ) {
Vector2 v1 = uluaGetVector2( L, 1 );
Vector2 v2 = uluaGetVector2( L, 2 );
Vector2 v3 = uluaGetVector2( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawTriangle( v1, v2, v3, color );
return 0;
}
/*
> RL.DrawTriangleLines( Vector2 v1, Vector2 v2, Vector2 v3, Color color )
Draw triangle outline (Vertex in counter-clockwise order!)
*/
int lshapesDrawTriangleLines( lua_State *L ) {
Vector2 v1 = uluaGetVector2( L, 1 );
Vector2 v2 = uluaGetVector2( L, 2 );
Vector2 v3 = uluaGetVector2( L, 3 );
Color color = uluaGetColor( L, 4 );
DrawTriangleLines( v1, v2, v3, color );
return 0;
}
/*
> RL.DrawTriangleFan( Vector2{} points, Color color )
Draw a triangle fan defined by points (first vertex is the center)
*/
int lshapesDrawTriangleFan( lua_State *L ) {
int pointsCount = uluaGetTableLen( L, 1 );
Color color = uluaGetColor( L, 2 );
Vector2 points[ pointsCount ];
/* t = points index. */
int t = 1, i = 0;
lua_pushnil( L );
while ( lua_next( L, t ) != 0 ) {
points[i] = uluaGetVector2( L, lua_gettop( L ) );
i++;
lua_pop( L, 1 );
}
DrawTriangleFan( points, pointsCount, color );
return 0;
}
/*
> RL.DrawTriangleStrip( Vector2{} points, Color color )
Draw a triangle strip defined by points
*/
int lshapesDrawTriangleStrip( lua_State *L ) {
int pointsCount = uluaGetTableLen( L, 1 );
Color color = uluaGetColor( L, 2 );
Vector2 points[ pointsCount ];
/* t = points index. */
int t = 1, i = 0;
lua_pushnil( L );
while ( lua_next( L, t ) != 0 ) {
points[i] = uluaGetVector2( L, lua_gettop( L ) );
i++;
lua_pop( L, 1 );
}
DrawTriangleStrip( points, pointsCount, color );
return 0;
}
/*
> RL.DrawPoly( Vector2 center, int sides, float radius, float rotation, Color color )
Draw a regular polygon (Vector version)
*/
int lshapesDrawPoly( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
int sides = luaL_checkinteger( L, 2 );
float radius = luaL_checknumber( L, 3 );
float rotation = luaL_checknumber( L, 4 );
Color color = uluaGetColor( L, 5 );
DrawPoly( center, sides, radius, rotation, color );
return 0;
}
/*
> RL.DrawPolyLines( Vector2 center, int sides, float radius, float rotation, Color color )
Draw a polygon outline of n sides
*/
int lshapesDrawPolyLines( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
int sides = luaL_checkinteger( L, 2 );
float radius = luaL_checknumber( L, 3 );
float rotation = luaL_checknumber( L, 4 );
Color color = uluaGetColor( L, 5 );
DrawPolyLines( center, sides, radius, rotation, color );
return 0;
}
/*
> RL.DrawPolyLinesEx( Vector2 center, int sides, float radius, float rotation, float lineThick, Color color )
Draw a polygon outline of n sides with extended parameters
*/
int lshapesDrawPolyLinesEx( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
int sides = luaL_checkinteger( L, 2 );
float radius = luaL_checknumber( L, 3 );
float rotation = luaL_checknumber( L, 4 );
float lineThick = luaL_checknumber( L, 5 );
Color color = uluaGetColor( L, 6 );
DrawPolyLinesEx( center, sides, radius, rotation, lineThick, color );
return 0;
}
/*
## Shapes - Basic shapes collision detection functions
*/
/*
> collision = RL.CheckCollisionRecs( Rectangle rec1, Rectangle rec2 )
Check collision between two rectangles
- Success return bool
*/
int lshapesCheckCollisionRecs( lua_State *L ) {
Rectangle rect1 = uluaGetRectangle( L, 1 );
Rectangle rect2 = uluaGetRectangle( L, 2 );
lua_pushboolean( L, CheckCollisionRecs( rect1, rect2 ) );
return 1;
}
/*
> collision = RL.CheckCollisionCircles( Vector2 center1, float radius1, Vector2 center2, float radius2 )
Check collision between two circles
- Success return bool
*/
int lshapesCheckCollisionCircles( lua_State *L ) {
Vector2 center1 = uluaGetVector2( L, 1 );
float radius1 = luaL_checknumber( L, 2 );
Vector2 center2 = uluaGetVector2( L, 3 );
float radius2 = luaL_checknumber( L, 4 );
lua_pushboolean( L, CheckCollisionCircles( center1, radius1, center2, radius2 ) );
return 1;
}
/*
> collision = RL.CheckCollisionCircleRec( Vector2 center, float radius, Rectangle rec )
Check collision between circle and rectangle
- Success return bool
*/
int lshapesCheckCollisionCircleRec( lua_State *L ) {
Vector2 center = uluaGetVector2( L, 1 );
float radius = luaL_checknumber( L, 2 );
Rectangle rec = uluaGetRectangle( L, 3 );
lua_pushboolean( L, CheckCollisionCircleRec( center, radius, rec ) );
return 1;
}
/*
> collision = RL.CheckCollisionPointRec( Vector2 point, Rectangle rec )
Check if point is inside rectangle
- Success return bool
*/
int lshapesCheckCollisionPointRec( lua_State *L ) {
Vector2 point = uluaGetVector2( L, 1 );
Rectangle rec = uluaGetRectangle( L, 2 );
lua_pushboolean( L, CheckCollisionPointRec( point, rec ) );
return 1;
}
/*
> collision = RL.CheckCollisionPointCircle( Vector2 point, Vector2 center, float radius )
Check if point is inside circle
- Success return bool
*/
int lshapesCheckCollisionPointCircle( lua_State *L ) {
Vector2 point = uluaGetVector2( L, 1 );
Vector2 center = uluaGetVector2( L, 2 );
float radius = luaL_checknumber( L, 3 );
lua_pushboolean( L, CheckCollisionPointCircle( point, center, radius ) );
return 1;
}
/*
> collision = RL.CheckCollisionPointTriangle( Vector2 point, Vector2 p1, Vector2 p2, Vector2 p3 )
Check if point is inside a triangle
- Success return bool
*/
int lshapesCheckCollisionPointTriangle( lua_State *L ) {
Vector2 point = uluaGetVector2( L, 1 );
Vector2 p1 = uluaGetVector2( L, 2 );
Vector2 p2 = uluaGetVector2( L, 3 );
Vector2 p3 = uluaGetVector2( L, 4 );
lua_pushboolean( L, CheckCollisionPointTriangle( point, p1, p2, p3 ) );
return 1;
}
/*
> collision = RL.CheckCollisionPointPoly( Vector2 point, Vector2{} points )
Check if point is within a polygon described by array of vertices
- Success return bool
*/
int lshapesCheckCollisionPointPoly( lua_State *L ) {
Vector2 point = uluaGetVector2( L, 1 );
int pointCount = uluaGetTableLen( L, 2 );
Vector2 points[ pointCount ];
/* t = points index. */
int t = 2, i = 0;
lua_pushnil( L );
while ( lua_next( L, t ) != 0 ) {
points[i] = uluaGetVector2( L, lua_gettop( L ) );
i++;
lua_pop( L, 1 );
}
lua_pushboolean( L, CheckCollisionPointPoly( point, points, pointCount ) );
return 1;
}
/*
> collision, position = RL.CheckCollisionLines( Vector2 startPos1, Vector2 endPos1, Vector2 startPos2, Vector2 endPos2 )
Check the collision between two lines defined by two points each, returns collision point by reference
- Success return bool, Vector2
*/
int lshapesCheckCollisionLines( lua_State *L ) {
Vector2 startPos1 = uluaGetVector2( L, 1 );
Vector2 endPos1 = uluaGetVector2( L, 2 );
Vector2 startPos2 = uluaGetVector2( L, 3 );
Vector2 endPos2 = uluaGetVector2( L, 4 );
Vector2 colPoint = { 0, 0 };
lua_pushboolean( L, CheckCollisionLines( startPos1, endPos1, startPos2, endPos2, &colPoint ) );
uluaPushVector2( L, colPoint );
return 2;
}
/*
> collision = RL.CheckCollisionPointLine( Vector2 point, Vector2 p1, Vector2 p2, int threshold )
Check if point belongs to line created between two points [p1] and [p2] with defined margin in pixels [threshold]
- Success return bool
*/
int lshapesCheckCollisionPointLine( lua_State *L ) {
Vector2 point = uluaGetVector2( L, 1 );
Vector2 p1 = uluaGetVector2( L, 2 );
Vector2 p2 = uluaGetVector2( L, 3 );
int threshold = luaL_checkinteger( L, 4 );
lua_pushboolean( L, CheckCollisionPointLine( point, p1, p2, threshold ) );
return 1;
}
/*
> rectangle = RL.GetCollisionRec( Rectangle rec1, Rectangle rec2 )
Get collision rectangle for two rectangles collision
- Success return Rectangle
*/
int lshapesGetCollisionRec( lua_State *L ) {
Rectangle rec1 = uluaGetRectangle( L, 1 );
Rectangle rec2 = uluaGetRectangle( L, 2 );
uluaPushRectangle( L, GetCollisionRec( rec1, rec2 ) );
return 1;
}
|