picrate 0.5.0-java → 0.6.0-java

Sign up to get free protection for your applications and to get access to all the features.
Files changed (97) hide show
  1. checksums.yaml +4 -4
  2. data/.mvn/wrapper/maven-wrapper.properties +1 -1
  3. data/CHANGELOG.md +3 -1
  4. data/README.md +1 -1
  5. data/Rakefile +8 -6
  6. data/docs/_editors/geany.md +5 -4
  7. data/docs/_editors/vim.md +6 -0
  8. data/docs/_includes/head.html +1 -0
  9. data/docs/_libraries/control_panel.md +2 -2
  10. data/docs/_libraries/gl_video.md +21 -0
  11. data/docs/_posts/2018-05-06-getting_started.md +10 -9
  12. data/docs/_posts/2018-05-06-install_jruby.md +19 -2
  13. data/docs/_posts/2018-06-26-auto_install_picrate.md +19 -4
  14. data/docs/_posts/2018-11-18-building-gem.md +18 -0
  15. data/docs/_posts/2018-11-27-getting_started_geany.md +38 -0
  16. data/docs/about.md +21 -10
  17. data/docs/assets/android-chrome-192x192.png +0 -0
  18. data/docs/assets/android-chrome-512x512.png +0 -0
  19. data/docs/assets/favicon.ico +0 -0
  20. data/docs/assets/geany.png +0 -0
  21. data/docs/assets/jwishy_picrate.png +0 -0
  22. data/docs/assets/picrate.svg +251 -0
  23. data/docs/index.html +8 -14
  24. data/lib/picrate/runner.rb +6 -2
  25. data/lib/picrate/version.rb +1 -1
  26. data/library/boids/boids.rb +10 -13
  27. data/mvnw +234 -0
  28. data/picrate.gemspec +2 -1
  29. data/pom.rb +1 -1
  30. data/pom.xml +1 -1
  31. data/src/main/java/japplemenubar/JAppleMenuBar.java +10 -2
  32. data/src/main/java/monkstone/ColorUtil.java +11 -1
  33. data/src/main/java/monkstone/MathToolModule.java +1 -0
  34. data/src/main/java/monkstone/PicrateLibrary.java +1 -0
  35. data/src/main/java/monkstone/fastmath/Deglut.java +1 -0
  36. data/src/main/java/monkstone/noise/SimplexNoise.java +3 -3
  37. data/src/main/java/monkstone/slider/CustomHorizontalSlider.java +1 -1
  38. data/src/main/java/monkstone/slider/CustomVerticalSlider.java +1 -1
  39. data/src/main/java/monkstone/slider/SimpleHorizontalSlider.java +1 -1
  40. data/src/main/java/monkstone/slider/SimpleSlider.java +8 -8
  41. data/src/main/java/monkstone/slider/SimpleVerticalSlider.java +1 -1
  42. data/src/main/java/monkstone/slider/Slider.java +3 -3
  43. data/src/main/java/monkstone/slider/SliderBar.java +1 -1
  44. data/src/main/java/monkstone/slider/SliderGroup.java +1 -1
  45. data/src/main/java/monkstone/vecmath/AppRender.java +1 -0
  46. data/src/main/java/monkstone/vecmath/JRender.java +1 -0
  47. data/src/main/java/monkstone/vecmath/ShapeRender.java +1 -0
  48. data/src/main/java/monkstone/vecmath/vec2/Vec2.java +8 -0
  49. data/src/main/java/monkstone/vecmath/vec3/Vec3.java +1 -0
  50. data/src/main/java/processing/awt/PGraphicsJava2D.java +85 -16
  51. data/src/main/java/processing/awt/PSurfaceAWT.java +1 -1
  52. data/src/main/java/processing/core/PApplet.java +18 -12
  53. data/src/main/java/processing/core/PShape.java +1182 -305
  54. data/src/main/java/processing/core/PStyle.java +1 -1
  55. data/src/main/java/processing/core/PSurface.java +1 -1
  56. data/src/main/java/processing/data/FloatDict.java +196 -54
  57. data/src/main/java/processing/data/FloatList.java +167 -54
  58. data/src/main/java/processing/data/IntDict.java +211 -56
  59. data/src/main/java/processing/data/IntList.java +185 -52
  60. data/src/main/java/processing/data/JSONArray.java +69 -20
  61. data/src/main/java/processing/data/JSONObject.java +53 -12
  62. data/src/main/java/processing/data/Sort.java +40 -10
  63. data/src/main/java/processing/data/StringDict.java +159 -49
  64. data/src/main/java/processing/data/StringList.java +147 -42
  65. data/src/main/java/processing/data/Table.java +778 -223
  66. data/src/main/java/processing/data/TableRow.java +26 -2
  67. data/src/main/java/processing/data/XML.java +190 -50
  68. data/src/main/java/processing/event/Event.java +93 -0
  69. data/src/main/java/processing/event/KeyEvent.java +55 -13
  70. data/src/main/java/processing/event/MouseEvent.java +77 -1
  71. data/src/main/java/processing/event/TouchEvent.java +14 -1
  72. data/src/main/java/processing/javafx/PGraphicsFX2D.java +8 -0
  73. data/src/main/java/processing/opengl/FrameBuffer.java +228 -66
  74. data/src/main/java/processing/opengl/LinePath.java +131 -27
  75. data/src/main/java/processing/opengl/LineStroker.java +30 -5
  76. data/src/main/java/processing/opengl/PGL.java +4066 -865
  77. data/src/main/java/processing/opengl/PGraphics2D.java +38 -10
  78. data/src/main/java/processing/opengl/PGraphics3D.java +38 -6
  79. data/src/main/java/processing/opengl/PGraphicsOpenGL.java +1980 -474
  80. data/src/main/java/processing/opengl/PJOGL.java +1460 -248
  81. data/src/main/java/processing/opengl/PShader.java +904 -217
  82. data/src/main/java/processing/opengl/PShapeOpenGL.java +1811 -487
  83. data/src/main/java/processing/opengl/PSurfaceJOGL.java +278 -71
  84. data/src/main/java/processing/opengl/Texture.java +610 -135
  85. data/src/main/java/processing/opengl/VertexBuffer.java +45 -9
  86. data/src/main/resources/icon/icon-1024.png +0 -0
  87. data/src/main/resources/icon/icon-128.png +0 -0
  88. data/src/main/resources/icon/icon-16.png +0 -0
  89. data/src/main/resources/icon/icon-256.png +0 -0
  90. data/src/main/resources/icon/icon-32.png +0 -0
  91. data/src/main/resources/icon/icon-48.png +0 -0
  92. data/src/main/resources/icon/icon-512.png +0 -0
  93. data/src/main/resources/icon/icon-64.png +0 -0
  94. data/vendors/Rakefile +1 -1
  95. metadata +13 -6
  96. data/docs/assets/circle_collisions.png +0 -0
  97. data/docs/favicon.ico +0 -0
@@ -60,17 +60,36 @@ import processing.core.PGraphics;
60
60
  import processing.core.PMatrix3D;
61
61
  import processing.core.PSurface;
62
62
 
