From: Douglas S. B. <db...@br...> - 2004-06-24 20:16:42
|
Attaching the ObserverCam inside the robot model works well with the latest CVS; thanks! That should do the trick (might need a "steadycam" interface later :). I also tried attaching a ptz to it, so that I could adjust the view if necessary. However, playerv choked via libplayerc: playerv : error in dev_ptz.c libplayerc error: requested [97] access, but got [101] access If I attach a gz_ptz to the ObserverCam, should I be able to adjust it? Here's part of my config: ptz:0 ( driver "gz_ptz" gz_id "usercam1" ) camera:0 ( driver "gz_camera" gz_id "usercam1" ) and part of the world: ... <model:Pioneer2DX> <id>robot1</id> <xyz>-0.35 0 0.25</xyz> <rpy>0 0 0</rpy> <model:Pioneer2Sonars> <id>sonars1</id> </model:Pioneer2Sonars> <model:ObserverCam> <id>usercam1</id> <xyz>-0.685 -2.5 1.1</xyz> <rpy>0.0 10.0 56.0</rpy> <updatePeriod>0.1</updatePeriod> <displayRays>true</displayRays> <window> <title>Gazebo1</title> <size>640 480</size> <xyz>0 0</xyz> </window> </model:ObserverCam> <model:SickLMS200> ... </model:SickLMS200> ... Although, I think I can get the camera in the right place (not too far, not too close) and this method should work nicely without having to adjust it. -Doug Nate Koenig wrote: > The ObserverCam needed a bit of tweaking to make following work. A new > version has been put back to CVS that will allow you to attach an > ObserverCam to another model. > > -nate > > On Wed, 23 Jun 2004 18:21:48 -0700 (PDT), ahoward > <ah...@po...> wrote: > >> >>Actually, I think you can just add an observer camera as a child of the >>robot model (in the world file). No hacking needed, and it will give you >>a fixed "over the shoulder" viewpoint. >> >> A. >> >>On Wed, 23 Jun 2004, Nate Koenig wrote: >> >> >>>Hi Doug, >>> >>>Moving the camera relative to the robot or programmatically is >>>something that hasn't been done yet. In the current implementation, >>>the best you can do is place a SonyVID30 camera ontop of the robot to >>>give a robot-perspective view of the world. >>> >>>A simple solution to this problem would involve attaching a Truth >>>model to an ObserverCamera. Then your player client code could control >>>the Camera to move anywhere it wanted. This would require a few >>>changes within the ObserverCam Model. >>> >>>Another alternative, which would probably result in a less jumpy >>>video, would involve attaching a slider joint between the camera and >>>the robot. The joint would maintain the relative position of the >>>camera to the robot. This again would take some hacking of the Camera >>>and Pioneer models. >>> >>>If you come up with a solution, please let us know. >>> >>>-nate >>> >>> >>> >>>On Wed, 23 Jun 2004 18:42:21 +0000, Douglas S. Blank >>><db...@br...> wrote: >>> >>>>Ok, the shell script to handle the pids was trivial and the right way to go; >>>>thanks! :) I have gazebo/player starting and stopping, and have our Python >>>>code moving the robots about. Woohoo! >>>> >>>>Now, what would it take to have the GL view follow a particular robot around? >>>>That is, what would it take to have the GL camera be a relative location from >>>>a robot's x,y,z? Optionally, it would be nice to make the direction of the GL >>>>view be relative to the robot's direction, so that you can watch "over its >>>>shoulder" as it moves about. >>>> >>>>I didn't see any commands in the gazebo interface to move the view >>>>programmatically. Did I miss it? Thanks! >>>> >>>>-Doug >>>> -- Douglas S. Blank, Assistant Professor db...@br..., (610)526-6501 Bryn Mawr College, Computer Science Program 101 North Merion Ave, Park Science Bld. Bryn Mawr, PA 19010 dangermouse.brynmawr.edu |