From: Radu B. R. <ru...@cs...> - 2006-03-26 22:20:51
|
Hi Hugo, Sorry I'm only delivering now, but I've been busy with other things during the weekend. :( Hope it's not too late for your project. Anyway, I just committed the code to CVS, so it should be available for you in the morning. Please ignore the WSNInterface for now, as I'm still working on committing the new wsn interface and drivers to the Player repository first. I haven't had time to test it properly, but here's a "quickie" :)... - Player/Stage 2.x from CVS - started with everything.cfg - and the following code compiled into Javaclient: PlayerClient robot = null; Graphics2DInterface g2di = null; robot = new PlayerClient ("localhost", 6665); g2di = robot.requestInterfaceGraphics2D (0, PlayerConstants.PLAYER_OPEN_MODE); robot.runThreaded (-1, -1); g2di.clearScreen (); PlayerGraphics2dCmdPolyline p = new PlayerGraphics2dCmdPolyline (); PlayerColor color = new PlayerColor (); color.setAlpha (0); color.setRed (0); color.setGreen (0); color.setBlue (0xff); p.setCount (64); for (double r = 0; r < 1.0; r += 0.05) { PlayerPoint2d[] points = new PlayerPoint2d[64]; for (int j = 0; j < 64; j++) { points[j] = new PlayerPoint2d (); points[j].setPx ((float)(r * Math.cos (j * Math.PI / 32))); points[j].setPy ((float)(r * Math.sin (j * Math.PI / 32))); } p.setPoints (points); p.setColor (color); g2di.drawPolyline (p); try { Thread.sleep (100); } catch (Exception e) { e.printStackTrace(); } } --- Please tell me if it works and if you encounter any errors. Cheers, Radu. Hugo Gravato Marques wrote: >Thank you Radu... I really appreciate it... > > > >On 23/3/06 8:42 pm, "Radu Bogdan Rusu" <ru...@cs...> wrote: > > > >>Hi Hugo, >> >>I just returned from Linz/Austria, and will get some free time tomorrow >>afternoon to do it. I will e-mail back tomorrow with more details and >>hopefully an implementation of it. >> >>Best, >>Radu. >> >>Hugo Gravato Marques wrote: >> >> >> >>>Hi Radu... >>> >>>Do you have any idea on when can you implement the Graphics2D interface? It >>>would come really handy if I could use it by the weekend... >>> >>>Thanks... >>>Hugo >>> >>> >>>On 14/3/06 3:42 pm, "Hugo Gravato Marques" <hg...@es...> wrote: >>> >>> >>> >>> >>> >>>>Hi Radu >>>> >>>>Yes... Toby told me they are in the stage side. The interface as far as I >>>>understand is just a visualization... If you could do it next week that >>>>would be wonderful since I don't expect to have things ready until then >>>>anyway... >>>> >>>>I added my email with Toby bellow... >>>> >>>>Thank you very much... >>>> >>>>Regards, >>>>Hugo >>>> >>>>I pasted bellow my email and his reply... >>>> >>>>=========================== EMAILS >>>> >>>>I dont think this would be particularly easy to do, however if you want >>>>to you can create visualisation in stage using the graphics2d interface. >>>>Have a look at the examples in the source and docs on the. i believe >>>>this will be the easiest method for achieving what you want. >>>> >>>>Toby >>>> >>>>Hugo Gravato Marques wrote: >>>> >>>> >>>> >>>> >>>> >>>>>Hello... >>>>> >>>>>I was wondering if I could set the values in the laser sensor in a way that >>>>>I could visualize in stage the values of a given laser array I define? If >>>>>not how difficult would be to make something like that? >>>>> >>>>>Thanks... >>>>>Hugo >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>============================ END OF EMAILS >>>> >>>>On 14/3/06 8:32 am, "Radu Bogdan Rusu" <ru...@cs...> wrote: >>>> >>>> >>>> >>>> >>>> >>>>>Hi Hugo, >>>>> >>>>>Unfortunately, I have no time this week (or I might during the weekend, >>>>>but I will be away in .nl). >>>>> >>>>>Last time I checked there was no data structures defined in player for >>>>>graphics2d. Are they all on Stage's side? >>>>> >>>>>Radu. >>>>> >>>>>Hugo Gravato Marques wrote: >>>>> >>>>> >>>>> >>>>> >>>>> >>>>>>Hello... >>>>>> >>>>>>I was wondering when do you think you will add the Graphics2D interface to >>>>>>the javaclient2? >>>>>> >>>>>>Cheers, >>>>>>Hugo >>>>>> >>>>>> >>>>>> >>>>>> >>>>>>------------------------------------------------------- >>>>>>This SF.Net email is sponsored by xPML, a groundbreaking scripting >>>>>>language >>>>>>that extends applications into web and mobile media. Attend the live >>>>>>webcast >>>>>>and join the prime developer group breaking into this new coding >>>>>>territory! >>>>>>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 >>>>>>_______________________________________________ >>>>>>Java-player-users mailing list >>>>>>Jav...@li... >>>>>>https://lists.sourceforge.net/lists/listinfo/java-player-users >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>------------------------------------------------------- >>>>This SF.Net email is sponsored by xPML, a groundbreaking scripting language >>>>that extends applications into web and mobile media. Attend the live webcast >>>>and join the prime developer group breaking into this new coding territory! >>>>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 >>>>_______________________________________________ >>>>Java-player-users mailing list >>>>Jav...@li... >>>>https://lists.sourceforge.net/lists/listinfo/java-player-users >>>> >>>> >>>> >>>> >>> >>> >>>------------------------------------------------------- >>>This SF.Net email is sponsored by xPML, a groundbreaking scripting language >>>that extends applications into web and mobile media. Attend the live webcast >>>and join the prime developer group breaking into this new coding territory! >>>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 >>>_______________________________________________ >>>Java-player-users mailing list >>>Jav...@li... >>>https://lists.sourceforge.net/lists/listinfo/java-player-users >>> >>> >>> >>> > > > > >------------------------------------------------------- >This SF.Net email is sponsored by xPML, a groundbreaking scripting language >that extends applications into web and mobile media. Attend the live webcast >and join the prime developer group breaking into this new coding territory! >http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 >_______________________________________________ >Java-player-users mailing list >Jav...@li... >https://lists.sourceforge.net/lists/listinfo/java-player-users > > -- | Radu Bogdan Rusu | http://rbrusu.com/ | http://www9.cs.tum.edu/people/rusu/ | Intelligent Autonomous Systems | Technische Universitaet Muenchen |