63
-
63
+ /**
64
+ *
65
+ * @author Martin Prout
66
+ */
64
67
  public class PJOGL extends PGL {
65
68
  // OpenGL profile to use (2, 3 or 4)
69
+
70
+ /**
71
+ *
72
+ */
66
73
  public static int profile = 2;
67
74
 
68
75
  // User-provided icons to override defaults
76
+
77
+ /**
78
+ *
79
+ */
69
80
  protected static String[] icons = null;
70
81
 
71
82
  // The two windowing toolkits available to use in JOGL:
83
+
84
+ /**
85
+ *
86
+ */
72
87
  public static final int AWT = 0; // http://jogamp.org/wiki/index.php/Using_JOGL_in_AWT_SWT_and_Swing
73
- public static final int NEWT = 1; // http://jogamp.org/jogl/doc/NEWT-Overview.html
88
+
89
+ /**
90
+ *
91
+ */
92
+ public static final int NEWT = 1; // http://jogamp.org/jogl/doc/NEWT-Overview.html
74
93
 
75
94
  // ........................................................
76
95
 
@@ -124,8 +143,16 @@ public class PJOGL extends PGL {
124
143
 
125
144
  // Utility arrays to copy projection/modelview matrices to GL
126
145
 
146
+ /**
147
+ *
148
+ */
149
+
127
150
  protected float[] projMatrix;
128
- protected float[] mvMatrix;
151
+
152
+ /**
153
+ *
154
+ */
155
+ protected float[] mvMatrix;
129
156
 
130
157
  // ........................................................
131
158
 
@@ -142,36 +169,57 @@ public class PJOGL extends PGL {
142
169
 
143
170
  // Initialization, finalization
144
171
 
172
+ /**
173
+ *
174
+ * @param pg
175
+ */
176
+
145
177
 
146
178
  public PJOGL(PGraphicsOpenGL pg) {
147
179
  super(pg);
148
180
  glu = new GLU();
149
181
  }
150
182
 
151
-
152
- @Override
183
+ /**
184
+ *
185
+ * @return
186
+ */
187
+ @Override
153
188
  public Object getNative() {
154
189
  return sketch.getSurface().getNative();
155
190
  }
156
191
 
157
-
158
- @Override
192
+ /**
193
+ *
194
+ * @param fps
195
+ */
196
+ @Override
159
197
  protected void setFrameRate(float fps) {}
160
198
 
161
-
162
- @Override
199
+ /**
200
+ *
201
+ * @param antialias
202
+ */
203
+ @Override
163
204
  protected void initSurface(int antialias) {}
164
205
 
165
-
166
- @Override
206
+ /**
207
+ *
208
+ */
209
+ @Override
167
210
  protected void reinitSurface() {}
168
211
 
169
-
170
- @Override
212
+ /**
213
+ *
214
+ */
215
+ @Override
171
216
  protected void registerListeners() {}
172
217
 
173
-
174
- static public void setIcon(String... icons) {
218
+ /**
219
+ *
220
+ * @param icons
221
+ */
222
+ static public void setIcon(String... icons) {
175
223
  PJOGL.icons = new String[icons.length];
176
224
  PApplet.arrayCopy(icons, PJOGL.icons);
177
225
  }
@@ -181,19 +229,30 @@ public class PJOGL extends PGL {
181
229
 
182
230
  // Public methods to get/set renderer's properties
183
231
 
232
+ /**
233
+ *
234
+ * @param caps
235
+ */
236
+
184
237
 
185
238
  public void setCaps(GLCapabilities caps) {
186
239
  reqNumSamples = caps.getNumSamples();
187
240
  capabilities = caps;
188
241
  }
189
242
 
190
-
191
- public GLCapabilitiesImmutable getCaps() {
243
+ /**
244
+ *
245
+ * @return
246
+ */
247
+ public GLCapabilitiesImmutable getCaps() {
192
248
  return capabilities;
193
249
  }
194
250
 
195
-
196
- public void setFps(float fps) {
251
+ /**
252
+ *
253
+ * @param fps
254
+ */
255
+ public void setFps(float fps) {
197
256
  if (!setFps || targetFps != fps) {
198
257
  if (60 < fps) {
199
258
  // Disables v-sync
@@ -208,20 +267,29 @@ public class PJOGL extends PGL {
208
267
  }
209
268
  }
210
269
 
211
-
212
- @Override
270
+ /**
271
+ *
272
+ * @return
273
+ */
274
+ @Override
213
275
  protected int getDepthBits() {
214
276
  return capabilities.getDepthBits();
215
277
  }
216
278
 
217
-
218
- @Override
279
+ /**
280
+ *
281
+ * @return
282
+ */
283
+ @Override
219
284
  protected int getStencilBits() {
220
285
  return capabilities.getStencilBits();
221
286
  }
222
287
 
223
-
224
- @Override
288
+ /**
289
+ *
290
+ * @return
291
+ */
292
+ @Override
225
293
  protected float getPixelScale() {
226
294
  PSurface surf = sketch.getSurface();
227
295
  if (surf == null) {
@@ -233,8 +301,11 @@ public class PJOGL extends PGL {
233
301
  }
234
302
  }
235
303
 
236
-
237
- @Override
304
+ /**
305
+ *
306
+ * @param pgl
307
+ */
308
+ @Override
238
309
  protected void getGL(PGL pgl) {
239
310
  PJOGL pjogl = (PJOGL)pgl;
240
311
 
@@ -250,8 +321,11 @@ public class PJOGL extends PGL {
250
321
  this.gl3es3 = pjogl.gl3es3;
251
322
  }
252
323
 
253
-
254
- public void getGL(GLAutoDrawable glDrawable) {
324
+ /**
325
+ *
326
+ * @param glDrawable
327
+ */
328
+ public void getGL(GLAutoDrawable glDrawable) {
255
329
  context = glDrawable.getContext();
256
330
  glContext = context.hashCode();
257
331
  setThread(Thread.currentThread());
@@ -275,27 +349,38 @@ public class PJOGL extends PGL {
275
349
  }
276
350
  }
277
351
 
278
-
279
- @Override
352
+ /**
353
+ *
354
+ * @return
355
+ */
356
+ @Override
280
357
  protected boolean canDraw() { return true; }
281
358
 
282
-
283
- @Override
359
+ /**
360
+ *
361
+ */
362
+ @Override
284
363
  protected void requestFocus() {}
285
364
 
286
-
287
- @Override
365
+ /**
366
+ *
367
+ */
368
+ @Override
288
369
  protected void requestDraw() {}
289
370
 
290
-
291
- @Override
371
+ /**
372
+ *
373
+ */
374
+ @Override
292
375
  protected void swapBuffers() {
293
376
  PSurfaceJOGL surf = (PSurfaceJOGL)sketch.getSurface();
294
377
  surf.window.swapBuffers();
295
378
  }
296
379
 
297
-
298
- @Override
380
+ /**
381
+ *
382
+ */
383
+ @Override
299
384
  protected void initFBOLayer() {
300
385
  if (0 < sketch.frameCount) {
301
386
  if (isES()) initFBOLayerES();
@@ -355,8 +440,10 @@ public class PJOGL extends PGL {
355
440
  bindFramebufferImpl(FRAMEBUFFER, 0);
356
441
  }
357
442
 
358
-
359
- @Override
443
+ /**
444
+ *
445
+ */
446
+ @Override
360
447
  protected void beginGL() {
361
448
  PMatrix3D proj = graphics.projection;
362
449
  PMatrix3D mdl = graphics.modelview;
@@ -407,22 +494,31 @@ public class PJOGL extends PGL {
407
494
  }
408
495
  }
409
496
 
410
-
411
- @Override
497
+ /**
498
+ *
499
+ * @return
500
+ */
501
+ @Override
412
502
  protected boolean hasFBOs() {
413
503
  if (context.hasBasicFBOSupport()) return true;
414
504
  else return super.hasFBOs();
415
505
  }
416
506
 
417
-
418
- @Override
507
+ /**
508
+ *
509
+ * @return
510
+ */
511
+ @Override
419
512
  protected boolean hasShaders() {
420
513
  if (context.hasGLSL()) return true;
421
514
  else return super.hasShaders();
422
515
  }
423
516
 
424
-
425
- public void init(GLAutoDrawable glDrawable) {
517
+ /**
518
+ *
519
+ * @param glDrawable
520
+ */
521
+ public void init(GLAutoDrawable glDrawable) {
426
522
  capabilities = glDrawable.getChosenGLCapabilities();
427
523
  if (!hasFBOs()) {
428
524
  throw new RuntimeException(MISSING_FBO_ERROR);
@@ -437,6 +533,11 @@ public class PJOGL extends PGL {
437
533
 
438
534
  // Utility functions
439
535
 
536
+ /**
537
+ *
538
+ * @param target
539
+ */
540
+
440
541
 
441
542
  @Override
442
543
  protected void enableTexturing(int target) {
@@ -447,8 +548,11 @@ public class PJOGL extends PGL {
447
548
  }
448
549
  }
449
550
 
450
-
451
- @Override
551
+ /**
552
+ *
553
+ * @param target
554
+ */
555
+ @Override
452
556
  protected void disableTexturing(int target) {
453
557
  if (target == TEXTURE_2D) {
454
558
  texturingTargets[0] = false;
@@ -476,20 +580,35 @@ public class PJOGL extends PGL {
476
580
  return getFontMetrics(font).getFontRenderContext();
477
581
  }
478
582
 
479
-
480
- @Override
583
+ /**
584
+ *
585
+ * @param font
586
+ * @return
587
+ */
588
+ @Override
481
589
  protected int getFontAscent(Object font) {
482
590
  return getFontMetrics((Font) font).getAscent();
483
591
  }
484
592
 
485
-
486
- @Override
593
+ /**
594
+ *
595
+ * @param font
596
+ * @return
597
+ */
598
+ @Override
487
599
  protected int getFontDescent(Object font) {
488
600
  return getFontMetrics((Font) font).getDescent();
489
601
  }
490
602
 
491
-
492
- @Override
603
+ /**
604
+ *
605
+ * @param font
606
+ * @param buffer
607
+ * @param start
608
+ * @param stop
609
+ * @return
610
+ */
611
+ @Override
493
612
  protected int getTextWidth(Object font, char[] buffer, int start, int stop) {
494
613
  // maybe should use one of the newer/fancier functions for this?
495
614
  int length = stop - start;
@@ -497,21 +616,32 @@ public class PJOGL extends PGL {
497
616
  return metrics.charsWidth(buffer, start, length);
498
617
  }
499
618
 
500
-
501
- @Override
619
+ /**
620
+ *
621
+ * @param font
622
+ * @param size
623
+ * @return
624
+ */
625
+ @Override
502
626
  protected Object getDerivedFont(Object font, float size) {
503
627
  return ((Font) font).deriveFont(size);
504
628
  }
505
629
 
506
-
507
- @Override
630
+ /**
631
+ *
632
+ * @return
633
+ */
634
+ @Override
508
635
  protected int getGLSLVersion() {
509
636
  VersionNumber vn = context.getGLSLVersionNumber();
510
637
  return vn.getMajor() * 100 + vn.getMinor();
511
638
  }
512
639
 
513
-
514
- @Override
640
+ /**
641
+ *
642
+ * @return
643
+ */
644
+ @Override
515
645
  protected String getGLSLVersionSuffix() {
516
646
  VersionNumber vn = context.getGLSLVersionNumber();
517
647
  if (context.isGLESProfile() && 1 < vn.getMajor()) {
@@ -521,46 +651,80 @@ public class PJOGL extends PGL {
521
651
  }
522
652
  }
523
653
 
524
-
525
- @Override
654
+ /**
655
+ *
656
+ * @param filename
657
+ * @return
658
+ */
659
+ @Override
526
660
  protected String[] loadVertexShader(String filename) {
527
661
  return loadVertexShader(filename, getGLSLVersion(), getGLSLVersionSuffix());
528
662
  }
529
663
 
530
-
531
- @Override
664
+ /**
665
+ *
666
+ * @param filename
667
+ * @return
668
+ */
669
+ @Override
532
670
  protected String[] loadFragmentShader(String filename) {
533
671
  return loadFragmentShader(filename, getGLSLVersion(), getGLSLVersionSuffix());
534
672
  }
535
673
 
536
-
537
- @Override
674
+ /**
675
+ *
676
+ * @param url
677
+ * @return
678
+ */
679
+ @Override
538
680
  protected String[] loadVertexShader(URL url) {
539
681
  return loadVertexShader(url, getGLSLVersion(), getGLSLVersionSuffix());
540
682
  }
541
683
 
542
-
543
- @Override
684
+ /**
685
+ *
686
+ * @param url
687
+ * @return
688
+ */
689
+ @Override
544
690
  protected String[] loadFragmentShader(URL url) {
545
691
  return loadFragmentShader(url, getGLSLVersion(), getGLSLVersionSuffix());
546
692
  }
547
693
 
548
-
549
- @Override
694
+ /**
695
+ *
696
+ * @param filename
697
+ * @param version
698
+ * @param versionSuffix
699
+ * @return
700
+ */
701
+ @Override
550
702
  protected String[] loadFragmentShader(String filename, int version, String versionSuffix) {
551
703
  String[] fragSrc0 = sketch.loadStrings(filename);
552
704
  return preprocessFragmentSource(fragSrc0, version, versionSuffix);
553
705
  }
554
706
 
555
-
556
- @Override
707
+ /**
708
+ *
709
+ * @param filename
710
+ * @param version
711
+ * @param versionSuffix
712
+ * @return
713
+ */
714
+ @Override
557
715
  protected String[] loadVertexShader(String filename, int version, String versionSuffix) {
558
716
  String[] vertSrc0 = sketch.loadStrings(filename);
559
717
  return preprocessVertexSource(vertSrc0, version, versionSuffix);
560
718
  }
561
719
 
562
-
563
- @Override
720
+ /**
721
+ *
722
+ * @param url
723
+ * @param version
724
+ * @param versionSuffix
725
+ * @return
726
+ */
727
+ @Override
564
728
  protected String[] loadFragmentShader(URL url, int version, String versionSuffix) {
565
729
  try {
566
730
  String[] fragSrc0 = PApplet.loadStrings(url.openStream());
@@ -571,8 +735,14 @@ public class PJOGL extends PGL {
571
735
  return null;
572
736
  }
573
737
 
574
-
575
- @Override
738
+ /**
739
+ *
740
+ * @param url
741
+ * @param version
742
+ * @param versionSuffix
743
+ * @return
744
+ */
745
+ @Override
576
746
  protected String[] loadVertexShader(URL url, int version, String versionSuffix) {
577
747
  try {
578
748
  String[] vertSrc0 = PApplet.loadStrings(url.openStream());
@@ -588,19 +758,43 @@ public class PJOGL extends PGL {
588
758
 
589
759
  // Tessellator
590
760
 
761
+ /**
762
+ *
763
+ * @param callback
764
+ * @return
765
+ */
766
+
591
767
 
592
768
  @Override
593
769
  protected Tessellator createTessellator(TessellatorCallback callback) {
594
770
  return new Tessellator(callback);
595
771
  }
596
772
 
773
+ /**
774
+ *
775
+ */
776
+ protected static class Tessellator implements PGL.Tessellator {
777
+
778
+ /**
779
+ *
780
+ */
781
+ protected GLUtessellator tess;
782
+
783
+ /**
784
+ *
785
+ */
786
+ protected TessellatorCallback callback;
597
787
 
598
- protected static class Tessellator implements PGL.Tessellator {
599
- protected GLUtessellator tess;
600
- protected TessellatorCallback callback;
601
- protected GLUCallback gluCallback;
788
+ /**
789
+ *
790
+ */
791
+ protected GLUCallback gluCallback;
602
792
 
603
- public Tessellator(TessellatorCallback callback) {
793
+ /**
794
+ *
795
+ * @param callback
796
+ */
797
+ public Tessellator(TessellatorCallback callback) {
604
798
  this.callback = callback;
605
799
  tess = GLU.gluNewTess();
606
800
  gluCallback = new GLUCallback();
@@ -612,86 +806,155 @@ public class PJOGL extends PGL {
612
806
  GLU.gluTessCallback(tess, GLU.GLU_TESS_ERROR, gluCallback);
613
807
  }
614
808
 
615
- @Override
809
+ /**
810
+ *
811
+ * @param flag
812
+ */
813
+ @Override
616
814
  public void setCallback(int flag) {
617
815
  GLU.gluTessCallback(tess, flag, gluCallback);
618
816
  }
619
817
 
620
- @Override
818
+ /**
819
+ *
820
+ * @param rule
821
+ */
822
+ @Override
621
823
  public void setWindingRule(int rule) {
622
824
  setProperty(GLU.GLU_TESS_WINDING_RULE, rule);
623
825
  }
624
826
 
625
- public void setProperty(int property, int value) {
827
+ /**
828
+ *
829
+ * @param property
830
+ * @param value
831
+ */
832
+ public void setProperty(int property, int value) {
626
833
  GLU.gluTessProperty(tess, property, value);
627
834
  }
628
835
 
629
- @Override
836
+ /**
837
+ *
838
+ */
839
+ @Override
630
840
  public void beginPolygon() {
631
841
  beginPolygon(null);
632
842
  }
633
843
 
634
- @Override
844
+ /**
845
+ *
846
+ * @param data
847
+ */
848
+ @Override
635
849
  public void beginPolygon(Object data) {
636
850
  GLU.gluTessBeginPolygon(tess, data);
637
851
  }
638
852
 
639
- @Override
853
+ /**
854
+ *
855
+ */
856
+ @Override
640
857
  public void endPolygon() {
641
858
  GLU.gluTessEndPolygon(tess);
642
859
  }
643
860
 
644
- @Override
861
+ /**
862
+ *
863
+ */
864
+ @Override
645
865
  public void beginContour() {
646
866
  GLU.gluTessBeginContour(tess);
647
867
  }
648
868
 
649
- @Override
869
+ /**
870
+ *
871
+ */
872
+ @Override
650
873
  public void endContour() {
651
874
  GLU.gluTessEndContour(tess);
652
875
  }
653
876
 
654
- @Override
877
+ /**
878
+ *
879
+ * @param v
880
+ */
881
+ @Override
655
882
  public void addVertex(double[] v) {
656
883
  addVertex(v, 0, v);
657
884
  }
658
885
 
659
- @Override
886
+ /**
887
+ *
888
+ * @param v
889
+ * @param n
890
+ * @param data
891
+ */
892
+ @Override
660
893
  public void addVertex(double[] v, int n, Object data) {
661
894
  GLU.gluTessVertex(tess, v, n, data);
662
895
  }
663
896
 
664
- protected class GLUCallback extends GLUtessellatorCallbackAdapter {
665
- @Override
897
+ /**
898
+ *
899
+ */
900
+ protected class GLUCallback extends GLUtessellatorCallbackAdapter {
901
+
902
+ /**
903
+ *
904
+ * @param type
905
+ */
906
+ @Override
666
907
  public void begin(int type) {
667
908
  callback.begin(type);
668
909
  }
669
910
 
670
- @Override
911
+ /**
912
+ *
913
+ */
914
+ @Override
671
915
  public void end() {
672
916
  callback.end();
673
917
  }
674
918
 
675
- @Override
919
+ /**
920
+ *
921
+ * @param data
922
+ */
923
+ @Override
676
924
  public void vertex(Object data) {
677
925
  callback.vertex(data);
678
926
  }
679
927
 
680
- @Override
928
+ /**
929
+ *
930
+ * @param coords
931
+ * @param data
932
+ * @param weight
933
+ * @param outData
934
+ */
935
+ @Override
681
936
  public void combine(double[] coords, Object[] data,
682
937
  float[] weight, Object[] outData) {
683
938
  callback.combine(coords, data, weight, outData);
684
939
  }
685
940
 
686
- @Override
941
+ /**
942
+ *
943
+ * @param errnum
944
+ */
945
+ @Override
687
946
  public void error(int errnum) {
688
947
  callback.error(errnum);
689
948
  }
690
949
  }
691
950
  }
692
951
 
693
-
694
- @Override
952
+ /**
953
+ *
954
+ * @param err
955
+ * @return
956
+ */
957
+ @Override
695
958
  protected String tessError(int err) {
696
959
  return glu.gluErrorString(err);
697
960
  }
@@ -711,17 +974,29 @@ public class PJOGL extends PGL {
711
974
  SEG_CLOSE = PathIterator.SEG_CLOSE;
712
975
  }
713
976
 
714
-
715
- @Override
977
+ /**
978
+ *
979
+ * @param ch
980
+ * @param font
981
+ * @return
982
+ */
983
+ @Override
716
984
  protected FontOutline createFontOutline(char ch, Object font) {
717
985
  return new FontOutline(ch, (Font) font);
718
986
  }
719
987
 
720
-
721
- protected class FontOutline implements PGL.FontOutline {
988
+ /**
989
+ *
990
+ */
991
+ protected class FontOutline implements PGL.FontOutline {
722
992
  PathIterator iter;
723
993
 
724
- public FontOutline(char ch, Font font) {
994
+ /**
995
+ *
996
+ * @param ch
997
+ * @param font
998
+ */
999
+ public FontOutline(char ch, Font font) {
725
1000
  char textArray[] = new char[] { ch };
726
1001
  FontRenderContext frc = getFontRenderContext(font);
727
1002
  GlyphVector gv = font.createGlyphVector(frc, textArray);
@@ -729,15 +1004,27 @@ public class PJOGL extends PGL {
729
1004
  iter = shp.getPathIterator(null);
730
1005
  }
731
1006
 
732
- public boolean isDone() {
1007
+ /**
1008
+ *
1009
+ * @return
1010
+ */
1011
+ public boolean isDone() {
733
1012
  return iter.isDone();
734
1013
  }
735
1014
 
736
- public int currentSegment(float coords[]) {
1015
+ /**
1016
+ *
1017
+ * @param coords
1018
+ * @return
1019
+ */
1020
+ public int currentSegment(float coords[]) {
737
1021
  return iter.currentSegment(coords);
738
1022
  }
739
1023
 
740
- public void next() {
1024
+ /**
1025
+ *
1026
+ */
1027
+ public void next() {
741
1028
  iter.next();
742
1029
  }
743
1030
  }
@@ -1047,17 +1334,29 @@ public class PJOGL extends PGL {
1047
1334
 
1048
1335
  // Special Functions
1049
1336
 
1337
+ /**
1338
+ *
1339
+ */
1340
+
1050
1341
  @Override
1051
1342
  public void flush() {
1052
1343
  gl.glFlush();
1053
1344
  }
1054
1345
 
1055
- @Override
1346
+ /**
1347
+ *
1348
+ */
1349
+ @Override
1056
1350
  public void finish() {
1057
1351
  gl.glFinish();
1058
1352
  }
1059
1353
 
1060
- @Override
1354
+ /**
1355
+ *
1356
+ * @param target
1357
+ * @param hint
1358
+ */
1359
+ @Override
1061
1360
  public void hint(int target, int hint) {
1062
1361
  gl.glHint(target, hint);
1063
1362
  }
@@ -1066,6 +1365,11 @@ public class PJOGL extends PGL {
1066
1365
 
1067
1366
  // State and State Requests
1068
1367
 
1368
+ /**
1369
+ *
1370
+ * @param value
1371
+ */
1372
+
1069
1373
  @Override
1070
1374
  public void enable(int value) {
1071
1375
  if (-1 < value) {
@@ -1073,14 +1377,23 @@ public class PJOGL extends PGL {
1073
1377
  }
1074
1378
  }
1075
1379
 
1076
- @Override
1380
+ /**
1381
+ *
1382
+ * @param value
1383
+ */
1384
+ @Override
1077
1385
  public void disable(int value) {
1078
1386
  if (-1 < value) {
1079
1387
  gl.glDisable(value);
1080
1388
  }
1081
1389
  }
1082
1390
 
1083
- @Override
1391
+ /**
1392
+ *
1393
+ * @param value
1394
+ * @param data
1395
+ */
1396
+ @Override
1084
1397
  public void getBooleanv(int value, IntBuffer data) {
1085
1398
  if (-1 < value) {
1086
1399
  if (byteBuffer.capacity() < data.capacity()) {
@@ -1095,7 +1408,12 @@ public class PJOGL extends PGL {
1095
1408
  }
1096
1409
  }
1097
1410
 
1098
- @Override
1411
+ /**
1412
+ *
1413
+ * @param value
1414
+ * @param data
1415
+ */
1416
+ @Override
1099
1417
  public void getIntegerv(int value, IntBuffer data) {
1100
1418
  if (-1 < value) {
1101
1419
  gl.glGetIntegerv(value, data);
@@ -1104,7 +1422,12 @@ public class PJOGL extends PGL {
1104
1422
  }
1105
1423
  }
1106
1424
 
1107
- @Override
1425
+ /**
1426
+ *
1427
+ * @param value
1428
+ * @param data
1429
+ */
1430
+ @Override
1108
1431
  public void getFloatv(int value, FloatBuffer data) {
1109
1432
  if (-1 < value) {
1110
1433
  gl.glGetFloatv(value, data);
@@ -1113,12 +1436,22 @@ public class PJOGL extends PGL {
1113
1436
  }
1114
1437
  }
1115
1438
 
1116
- @Override
1439
+ /**
1440
+ *
1441
+ * @param value
1442
+ * @return
1443
+ */
1444
+ @Override
1117
1445
  public boolean isEnabled(int value) {
1118
1446
  return gl.glIsEnabled(value);
1119
1447
  }
1120
1448
 
1121
- @Override
1449
+ /**
1450
+ *
1451
+ * @param name
1452
+ * @return
1453
+ */
1454
+ @Override
1122
1455
  public String getString(int name) {
1123
1456
  return gl.glGetString(name);
1124
1457
  }
@@ -1127,12 +1460,22 @@ public class PJOGL extends PGL {
1127
1460
 
1128
1461
  // Error Handling
1129
1462
 
1463
+ /**
1464
+ *
1465
+ * @return
1466
+ */
1467
+
1130
1468
  @Override
1131
1469
  public int getError() {
1132
1470
  return gl.glGetError();
1133
1471
  }
1134
1472
 
1135
- @Override
1473
+ /**
1474
+ *
1475
+ * @param err
1476
+ * @return
1477
+ */
1478
+ @Override
1136
1479
  public String errorString(int err) {
1137
1480
  return glu.gluErrorString(err);
1138
1481
  }
@@ -1141,47 +1484,101 @@ public class PJOGL extends PGL {
1141
1484
 
1142
1485
  // Buffer Objects
1143
1486
 
1487
+ /**
1488
+ *
1489
+ * @param n
1490
+ * @param buffers
1491
+ */
1492
+
1144
1493
  @Override
1145
1494
  public void genBuffers(int n, IntBuffer buffers) {
1146
1495
  gl.glGenBuffers(n, buffers);
1147
1496
  }
1148
1497
 
1149
- @Override
1498
+ /**
1499
+ *
1500
+ * @param n
1501
+ * @param buffers
1502
+ */
1503
+ @Override
1150
1504
  public void deleteBuffers(int n, IntBuffer buffers) {
1151
1505
  gl.glDeleteBuffers(n, buffers);
1152
1506
  }
1153
1507
 
1154
- @Override
1508
+ /**
1509
+ *
1510
+ * @param target
1511
+ * @param buffer
1512
+ */
1513
+ @Override
1155
1514
  public void bindBuffer(int target, int buffer) {
1156
1515
  gl.glBindBuffer(target, buffer);
1157
1516
  }
1158
1517
 
1159
- @Override
1518
+ /**
1519
+ *
1520
+ * @param target
1521
+ * @param size
1522
+ * @param data
1523
+ * @param usage
1524
+ */
1525
+ @Override
1160
1526
  public void bufferData(int target, int size, Buffer data, int usage) {
1161
1527
  gl.glBufferData(target, size, data, usage);
1162
1528
  }
1163
1529
 
1164
- @Override
1530
+ /**
1531
+ *
1532
+ * @param target
1533
+ * @param offset
1534
+ * @param size
1535
+ * @param data
1536
+ */
1537
+ @Override
1165
1538
  public void bufferSubData(int target, int offset, int size, Buffer data) {
1166
1539
  gl.glBufferSubData(target, offset, size, data);
1167
1540
  }
1168
1541
 
1169
- @Override
1542
+ /**
1543
+ *
1544
+ * @param buffer
1545
+ */
1546
+ @Override
1170
1547
  public void isBuffer(int buffer) {
1171
1548
  gl.glIsBuffer(buffer);
1172
1549
  }
1173
1550
 
1174
- @Override
1551
+ /**
1552
+ *
1553
+ * @param target
1554
+ * @param value
1555
+ * @param data
1556
+ */
1557
+ @Override
1175
1558
  public void getBufferParameteriv(int target, int value, IntBuffer data) {
1176
1559
  gl.glGetBufferParameteriv(target, value, data);
1177
1560
  }
1178
1561
 
1179
- @Override
1562
+ /**
1563
+ *
1564
+ * @param target
1565
+ * @param access
1566
+ * @return
1567
+ */
1568
+ @Override
1180
1569
  public ByteBuffer mapBuffer(int target, int access) {
1181
1570
  return gl2.glMapBuffer(target, access);
1182
1571
  }
1183
1572
 
1184
- @Override
1573
+ /**
1574
+ *
1575
+ * @param target
1576
+ * @param offset
1577
+ * @param length
1578
+ * @param access
1579
+ * @return
1580
+ */
1581
+ @Override
1185
1582
  public ByteBuffer mapBufferRange(int target, int offset, int length, int access) {
1186
1583
  if (gl2x != null) {
1187
1584
  return gl2x.glMapBufferRange(target, offset, length, access);
@@ -1192,7 +1589,11 @@ public class PJOGL extends PGL {
1192
1589
  }
1193
1590
  }
1194
1591
 
1195
- @Override
1592
+ /**
1593
+ *
1594
+ * @param target
1595
+ */
1596
+ @Override
1196
1597
  public void unmapBuffer(int target) {
1197
1598
  gl2.glUnmapBuffer(target);
1198
1599
  }
@@ -1201,6 +1602,13 @@ public class PJOGL extends PGL {
1201
1602
 
1202
1603
  // Synchronization
1203
1604
 
1605
+ /**
1606
+ *
1607
+ * @param condition
1608
+ * @param flags
1609
+ * @return
1610
+ */
1611
+
1204
1612
  @Override
1205
1613
  public long fenceSync(int condition, int flags) {
1206
1614
  if (gl3es3 != null) {
@@ -1210,7 +1618,11 @@ public class PJOGL extends PGL {
1210
1618
  }
1211
1619
  }
1212
1620
 
1213
- @Override
1621
+ /**
1622
+ *
1623
+ * @param sync
1624
+ */
1625
+ @Override
1214
1626
  public void deleteSync(long sync) {
1215
1627
  if (gl3es3 != null) {
1216
1628
  gl3es3.glDeleteSync(sync);
@@ -1219,7 +1631,14 @@ public class PJOGL extends PGL {
1219
1631
  }
1220
1632
  }
1221
1633
 
1222
- @Override
1634
+ /**
1635
+ *
1636
+ * @param sync
1637
+ * @param flags
1638
+ * @param timeout
1639
+ * @return
1640
+ */
1641
+ @Override
1223
1642
  public int clientWaitSync(long sync, int flags, long timeout) {
1224
1643
  if (gl3es3 != null) {
1225
1644
  return gl3es3.glClientWaitSync(sync, flags, timeout);
@@ -1232,18 +1651,38 @@ public class PJOGL extends PGL {
1232
1651
 
1233
1652
  // Viewport and Clipping
1234
1653
 
1654
+ /**
1655
+ *
1656
+ * @param n
1657
+ * @param f
1658
+ */
1659
+
1235
1660
  @Override
1236
1661
  public void depthRangef(float n, float f) {
1237
1662
  gl.glDepthRangef(n, f);
1238
1663
  }
1239
1664
 
1240
- @Override
1665
+ /**
1666
+ *
1667
+ * @param x
1668
+ * @param y
1669
+ * @param w
1670
+ * @param h
1671
+ */
1672
+ @Override
1241
1673
  public void viewport(int x, int y, int w, int h) {
1242
1674
  float scale = getPixelScale();
1243
1675
  viewportImpl((int)scale * x, (int)(scale * y), (int)(scale * w), (int)(scale * h));
1244
1676
  }
1245
1677
 
1246
- @Override
1678
+ /**
1679
+ *
1680
+ * @param x
1681
+ * @param y
1682
+ * @param w
1683
+ * @param h
1684
+ */
1685
+ @Override
1247
1686
  protected void viewportImpl(int x, int y, int w, int h) {
1248
1687
  gl.glViewport(x, y, w, h);
1249
1688
  }
@@ -1252,12 +1691,33 @@ public class PJOGL extends PGL {
1252
1691
 
1253
1692
  // Reading Pixels
1254
1693
 
1694
+ /**
1695
+ *
1696
+ * @param x
1697
+ * @param y
1698
+ * @param width
1699
+ * @param height
1700
+ * @param format
1701
+ * @param type
1702
+ * @param buffer
1703
+ */
1704
+
1255
1705
  @Override
1256
1706
  protected void readPixelsImpl(int x, int y, int width, int height, int format, int type, Buffer buffer) {
1257
1707
  gl.glReadPixels(x, y, width, height, format, type, buffer);
1258
1708
  }
1259
1709
 
1260
- @Override
1710
+ /**
1711
+ *
1712
+ * @param x
1713
+ * @param y
1714
+ * @param width
1715
+ * @param height
1716
+ * @param format
1717
+ * @param type
1718
+ * @param offset
1719
+ */
1720
+ @Override
1261
1721
  protected void readPixelsImpl(int x, int y, int width, int height, int format, int type, long offset) {
1262
1722
  gl.glReadPixels(x, y, width, height, format, type, 0);
1263
1723
  }
@@ -1266,67 +1726,144 @@ public class PJOGL extends PGL {
1266
1726
 
1267
1727
  // Vertices
1268
1728
 
1729
+ /**
1730
+ *
1731
+ * @param index
1732
+ * @param value
1733
+ */
1734
+
1269
1735
  @Override
1270
1736
  public void vertexAttrib1f(int index, float value) {
1271
1737
  gl2.glVertexAttrib1f(index, value);
1272
1738
  }
1273
1739
 
1274
- @Override
1740
+ /**
1741
+ *
1742
+ * @param index
1743
+ * @param value0
1744
+ * @param value1
1745
+ */
1746
+ @Override
1275
1747
  public void vertexAttrib2f(int index, float value0, float value1) {
1276
1748
  gl2.glVertexAttrib2f(index, value0, value1);
1277
1749
  }
1278
1750
 
1279
- @Override
1751
+ /**
1752
+ *
1753
+ * @param index
1754
+ * @param value0
1755
+ * @param value1
1756
+ * @param value2
1757
+ */
1758
+ @Override
1280
1759
  public void vertexAttrib3f(int index, float value0, float value1, float value2) {
1281
1760
  gl2.glVertexAttrib3f(index, value0, value1, value2);
1282
1761
  }
1283
1762
 
1284
- @Override
1763
+ /**
1764
+ *
1765
+ * @param index
1766
+ * @param value0
1767
+ * @param value1
1768
+ * @param value2
1769
+ * @param value3
1770
+ */
1771
+ @Override
1285
1772
  public void vertexAttrib4f(int index, float value0, float value1, float value2, float value3) {
1286
1773
  gl2.glVertexAttrib4f(index, value0, value1, value2, value3);
1287
1774
  }
1288
1775
 
1289
- @Override
1776
+ /**
1777
+ *
1778
+ * @param index
1779
+ * @param values
1780
+ */
1781
+ @Override
1290
1782
  public void vertexAttrib1fv(int index, FloatBuffer values) {
1291
1783
  gl2.glVertexAttrib1fv(index, values);
1292
1784
  }
1293
1785
 
1294
- @Override
1786
+ /**
1787
+ *
1788
+ * @param index
1789
+ * @param values
1790
+ */
1791
+ @Override
1295
1792
  public void vertexAttrib2fv(int index, FloatBuffer values) {
1296
1793
  gl2.glVertexAttrib2fv(index, values);
1297
1794
  }
1298
1795
 
1299
- @Override
1796
+ /**
1797
+ *
1798
+ * @param index
1799
+ * @param values
1800
+ */
1801
+ @Override
1300
1802
  public void vertexAttrib3fv(int index, FloatBuffer values) {
1301
1803
  gl2.glVertexAttrib3fv(index, values);
1302
1804
  }
1303
1805
 
1304
- @Override
1806
+ /**
1807
+ *
1808
+ * @param index
1809
+ * @param values
1810
+ */
1811
+ @Override
1305
1812
  public void vertexAttrib4fv(int index, FloatBuffer values) {
1306
1813
  gl2.glVertexAttrib4fv(index, values);
1307
1814
  }
1308
1815
 
1309
- @Override
1816
+ /**
1817
+ *
1818
+ * @param index
1819
+ * @param size
1820
+ * @param type
1821
+ * @param normalized
1822
+ * @param stride
1823
+ * @param offset
1824
+ */
1825
+ @Override
1310
1826
  public void vertexAttribPointer(int index, int size, int type, boolean normalized, int stride, int offset) {
1311
1827
  gl2.glVertexAttribPointer(index, size, type, normalized, stride, offset);
1312
1828
  }
1313
1829
 
1314
- @Override
1830
+ /**
1831
+ *
1832
+ * @param index
1833
+ */
1834
+ @Override
1315
1835
  public void enableVertexAttribArray(int index) {
1316
1836
  gl2.glEnableVertexAttribArray(index);
1317
1837
  }
1318
1838
 
1319
- @Override
1839
+ /**
1840
+ *
1841
+ * @param index
1842
+ */
1843
+ @Override
1320
1844
  public void disableVertexAttribArray(int index) {
1321
1845
  gl2.glDisableVertexAttribArray(index);
1322
1846
  }
1323
1847
 
1324
- @Override
1848
+ /**
1849
+ *
1850
+ * @param mode
1851
+ * @param first
1852
+ * @param count
1853
+ */
1854
+ @Override
1325
1855
  public void drawArraysImpl(int mode, int first, int count) {
1326
1856
  gl.glDrawArrays(mode, first, count);
1327
1857
  }
1328
1858
 
1329
- @Override
1859
+ /**
1860
+ *
1861
+ * @param mode
1862
+ * @param count
1863
+ * @param type
1864
+ * @param offset
1865
+ */
1866
+ @Override
1330
1867
  public void drawElementsImpl(int mode, int count, int type, int offset) {
1331
1868
  gl.glDrawElements(mode, count, type, offset);
1332
1869
  }
@@ -1335,22 +1872,40 @@ public class PJOGL extends PGL {
1335
1872
 
1336
1873
  // Rasterization
1337
1874
 
1875
+ /**
1876
+ *
1877
+ * @param width
1878
+ */
1879
+
1338
1880
  @Override
1339
1881
  public void lineWidth(float width) {
1340
1882
  gl.glLineWidth(width);
1341
1883
  }
1342
1884
 
1343
- @Override
1885
+ /**
1886
+ *
1887
+ * @param dir
1888
+ */
1889
+ @Override
1344
1890
  public void frontFace(int dir) {
1345
1891
  gl.glFrontFace(dir);
1346
1892
  }
1347
1893
 
1348
- @Override
1894
+ /**
1895
+ *
1896
+ * @param mode
1897
+ */
1898
+ @Override
1349
1899
  public void cullFace(int mode) {
1350
1900
  gl.glCullFace(mode);
1351
1901
  }
1352
1902
 
1353
- @Override
1903
+ /**
1904
+ *
1905
+ * @param factor
1906
+ * @param units
1907
+ */
1908
+ @Override
1354
1909
  public void polygonOffset(float factor, float units) {
1355
1910
  gl.glPolygonOffset(factor, units);
1356
1911
  }
@@ -1359,6 +1914,12 @@ public class PJOGL extends PGL {
1359
1914
 
1360
1915
  // Pixel Rectangles
1361
1916
 
1917
+ /**
1918
+ *
1919
+ * @param pname
1920
+ * @param param
1921
+ */
1922
+
1362
1923
  @Override
1363
1924
  public void pixelStorei(int pname, int param) {
1364
1925
  gl.glPixelStorei(pname, param);
@@ -1368,92 +1929,226 @@ public class PJOGL extends PGL {
1368
1929
 
1369
1930
  // Texturing
1370
1931
 
1932
+ /**
1933
+ *
1934
+ * @param target
1935
+ * @param level
1936
+ * @param internalFormat
1937
+ * @param width
1938
+ * @param height
1939
+ * @param border
1940
+ * @param format
1941
+ * @param type
1942
+ * @param data
1943
+ */
1944
+
1371
1945
  @Override
1372
1946
  public void texImage2D(int target, int level, int internalFormat, int width, int height, int border, int format, int type, Buffer data) {
1373
1947
  gl.glTexImage2D(target, level, internalFormat, width, height, border, format, type, data);
1374
1948
  }
1375
1949
 
1376
- @Override
1950
+ /**
1951
+ *
1952
+ * @param target
1953
+ * @param level
1954
+ * @param internalFormat
1955
+ * @param x
1956
+ * @param y
1957
+ * @param width
1958
+ * @param height
1959
+ * @param border
1960
+ */
1961
+ @Override
1377
1962
  public void copyTexImage2D(int target, int level, int internalFormat, int x, int y, int width, int height, int border) {
1378
1963
  gl.glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
1379
1964
  }
1380
1965
 
1381
- @Override
1966
+ /**
1967
+ *
1968
+ * @param target
1969
+ * @param level
1970
+ * @param xOffset
1971
+ * @param yOffset
1972
+ * @param width
1973
+ * @param height
1974
+ * @param format
1975
+ * @param type
1976
+ * @param data
1977
+ */
1978
+ @Override
1382
1979
  public void texSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int type, Buffer data) {
1383
1980
  gl.glTexSubImage2D(target, level, xOffset, yOffset, width, height, format, type, data);
1384
1981
  }
1385
1982
 
1386
- @Override
1983
+ /**
1984
+ *
1985
+ * @param target
1986
+ * @param level
1987
+ * @param xOffset
1988
+ * @param yOffset
1989
+ * @param x
1990
+ * @param y
1991
+ * @param width
1992
+ * @param height
1993
+ */
1994
+ @Override
1387
1995
  public void copyTexSubImage2D(int target, int level, int xOffset, int yOffset, int x, int y, int width, int height) {
1388
1996
  gl.glCopyTexSubImage2D(target, level, x, y, xOffset, yOffset, width, height);
1389
1997
  }
1390
1998
 
1391
- @Override
1999
+ /**
2000
+ *
2001
+ * @param target
2002
+ * @param level
2003
+ * @param internalFormat
2004
+ * @param width
2005
+ * @param height
2006
+ * @param border
2007
+ * @param imageSize
2008
+ * @param data
2009
+ */
2010
+ @Override
1392
2011
  public void compressedTexImage2D(int target, int level, int internalFormat, int width, int height, int border, int imageSize, Buffer data) {
1393
2012
  gl.glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
1394
2013
  }
1395
2014
 
1396
- @Override
2015
+ /**
2016
+ *
2017
+ * @param target
2018
+ * @param level
2019
+ * @param xOffset
2020
+ * @param yOffset
2021
+ * @param width
2022
+ * @param height
2023
+ * @param format
2024
+ * @param imageSize
2025
+ * @param data
2026
+ */
2027
+ @Override
1397
2028
  public void compressedTexSubImage2D(int target, int level, int xOffset, int yOffset, int width, int height, int format, int imageSize, Buffer data) {
1398
2029
  gl.glCompressedTexSubImage2D(target, level, xOffset, yOffset, width, height, format, imageSize, data);
1399
2030
  }
1400
2031
 
1401
- @Override
2032
+ /**
2033
+ *
2034
+ * @param target
2035
+ * @param pname
2036
+ * @param param
2037
+ */
2038
+ @Override
1402
2039
  public void texParameteri(int target, int pname, int param) {
1403
2040
  gl.glTexParameteri(target, pname, param);
1404
2041
  }
1405
2042
 
1406
- @Override
2043
+ /**
2044
+ *
2045
+ * @param target
2046
+ * @param pname
2047
+ * @param param
2048
+ */
2049
+ @Override
1407
2050
  public void texParameterf(int target, int pname, float param) {
1408
2051
  gl.glTexParameterf(target, pname, param);
1409
2052
  }
1410
2053
 
1411
- @Override
2054
+ /**
2055
+ *
2056
+ * @param target
2057
+ * @param pname
2058
+ * @param params
2059
+ */
2060
+ @Override
1412
2061
  public void texParameteriv(int target, int pname, IntBuffer params) {
1413
2062
  gl.glTexParameteriv(target, pname, params);
1414
2063
  }
1415
2064
 
1416
- @Override
2065
+ /**
2066
+ *
2067
+ * @param target
2068
+ * @param pname
2069
+ * @param params
2070
+ */
2071
+ @Override
1417
2072
  public void texParameterfv(int target, int pname, FloatBuffer params) {
1418
2073
  gl.glTexParameterfv(target, pname, params);
1419
2074
  }
1420
2075
 
1421
- @Override
2076
+ /**
2077
+ *
2078
+ * @param target
2079
+ */
2080
+ @Override
1422
2081
  public void generateMipmap(int target) {
1423
2082
  gl.glGenerateMipmap(target);
1424
2083
  }
1425
2084
 
1426
- @Override
2085
+ /**
2086
+ *
2087
+ * @param n
2088
+ * @param textures
2089
+ */
2090
+ @Override
1427
2091
  public void genTextures(int n, IntBuffer textures) {
1428
2092
  gl.glGenTextures(n, textures);
1429
2093
  }
1430
2094
 
1431
- @Override
2095
+ /**
2096
+ *
2097
+ * @param n
2098
+ * @param textures
2099
+ */
2100
+ @Override
1432
2101
  public void deleteTextures(int n, IntBuffer textures) {
1433
2102
  gl.glDeleteTextures(n, textures);
1434
2103
  }
1435
2104
 
1436
- @Override
2105
+ /**
2106
+ *
2107
+ * @param target
2108
+ * @param pname
2109
+ * @param params
2110
+ */
2111
+ @Override
1437
2112
  public void getTexParameteriv(int target, int pname, IntBuffer params) {
1438
2113
  gl.glGetTexParameteriv(target, pname, params);
1439
2114
  }
1440
2115
 
1441
- @Override
2116
+ /**
2117
+ *
2118
+ * @param target
2119
+ * @param pname
2120
+ * @param params
2121
+ */
2122
+ @Override
1442
2123
  public void getTexParameterfv(int target, int pname, FloatBuffer params) {
1443
2124
  gl.glGetTexParameterfv(target, pname, params);
1444
2125
  }
1445
2126
 
1446
- @Override
2127
+ /**
2128
+ *
2129
+ * @param texture
2130
+ * @return
2131
+ */
2132
+ @Override
1447
2133
  public boolean isTexture(int texture) {
1448
2134
  return gl.glIsTexture(texture);
1449
2135
  }
1450
2136
 
1451
- @Override
2137
+ /**
2138
+ *
2139
+ * @param texture
2140
+ */
2141
+ @Override
1452
2142
  protected void activeTextureImpl(int texture) {
1453
2143
  gl.glActiveTexture(texture);
1454
2144
  }
1455
2145
 
1456
- @Override
2146
+ /**
2147
+ *
2148
+ * @param target
2149
+ * @param texture
2150
+ */
2151
+ @Override
1457
2152
  protected void bindTextureImpl(int target, int texture) {
1458
2153
  gl.glBindTexture(target, texture);
1459
2154
  }
@@ -1462,67 +2157,131 @@ public class PJOGL extends PGL {
1462
2157
 
1463
2158
  // Shaders and Programs
1464
2159
 
2160
+ /**
2161
+ *
2162
+ * @param type
2163
+ * @return
2164
+ */
2165
+
1465
2166
  @Override
1466
2167
  public int createShader(int type) {
1467
2168
  return gl2.glCreateShader(type);
1468
2169
  }
1469
2170
 
1470
- @Override
2171
+ /**
2172
+ *
2173
+ * @param shader
2174
+ * @param source
2175
+ */
2176
+ @Override
1471
2177
  public void shaderSource(int shader, String source) {
1472
2178
  gl2.glShaderSource(shader, 1, new String[] { source }, (int[]) null, 0);
1473
2179
  }
1474
2180
 
1475
- @Override
2181
+ /**
2182
+ *
2183
+ * @param shader
2184
+ */
2185
+ @Override
1476
2186
  public void compileShader(int shader) {
1477
2187
  gl2.glCompileShader(shader);
1478
2188
  }
1479
2189
 
1480
- @Override
2190
+ /**
2191
+ *
2192
+ */
2193
+ @Override
1481
2194
  public void releaseShaderCompiler() {
1482
2195
  gl2.glReleaseShaderCompiler();
1483
2196
  }
1484
2197
 
1485
- @Override
2198
+ /**
2199
+ *
2200
+ * @param shader
2201
+ */
2202
+ @Override
1486
2203
  public void deleteShader(int shader) {
1487
2204
  gl2.glDeleteShader(shader);
1488
2205
  }
1489
2206
 
1490
- @Override
2207
+ /**
2208
+ *
2209
+ * @param count
2210
+ * @param shaders
2211
+ * @param binaryFormat
2212
+ * @param binary
2213
+ * @param length
2214
+ */
2215
+ @Override
1491
2216
  public void shaderBinary(int count, IntBuffer shaders, int binaryFormat, Buffer binary, int length) {
1492
2217
  gl2.glShaderBinary(count, shaders, binaryFormat, binary, length);
1493
2218
  }
1494
2219
 
1495
- @Override
2220
+ /**
2221
+ *
2222
+ * @return
2223
+ */
2224
+ @Override
1496
2225
  public int createProgram() {
1497
2226
  return gl2.glCreateProgram();
1498
2227
  }
1499
2228
 
1500
- @Override
2229
+ /**
2230
+ *
2231
+ * @param program
2232
+ * @param shader
2233
+ */
2234
+ @Override
1501
2235
  public void attachShader(int program, int shader) {
1502
2236
  gl2.glAttachShader(program, shader);
1503
2237
  }
1504
2238
 
1505
- @Override
2239
+ /**
2240
+ *
2241
+ * @param program
2242
+ * @param shader
2243
+ */
2244
+ @Override
1506
2245
  public void detachShader(int program, int shader) {
1507
2246
  gl2.glDetachShader(program, shader);
1508
2247
  }
1509
2248
 
1510
- @Override
2249
+ /**
2250
+ *
2251
+ * @param program
2252
+ */
2253
+ @Override
1511
2254
  public void linkProgram(int program) {
1512
2255
  gl2.glLinkProgram(program);
1513
2256
  }
1514
2257
 
1515
- @Override
2258
+ /**
2259
+ *
2260
+ * @param program
2261
+ */
2262
+ @Override
1516
2263
  public void useProgram(int program) {
1517
2264
  gl2.glUseProgram(program);
1518
2265
  }
1519
2266
 
1520
- @Override
2267
+ /**
2268
+ *
2269
+ * @param program
2270
+ */
2271
+ @Override
1521
2272
  public void deleteProgram(int program) {
1522
2273
  gl2.glDeleteProgram(program);
1523
2274
  }
1524
2275
 
1525
- @Override
2276
+ /**
2277
+ *
2278
+ * @param program
2279
+ * @param index
2280
+ * @param size
2281
+ * @param type
2282
+ * @return
2283
+ */
2284
+ @Override
1526
2285
  public String getActiveAttrib(int program, int index, IntBuffer size, IntBuffer type) {
1527
2286
  int[] tmp = {0, 0, 0};
1528
2287
  byte[] namebuf = new byte[1024];
@@ -1533,22 +2292,48 @@ public class PJOGL extends PGL {
1533
2292
  return name;
1534
2293
  }
1535
2294
 
1536
- @Override
2295
+ /**
2296
+ *
2297
+ * @param program
2298
+ * @param name
2299
+ * @return
2300
+ */
2301
+ @Override
1537
2302
  public int getAttribLocation(int program, String name) {
1538
2303
  return gl2.glGetAttribLocation(program, name);
1539
2304
  }
1540
2305
 
1541
- @Override
2306
+ /**
2307
+ *
2308
+ * @param program
2309
+ * @param index
2310
+ * @param name
2311
+ */
2312
+ @Override
1542
2313
  public void bindAttribLocation(int program, int index, String name) {
1543
2314
  gl2.glBindAttribLocation(program, index, name);
1544
2315
  }
1545
2316
 
1546
- @Override
2317
+ /**
2318
+ *
2319
+ * @param program
2320
+ * @param name
2321
+ * @return
2322
+ */
2323
+ @Override
1547
2324
  public int getUniformLocation(int program, String name) {
1548
2325
  return gl2.glGetUniformLocation(program, name);
1549
2326
  }
1550
2327
 
1551
- @Override
2328
+ /**
2329
+ *
2330
+ * @param program
2331
+ * @param index
2332
+ * @param size
2333
+ * @param type
2334
+ * @return
2335
+ */
2336
+ @Override
1552
2337
  public String getActiveUniform(int program, int index, IntBuffer size, IntBuffer type) {
1553
2338
  int[] tmp= {0, 0, 0};
1554
2339
  byte[] namebuf = new byte[1024];
@@ -1559,122 +2344,270 @@ public class PJOGL extends PGL {
1559
2344
  return name;
1560
2345
  }
1561
2346
 
1562
- @Override
2347
+ /**
2348
+ *
2349
+ * @param location
2350
+ * @param value
2351
+ */
2352
+ @Override
1563
2353
  public void uniform1i(int location, int value) {
1564
2354
  gl2.glUniform1i(location, value);
1565
2355
  }
1566
2356
 
1567
- @Override
2357
+ /**
2358
+ *
2359
+ * @param location
2360
+ * @param value0
2361
+ * @param value1
2362
+ */
2363
+ @Override
1568
2364
  public void uniform2i(int location, int value0, int value1) {
1569
2365
  gl2.glUniform2i(location, value0, value1);
1570
2366
  }
1571
2367
 
1572
- @Override
2368
+ /**
2369
+ *
2370
+ * @param location
2371
+ * @param value0
2372
+ * @param value1
2373
+ * @param value2
2374
+ */
2375
+ @Override
1573
2376
  public void uniform3i(int location, int value0, int value1, int value2) {
1574
2377
  gl2.glUniform3i(location, value0, value1, value2);
1575
2378
  }
1576
2379
 
1577
- @Override
2380
+ /**
2381
+ *
2382
+ * @param location
2383
+ * @param value0
2384
+ * @param value1
2385
+ * @param value2
2386
+ * @param value3
2387
+ */
2388
+ @Override
1578
2389
  public void uniform4i(int location, int value0, int value1, int value2, int value3) {
1579
2390
  gl2.glUniform4i(location, value0, value1, value2, value3);
1580
2391
  }
1581
2392
 
1582
- @Override
2393
+ /**
2394
+ *
2395
+ * @param location
2396
+ * @param value
2397
+ */
2398
+ @Override
1583
2399
  public void uniform1f(int location, float value) {
1584
2400
  gl2.glUniform1f(location, value);
1585
2401
  }
1586
2402
 
1587
- @Override
2403
+ /**
2404
+ *
2405
+ * @param location
2406
+ * @param value0
2407
+ * @param value1
2408
+ */
2409
+ @Override
1588
2410
  public void uniform2f(int location, float value0, float value1) {
1589
2411
  gl2.glUniform2f(location, value0, value1);
1590
2412
  }
1591
2413
 
1592
- @Override
2414
+ /**
2415
+ *
2416
+ * @param location
2417
+ * @param value0
2418
+ * @param value1
2419
+ * @param value2
2420
+ */
2421
+ @Override
1593
2422
  public void uniform3f(int location, float value0, float value1, float value2) {
1594
2423
  gl2.glUniform3f(location, value0, value1, value2);
1595
2424
  }
1596
2425
 
1597
- @Override
2426
+ /**
2427
+ *
2428
+ * @param location
2429
+ * @param value0
2430
+ * @param value1
2431
+ * @param value2
2432
+ * @param value3
2433
+ */
2434
+ @Override
1598
2435
  public void uniform4f(int location, float value0, float value1, float value2, float value3) {
1599
2436
  gl2.glUniform4f(location, value0, value1, value2, value3);
1600
2437
  }
1601
2438
 
1602
- @Override
2439
+ /**
2440
+ *
2441
+ * @param location
2442
+ * @param count
2443
+ * @param v
2444
+ */
2445
+ @Override
1603
2446
  public void uniform1iv(int location, int count, IntBuffer v) {
1604
2447
  gl2.glUniform1iv(location, count, v);
1605
2448
  }
1606
2449
 
1607
- @Override
2450
+ /**
2451
+ *
2452
+ * @param location
2453
+ * @param count
2454
+ * @param v
2455
+ */
2456
+ @Override
1608
2457
  public void uniform2iv(int location, int count, IntBuffer v) {
1609
2458
  gl2.glUniform2iv(location, count, v);
1610
2459
  }
1611
2460
 
1612
- @Override
2461
+ /**
2462
+ *
2463
+ * @param location
2464
+ * @param count
2465
+ * @param v
2466
+ */
2467
+ @Override
1613
2468
  public void uniform3iv(int location, int count, IntBuffer v) {
1614
2469
  gl2.glUniform3iv(location, count, v);
1615
2470
  }
1616
2471
 
1617
- @Override
2472
+ /**
2473
+ *
2474
+ * @param location
2475
+ * @param count
2476
+ * @param v
2477
+ */
2478
+ @Override
1618
2479
  public void uniform4iv(int location, int count, IntBuffer v) {
1619
2480
  gl2.glUniform4iv(location, count, v);
1620
2481
  }
1621
2482
 
1622
- @Override
2483
+ /**
2484
+ *
2485
+ * @param location
2486
+ * @param count
2487
+ * @param v
2488
+ */
2489
+ @Override
1623
2490
  public void uniform1fv(int location, int count, FloatBuffer v) {
1624
2491
  gl2.glUniform1fv(location, count, v);
1625
2492
  }
1626
2493
 
1627
- @Override
2494
+ /**
2495
+ *
2496
+ * @param location
2497
+ * @param count
2498
+ * @param v
2499
+ */
2500
+ @Override
1628
2501
  public void uniform2fv(int location, int count, FloatBuffer v) {
1629
2502
  gl2.glUniform2fv(location, count, v);
1630
2503
  }
1631
2504
 
1632
- @Override
2505
+ /**
2506
+ *
2507
+ * @param location
2508
+ * @param count
2509
+ * @param v
2510
+ */
2511
+ @Override
1633
2512
  public void uniform3fv(int location, int count, FloatBuffer v) {
1634
2513
  gl2.glUniform3fv(location, count, v);
1635
2514
  }
1636
2515
 
1637
- @Override
2516
+ /**
2517
+ *
2518
+ * @param location
2519
+ * @param count
2520
+ * @param v
2521
+ */
2522
+ @Override
1638
2523
  public void uniform4fv(int location, int count, FloatBuffer v) {
1639
2524
  gl2.glUniform4fv(location, count, v);
1640
2525
  }
1641
2526
 
1642
- @Override
2527
+ /**
2528
+ *
2529
+ * @param location
2530
+ * @param count
2531
+ * @param transpose
2532
+ * @param mat
2533
+ */
2534
+ @Override
1643
2535
  public void uniformMatrix2fv(int location, int count, boolean transpose, FloatBuffer mat) {
1644
2536
  gl2.glUniformMatrix2fv(location, count, transpose, mat);
1645
2537
  }
1646
2538
 
1647
- @Override
2539
+ /**
2540
+ *
2541
+ * @param location
2542
+ * @param count
2543
+ * @param transpose
2544
+ * @param mat
2545
+ */
2546
+ @Override
1648
2547
  public void uniformMatrix3fv(int location, int count, boolean transpose, FloatBuffer mat) {
1649
2548
  gl2.glUniformMatrix3fv(location, count, transpose, mat);
1650
2549
  }
1651
2550
 
1652
- @Override
2551
+ /**
2552
+ *
2553
+ * @param location
2554
+ * @param count
2555
+ * @param transpose
2556
+ * @param mat
2557
+ */
2558
+ @Override
1653
2559
  public void uniformMatrix4fv(int location, int count, boolean transpose, FloatBuffer mat) {
1654
2560
  gl2.glUniformMatrix4fv(location, count, transpose, mat);
1655
2561
  }
1656
2562
 
1657
- @Override
2563
+ /**
2564
+ *
2565
+ * @param program
2566
+ */
2567
+ @Override
1658
2568
  public void validateProgram(int program) {
1659
2569
  gl2.glValidateProgram(program);
1660
2570
  }
1661
2571
 
1662
- @Override
2572
+ /**
2573
+ *
2574
+ * @param shader
2575
+ * @return
2576
+ */
2577
+ @Override
1663
2578
  public boolean isShader(int shader) {
1664
2579
  return gl2.glIsShader(shader);
1665
2580
  }
1666
2581
 
1667
- @Override
2582
+ /**
2583
+ *
2584
+ * @param shader
2585
+ * @param pname
2586
+ * @param params
2587
+ */
2588
+ @Override
1668
2589
  public void getShaderiv(int shader, int pname, IntBuffer params) {
1669
2590
  gl2.glGetShaderiv(shader, pname, params);
1670
2591
  }
1671
2592
 
1672
- @Override
2593
+ /**
2594
+ *
2595
+ * @param program
2596
+ * @param maxCount
2597
+ * @param count
2598
+ * @param shaders
2599
+ */
2600
+ @Override
1673
2601
  public void getAttachedShaders(int program, int maxCount, IntBuffer count, IntBuffer shaders) {
1674
2602
  gl2.glGetAttachedShaders(program, maxCount, count, shaders);
1675
2603
  }
1676
2604
 
1677
- @Override
2605
+ /**
2606
+ *
2607
+ * @param shader
2608
+ * @return
2609
+ */
2610
+ @Override
1678
2611
  public String getShaderInfoLog(int shader) {
1679
2612
  int[] val = { 0 };
1680
2613
  gl2.glGetShaderiv(shader, GL2ES2.GL_INFO_LOG_LENGTH, val, 0);
@@ -1685,7 +2618,12 @@ public class PJOGL extends PGL {
1685
2618
  return new String(log);
1686
2619
  }
1687
2620
 
1688
- @Override
2621
+ /**
2622
+ *
2623
+ * @param shader
2624
+ * @return
2625
+ */
2626
+ @Override
1689
2627
  public String getShaderSource(int shader) {
1690
2628
  int[] len = {0};
1691
2629
  byte[] buf = new byte[1024];
@@ -1693,47 +2631,100 @@ public class PJOGL extends PGL {
1693
2631
  return new String(buf, 0, len[0]);
1694
2632
  }
1695
2633
 
1696
- @Override
2634
+ /**
2635
+ *
2636
+ * @param shaderType
2637
+ * @param precisionType
2638
+ * @param range
2639
+ * @param precision
2640
+ */
2641
+ @Override
1697
2642
  public void getShaderPrecisionFormat(int shaderType, int precisionType, IntBuffer range, IntBuffer precision) {
1698
2643
  gl2.glGetShaderPrecisionFormat(shaderType, precisionType, range, precision);
1699
2644
  }
1700
2645
 
1701
- @Override
2646
+ /**
2647
+ *
2648
+ * @param index
2649
+ * @param pname
2650
+ * @param params
2651
+ */
2652
+ @Override
1702
2653
  public void getVertexAttribfv(int index, int pname, FloatBuffer params) {
1703
2654
  gl2.glGetVertexAttribfv(index, pname, params);
1704
2655
  }
1705
2656
 
1706
- @Override
2657
+ /**
2658
+ *
2659
+ * @param index
2660
+ * @param pname
2661
+ * @param params
2662
+ */
2663
+ @Override
1707
2664
  public void getVertexAttribiv(int index, int pname, IntBuffer params) {
1708
2665
  gl2.glGetVertexAttribiv(index, pname, params);
1709
2666
  }
1710
2667
 
1711
- @Override
2668
+ /**
2669
+ *
2670
+ * @param index
2671
+ * @param pname
2672
+ * @param data
2673
+ */
2674
+ @Override
1712
2675
  public void getVertexAttribPointerv(int index, int pname, ByteBuffer data) {
1713
2676
  throw new RuntimeException(String.format(MISSING_GLFUNC_ERROR, "glGetVertexAttribPointerv()"));
1714
2677
  }
1715
2678
 
1716
- @Override
2679
+ /**
2680
+ *
2681
+ * @param program
2682
+ * @param location
2683
+ * @param params
2684
+ */
2685
+ @Override
1717
2686
  public void getUniformfv(int program, int location, FloatBuffer params) {
1718
2687
  gl2.glGetUniformfv(program, location, params);
1719
2688
  }
1720
2689
 
1721
- @Override
2690
+ /**
2691
+ *
2692
+ * @param program
2693
+ * @param location
2694
+ * @param params
2695
+ */
2696
+ @Override
1722
2697
  public void getUniformiv(int program, int location, IntBuffer params) {
1723
2698
  gl2.glGetUniformiv(program, location, params);
1724
2699
  }
1725
2700
 
1726
- @Override
2701
+ /**
2702
+ *
2703
+ * @param program
2704
+ * @return
2705
+ */
2706
+ @Override
1727
2707
  public boolean isProgram(int program) {
1728
2708
  return gl2.glIsProgram(program);
1729
2709
  }
1730
2710
 
1731
- @Override
2711
+ /**
2712
+ *
2713
+ * @param program
2714
+ * @param pname
2715
+ * @param params
2716
+ */
2717
+ @Override
1732
2718
  public void getProgramiv(int program, int pname, IntBuffer params) {
1733
2719
  gl2.glGetProgramiv(program, pname, params);
1734
2720
  }
1735
2721
 
1736
- @Override
2722
+ /**
2723
+ *
2724
+ * @param program
2725
+ * @return
2726
+ */
2727
+ @Override
1737
2728
  public String getProgramInfoLog(int program) {
1738
2729
  int[] val = { 0 };
1739
2730
  gl2.glGetProgramiv(program, GL2ES2.GL_INFO_LOG_LENGTH, val, 0);
@@ -1752,6 +2743,14 @@ public class PJOGL extends PGL {
1752
2743
 
1753
2744
  // Per-Fragment Operations
1754
2745
 
2746
+ /**
2747
+ *
2748
+ * @param x
2749
+ * @param y
2750
+ * @param w
2751
+ * @param h
2752
+ */
2753
+
1755
2754
  @Override
1756
2755
  public void scissor(int x, int y, int w, int h) {
1757
2756
  float scale = getPixelScale();
@@ -1759,57 +2758,120 @@ public class PJOGL extends PGL {
1759
2758
  // gl.glScissor(x, y, w, h);
1760
2759
  }
1761
2760
 
1762
- @Override
2761
+ /**
2762
+ *
2763
+ * @param value
2764
+ * @param invert
2765
+ */
2766
+ @Override
1763
2767
  public void sampleCoverage(float value, boolean invert) {
1764
2768
  gl2.glSampleCoverage(value, invert);
1765
2769
  }
1766
2770
 
1767
- @Override
2771
+ /**
2772
+ *
2773
+ * @param func
2774
+ * @param ref
2775
+ * @param mask
2776
+ */
2777
+ @Override
1768
2778
  public void stencilFunc(int func, int ref, int mask) {
1769
2779
  gl2.glStencilFunc(func, ref, mask);
1770
2780
  }
1771
2781
 
1772
- @Override
2782
+ /**
2783
+ *
2784
+ * @param face
2785
+ * @param func
2786
+ * @param ref
2787
+ * @param mask
2788
+ */
2789
+ @Override
1773
2790
  public void stencilFuncSeparate(int face, int func, int ref, int mask) {
1774
2791
  gl2.glStencilFuncSeparate(face, func, ref, mask);
1775
2792
  }
1776
2793
 
1777
- @Override
2794
+ /**
2795
+ *
2796
+ * @param sfail
2797
+ * @param dpfail
2798
+ * @param dppass
2799
+ */
2800
+ @Override
1778
2801
  public void stencilOp(int sfail, int dpfail, int dppass) {
1779
2802
  gl2.glStencilOp(sfail, dpfail, dppass);
1780
2803
  }
1781
2804
 
1782
- @Override
2805
+ /**
2806
+ *
2807
+ * @param face
2808
+ * @param sfail
2809
+ * @param dpfail
2810
+ * @param dppass
2811
+ */
2812
+ @Override
1783
2813
  public void stencilOpSeparate(int face, int sfail, int dpfail, int dppass) {
1784
2814
  gl2.glStencilOpSeparate(face, sfail, dpfail, dppass);
1785
2815
  }
1786
2816
 
1787
- @Override
2817
+ /**
2818
+ *
2819
+ * @param func
2820
+ */
2821
+ @Override
1788
2822
  public void depthFunc(int func) {
1789
2823
  gl.glDepthFunc(func);
1790
2824
  }
1791
2825
 
1792
- @Override
2826
+ /**
2827
+ *
2828
+ * @param mode
2829
+ */
2830
+ @Override
1793
2831
  public void blendEquation(int mode) {
1794
2832
  gl.glBlendEquation(mode);
1795
2833
  }
1796
2834
 
1797
- @Override
2835
+ /**
2836
+ *
2837
+ * @param modeRGB
2838
+ * @param modeAlpha
2839
+ */
2840
+ @Override
1798
2841
  public void blendEquationSeparate(int modeRGB, int modeAlpha) {
1799
2842
  gl.glBlendEquationSeparate(modeRGB, modeAlpha);
1800
2843
  }
1801
2844
 
1802
- @Override
2845
+ /**
2846
+ *
2847
+ * @param src
2848
+ * @param dst
2849
+ */
2850
+ @Override
1803
2851
  public void blendFunc(int src, int dst) {
1804
2852
  gl.glBlendFunc(src, dst);
1805
2853
  }
1806
2854
 
1807
- @Override
2855
+ /**
2856
+ *
2857
+ * @param srcRGB
2858
+ * @param dstRGB
2859
+ * @param srcAlpha
2860
+ * @param dstAlpha
2861
+ */
2862
+ @Override
1808
2863
  public void blendFuncSeparate(int srcRGB, int dstRGB, int srcAlpha, int dstAlpha) {
1809
2864
  gl.glBlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
1810
2865
  }
1811
2866
 
1812
- @Override
2867
+ /**
2868
+ *
2869
+ * @param red
2870
+ * @param green
2871
+ * @param blue
2872
+ * @param alpha
2873
+ */
2874
+ @Override
1813
2875
  public void blendColor(float red, float green, float blue, float alpha) {
1814
2876
  gl2.glBlendColor(red, green, blue, alpha);
1815
2877
  }
@@ -1818,42 +2880,82 @@ public class PJOGL extends PGL {
1818
2880
 
1819
2881
  // Whole Framebuffer Operations
1820
2882
 
2883
+ /**
2884
+ *
2885
+ * @param r
2886
+ * @param g
2887
+ * @param b
2888
+ * @param a
2889
+ */
2890
+
1821
2891
  @Override
1822
2892
  public void colorMask(boolean r, boolean g, boolean b, boolean a) {
1823
2893
  gl.glColorMask(r, g, b, a);
1824
2894
  }
1825
2895
 
1826
- @Override
2896
+ /**
2897
+ *
2898
+ * @param mask
2899
+ */
2900
+ @Override
1827
2901
  public void depthMask(boolean mask) {
1828
2902
  gl.glDepthMask(mask);
1829
2903
  }
1830
2904
 
1831
- @Override
2905
+ /**
2906
+ *
2907
+ * @param mask
2908
+ */
2909
+ @Override
1832
2910
  public void stencilMask(int mask) {
1833
2911
  gl.glStencilMask(mask);
1834
2912
  }
1835
2913
 
1836
- @Override
2914
+ /**
2915
+ *
2916
+ * @param face
2917
+ * @param mask
2918
+ */
2919
+ @Override
1837
2920
  public void stencilMaskSeparate(int face, int mask) {
1838
2921
  gl2.glStencilMaskSeparate(face, mask);
1839
2922
  }
1840
2923
 
1841
- @Override
2924
+ /**
2925
+ *
2926
+ * @param r
2927
+ * @param g
2928
+ * @param b
2929
+ * @param a
2930
+ */
2931
+ @Override
1842
2932
  public void clearColor(float r, float g, float b, float a) {
1843
2933
  gl.glClearColor(r, g, b, a);
1844
2934
  }
1845
2935
 
1846
- @Override
2936
+ /**
2937
+ *
2938
+ * @param d
2939
+ */
2940
+ @Override
1847
2941
  public void clearDepth(float d) {
1848
2942
  gl.glClearDepth(d);
1849
2943
  }
1850
2944
 
1851
- @Override
2945
+ /**
2946
+ *
2947
+ * @param s
2948
+ */
2949
+ @Override
1852
2950
  public void clearStencil(int s) {
1853
2951
  gl.glClearStencil(s);
1854
2952
  }
1855
2953
 
1856
- @Override
2954
+ /**
2955
+ *
2956
+ * @param buf
2957
+ */
2958
+ @Override
1857
2959
  public void clear(int buf) {
1858
2960
  gl.glClear(buf);
1859
2961
  }
@@ -1862,77 +2964,171 @@ public class PJOGL extends PGL {
1862
2964
 
1863
2965
  // Framebuffers Objects
1864
2966
 
2967
+ /**
2968
+ *
2969
+ * @param target
2970
+ * @param framebuffer
2971
+ */
2972
+
1865
2973
  @Override
1866
2974
  protected void bindFramebufferImpl(int target, int framebuffer) {
1867
2975
  gl.glBindFramebuffer(target, framebuffer);
1868
2976
  }
1869
2977
 
1870
- @Override
2978
+ /**
2979
+ *
2980
+ * @param n
2981
+ * @param framebuffers
2982
+ */
2983
+ @Override
1871
2984
  public void deleteFramebuffers(int n, IntBuffer framebuffers) {
1872
2985
  gl.glDeleteFramebuffers(n, framebuffers);
1873
2986
  }
1874
2987
 
1875
- @Override
2988
+ /**
2989
+ *
2990
+ * @param n
2991
+ * @param framebuffers
2992
+ */
2993
+ @Override
1876
2994
  public void genFramebuffers(int n, IntBuffer framebuffers) {
1877
2995
  gl.glGenFramebuffers(n, framebuffers);
1878
2996
  }
1879
2997
 
1880
- @Override
2998
+ /**
2999
+ *
3000
+ * @param target
3001
+ * @param renderbuffer
3002
+ */
3003
+ @Override
1881
3004
  public void bindRenderbuffer(int target, int renderbuffer) {
1882
3005
  gl.glBindRenderbuffer(target, renderbuffer);
1883
3006
  }
1884
3007
 
1885
- @Override
3008
+ /**
3009
+ *
3010
+ * @param n
3011
+ * @param renderbuffers
3012
+ */
3013
+ @Override
1886
3014
  public void deleteRenderbuffers(int n, IntBuffer renderbuffers) {
1887
3015
  gl.glDeleteRenderbuffers(n, renderbuffers);
1888
3016
  }
1889
3017
 
1890
- @Override
3018
+ /**
3019
+ *
3020
+ * @param n
3021
+ * @param renderbuffers
3022
+ */
3023
+ @Override
1891
3024
  public void genRenderbuffers(int n, IntBuffer renderbuffers) {
1892
3025
  gl.glGenRenderbuffers(n, renderbuffers);
1893
3026
  }
1894
3027
 
1895
- @Override
3028
+ /**
3029
+ *
3030
+ * @param target
3031
+ * @param internalFormat
3032
+ * @param width
3033
+ * @param height
3034
+ */
3035
+ @Override
1896
3036
  public void renderbufferStorage(int target, int internalFormat, int width, int height) {
1897
3037
  gl.glRenderbufferStorage(target, internalFormat, width, height);
1898
3038
  }
1899
3039
 
1900
- @Override
3040
+ /**
3041
+ *
3042
+ * @param target
3043
+ * @param attachment
3044
+ * @param rendbuferfTarget
3045
+ * @param renderbuffer
3046
+ */
3047
+ @Override
1901
3048
  public void framebufferRenderbuffer(int target, int attachment, int rendbuferfTarget, int renderbuffer) {
1902
3049
  gl.glFramebufferRenderbuffer(target, attachment, rendbuferfTarget, renderbuffer);
1903
3050
  }
1904
3051
 
1905
- @Override
3052
+ /**
3053
+ *
3054
+ * @param target
3055
+ * @param attachment
3056
+ * @param texTarget
3057
+ * @param texture
3058
+ * @param level
3059
+ */
3060
+ @Override
1906
3061
  public void framebufferTexture2D(int target, int attachment, int texTarget, int texture, int level) {
1907
3062
  gl.glFramebufferTexture2D(target, attachment, texTarget, texture, level);
1908
3063
  }
1909
3064
 
1910
- @Override
3065
+ /**
3066
+ *
3067
+ * @param target
3068
+ * @return
3069
+ */
3070
+ @Override
1911
3071
  public int checkFramebufferStatus(int target) {
1912
3072
  return gl.glCheckFramebufferStatus(target);
1913
3073
  }
1914
3074
 
1915
- @Override
3075
+ /**
3076
+ *
3077
+ * @param framebuffer
3078
+ * @return
3079
+ */
3080
+ @Override
1916
3081
  public boolean isFramebuffer(int framebuffer) {
1917
3082
  return gl2.glIsFramebuffer(framebuffer);
1918
3083
  }
1919
3084
 
1920
- @Override
3085
+ /**
3086
+ *
3087
+ * @param target
3088
+ * @param attachment
3089
+ * @param pname
3090
+ * @param params
3091
+ */
3092
+ @Override
1921
3093
  public void getFramebufferAttachmentParameteriv(int target, int attachment, int pname, IntBuffer params) {
1922
3094
  gl2.glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
1923
3095
  }
1924
3096
 
1925
- @Override
3097
+ /**
3098
+ *
3099
+ * @param renderbuffer
3100
+ * @return
3101
+ */
3102
+ @Override
1926
3103
  public boolean isRenderbuffer(int renderbuffer) {
1927
3104
  return gl2.glIsRenderbuffer(renderbuffer);
1928
3105
  }
1929
3106
 
1930
- @Override
3107
+ /**
3108
+ *
3109
+ * @param target
3110
+ * @param pname
3111
+ * @param params
3112
+ */
3113
+ @Override
1931
3114
  public void getRenderbufferParameteriv(int target, int pname, IntBuffer params) {
1932
3115
  gl2.glGetRenderbufferParameteriv(target, pname, params);
1933
3116
  }
1934
3117
 
1935
- @Override
3118
+ /**
3119
+ *
3120
+ * @param srcX0
3121
+ * @param srcY0
3122
+ * @param srcX1
3123
+ * @param srcY1
3124
+ * @param dstX0
3125
+ * @param dstY0
3126
+ * @param dstX1
3127
+ * @param dstY1
3128
+ * @param mask
3129
+ * @param filter
3130
+ */
3131
+ @Override
1936
3132
  public void blitFramebuffer(int srcX0, int srcY0, int srcX1, int srcY1, int dstX0, int dstY0, int dstX1, int dstY1, int mask, int filter) {
1937
3133
  if (gl2x != null) {
1938
3134
  gl2x.glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
@@ -1945,7 +3141,15 @@ public class PJOGL extends PGL {
1945
3141
  }
1946
3142
  }
1947
3143
 
1948
- @Override
3144
+ /**
3145
+ *
3146
+ * @param target
3147
+ * @param samples
3148
+ * @param format
3149
+ * @param width
3150
+ * @param height
3151
+ */
3152
+ @Override
1949
3153
  public void renderbufferStorageMultisample(int target, int samples, int format, int width, int height) {
1950
3154
  if (gl2x != null) {
1951
3155
  gl2x.glRenderbufferStorageMultisample(target, samples, format, width, height);
@@ -1958,7 +3162,11 @@ public class PJOGL extends PGL {
1958
3162
  }
1959
3163
  }
1960
3164
 
1961
- @Override
3165
+ /**
3166
+ *
3167
+ * @param buf
3168
+ */
3169
+ @Override
1962
3170
  public void readBuffer(int buf) {
1963
3171
  if (gl2x != null) {
1964
3172
  gl2x.glReadBuffer(buf);
@@ -1971,7 +3179,11 @@ public class PJOGL extends PGL {
1971
3179
  }
1972
3180
  }
1973
3181
 
1974
- @Override
3182
+ /**
3183
+ *
3184
+ * @param buf
3185
+ */
3186
+ @Override
1975
3187
  public void drawBuffer(int buf) {
1976
3188
  if (gl2x != null) {
1977
3189
  gl2x.glDrawBuffer(buf);