Normand Briere
2019-04-28 f1c718cce66e5651a0dae91375db6ebfaded1a92
GenericJoint.java
....@@ -314,7 +314,7 @@
314314 bRep = null;
315315 }
316316
317
- void DrawNode(CameraPane display, Object3D /*Composite*/ root, boolean selected) // ??
317
+ void DrawNode(iCameraPane display, Object3D /*Composite*/ root, boolean selected) // ??
318318 {
319319 // super.DrawNode(display,root,selected);
320320
....@@ -330,16 +330,18 @@
330330 e.printStackTrace();
331331 }
332332
333
- display.GetGL().glPushMatrix();
333
+ //display.GetGL().glPushMatrix();
334
+ display.PushMatrix(LA.Identity, 1);
334335 Vector3f v = ragdolls.get(0).bodies[0].worldTransform.origin;
335336 // display.GetGL().glTranslatef(-v.x,0,-v.z);
336337
337338 super.DrawNode(display, root, selected);
338
- display.GetGL().glPopMatrix();
339
+ //display.GetGL().glPopMatrix();
340
+ display.PopMatrix(LA.Identity);
339341
340342 // assert(bRep != null);
341343
342
- if (display.isLIVE() && live && display.drawMode == display.SHADOW) // FUCK
344
+ if (Globals.isLIVE() && live && display.DrawMode() == display.SHADOW) // FUCK
343345 {
344346 // float ms = getDeltaTimeMicroseconds();
345347 // float minFPS = 1000000f / 60f;
....@@ -379,7 +381,7 @@
379381 try
380382 {
381383 //font = FontRender.createFont("Dialog", 11, false, true);
382
- font = new FontRender.GLFont(gl, GraphreeD.class.getResourceAsStream("DejaVu_Sans_11.fnt"));
384
+ font = new FontRender.GLFont(gl, GrafreeD.class.getResourceAsStream("DejaVu_Sans_11.fnt"));
383385 } catch (java.io.IOException e)
384386 {
385387 e.printStackTrace();
....@@ -451,9 +453,9 @@
451453 int startvertex;
452454 int currentobject;
453455
454
- public void renderme(CameraPane display)
456
+ public void renderme(iCameraPane display)
455457 {
456
- GL gl = display!=null?display.getGL():null;
458
+ GL gl = display!=null?display.GetGL0():null;
457459
458460 // gl0 = gl;
459461 if (GetDynamicsWorld() != null)
....@@ -796,9 +798,9 @@
796798 }
797799 }
798800
799
- public void drawCube(CameraPane display, float extent)
801
+ public void drawCube(iCameraPane display, float extent)
800802 {
801
- GL gl = display.getGL();
803
+ GL gl = display.GetGL0();
802804
803805 extent = extent * 0.5f;
804806
....@@ -838,7 +840,7 @@
838840
839841 private /*static*/ float[] glMat = new float[16];
840842
841
- public void drawOpenGL(CameraPane display, Transform trans, CollisionShape shape, Vector3f color, int debugMode)
843
+ public void drawOpenGL(iCameraPane display, Transform trans, CollisionShape shape, Vector3f color, int debugMode)
842844 {
843845 GL gl = null; // display.getGL();
844846
....@@ -1522,9 +1524,9 @@
15221524 private static Map<SphereKey, Integer> sphereDisplayLists = new HashMap<SphereKey, Integer>();
15231525 private static SphereKey sphereKey = new SphereKey();
15241526
1525
- public void drawSphere(CameraPane display, float radius, int slices, int stacks)
1527
+ public void drawSphere(iCameraPane display, float radius, int slices, int stacks)
15261528 {
1527
- GL gl = display.getGL();
1529
+ GL gl = display.GetGL0();
15281530
15291531 sphereKey.radius = radius;
15301532 Integer glList = sphereDisplayLists.get(sphereKey);
....@@ -1594,9 +1596,9 @@
15941596 private static Map<CylinderKey, Integer> cylinderDisplayLists = new HashMap<CylinderKey, Integer>();
15951597 private static CylinderKey cylinderKey = new CylinderKey();
15961598
1597
- public void drawCylinder(CameraPane display, float radius, float halfHeight, int upAxis)
1599
+ public void drawCylinder(iCameraPane display, float radius, float halfHeight, int upAxis)
15981600 {
1599
- GL gl = display.getGL();
1601
+ GL gl = display.GetGL0();
16001602
16011603 gl.glPushMatrix();
16021604 switch (upAxis)