Normand Briere
2019-05-05 623dc0fa8cbd9473830a1786f6d49fa808a09439
Mocap.java
....@@ -921,7 +921,7 @@
921921 // //GetFileRoot();
922922
923923 // sept 2014: //
924
- GrafreeD.RENDERME = 3; // patch for Merge objects
924
+ Grafreed.RENDERME = 3; // patch for Merge objects
925925 float[] thedata = bvh.animation.getBoneData(0);
926926
927927 os.x = (float) (path.get(i).toParent[3][0]); // - thedata[frame*6]);
....@@ -1566,7 +1566,7 @@
15661566
15671567 lastsoundtime = Globals.framecount;
15681568
1569
- GrafreeD.hassound = true;
1569
+ Grafreed.hassound = true;
15701570 }
15711571 // else
15721572 // System.out.println("skipped");
....@@ -3299,23 +3299,40 @@
32993299 // SetPositionDelta(false, true, false); // ?? false);
33003300 {
33013301 if (support == null)
3302
- ObjEditor.LoadBVHFile(fullname, this, false, beginframe, lastframetest);
3302
+ {
3303
+ if (new File(fullname).exists())
3304
+ ObjEditor.LoadBVHFile(fullname, this, false, beginframe, lastframetest);
3305
+ else
3306
+ {
3307
+ SetGlobalTransform();
3308
+ Rewind();
3309
+ Fade();
3310
+ }
3311
+ }
33033312 else
33043313 {
3305
- try
3306
- {
3314
+// try
3315
+// {
33073316 bvh = ((Mocap)support.get(mocapsupport++ % support.Size())).bvh;
33083317
33093318 // SetPositionDelta(false, true, true, true);
33103319 LoadData();
33113320 Rewind();
33123321 Fade();
3313
- }
3314
- catch (Exception e)
3315
- {
3316
- e.printStackTrace();
3317
- ObjEditor.LoadBVHFile(fullname, this, false, beginframe, lastframetest);
3318
- }
3322
+// }
3323
+// catch (Exception e)
3324
+// {
3325
+// System.err.println("An error occured while loading data. Use fallback by loading the file.");
3326
+// //e.printStackTrace();
3327
+// try
3328
+// {
3329
+// ObjEditor.LoadBVHFile(fullname, this, false, beginframe, lastframetest);
3330
+// }
3331
+// catch (Exception e2)
3332
+// {
3333
+// System.err.println("Motion file not found: " + fullname);
3334
+// }
3335
+// }
33193336 }
33203337 }
33213338