Laser Sensing Display for UI interfaces in the real world
Fork of skinGames_forktest by
Diff: main.cpp
- Revision:
- 5:73cd58b58f95
- Parent:
- 4:f9d364f10335
- Child:
- 7:0df17f3078bc
--- a/main.cpp Wed Apr 04 10:05:25 2012 +0000 +++ b/main.cpp Thu Apr 05 12:29:14 2012 +0000 @@ -16,7 +16,7 @@ // To test the time it takes for executing one loop in the main program: -//#define LOOPTIMECOMPUTE +#define LOOPTIMECOMPUTE // To get serial commands (for debug, or other things using a Terminal - for instance, a laser scan) //#define SERIAL_COMMANDS @@ -105,21 +105,20 @@ // Tested modes: blobconf.clearConfig(); -// blobconf.addOneElasticLoopContractCentral(); - // blobconf.addOneElasticContourFollowing(); + blobconf.addOneElasticLoopContractCentral(); +// blobconf.addOneElasticContourFollowing(); - blobconf.addOneRigidLoopBouncing(); // blobconf.addOneRigidLoopBouncing(); -// blobconf.addOneRigidLoopBouncing(); -// blobconf.addOneRigidLoopBouncing(); -// blobconf.addOneRigidLoopBouncing(); +// blobconf.addOneRigidLoopFollowing(); -// blobconf.addOneRigidLoopFollowing(); +//blobconf.addOneRigidLoopTest(); // Important: first, set the initial position for all the blobs, this will be useful because // when changing modes we can use the previous central position... // blobconf.setInitialPos(CENTER_AD_MIRROR_X, CENTER_AD_MIRROR_Y); +// draw the config once befor activating the laser buffer: + blobconf.draw(); // RENRERER (attn: setConfigToRender must be called when the blobconf is set - i.e., the number of blobs and number of points/blob is fixed) lsr.setConfigToRender(&blobconf); @@ -200,6 +199,7 @@ sendMes.setTopAddress("/timeloop"); sendMes.setSubAddress("/"); long x=(long)(int(measureLoopPeriod.read_us()/1000.0)); + // long x=(long)(blobconf.blobArray[0]->displaySensingBuffer.lsdTrajectory.size()); sendMes.setArgs( "i", &x); osc.sendOsc( &sendMes ); timeCounterNum=0;