Update of /cvsroot/playerstage/code/player/client_libs/libplayerc++
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13931/libplayerc++
Modified Files:
Tag: release-2-0-patches
Makefile.am
Added Files:
Tag: release-2-0-patches
graphics3dproxy.cc
Log Message:
added some files
--- NEW FILE: graphics3dproxy.cc ---
/*
* Player - One Hell of a Robot Server
* Copyright (C) 2000-2003
* Brian Gerkey, Kasper Stoy, Richard Vaughan, & Andrew Howard
*
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
/*
* $Id: graphics3dproxy.cc,v 1.1.2.2 2006/06/09 18:27:45 gerkey Exp $
*/
#include "playerc++.h"
using namespace PlayerCc;
Graphics3dProxy::Graphics3dProxy(PlayerClient *aPc, uint aIndex)
: ClientProxy(aPc, aIndex),
mDevice(NULL)
{
Subscribe(aIndex);
// how can I get this into the clientproxy.cc?
// right now, we're dependent on knowing its device type
mInfo = &(mDevice->info);
}
Graphics3dProxy::~Graphics3dProxy()
{
Unsubscribe();
}
void
Graphics3dProxy::Subscribe(uint aIndex)
{
scoped_lock_t lock(mPc->mMutex);
mDevice = playerc_graphics3d_create(mClient, aIndex);
if (NULL==mDevice)
throw PlayerError("Graphics3dProxy::Graphics3dProxy()", "could not create");
if (0 != playerc_graphics3d_subscribe(mDevice, PLAYER_OPEN_MODE))
throw PlayerError("Graphics3dProxy::Graphics3dProxy()", "could not
subscribe");
}
void
Graphics3dProxy::Unsubscribe()
{
assert(NULL!=mDevice);
scoped_lock_t lock(mPc->mMutex);
playerc_graphics3d_unsubscribe(mDevice);
playerc_graphics3d_destroy(mDevice);
mDevice = NULL;
}
void
Graphics3dProxy::Clear( void )
{
scoped_lock_t lock(mPc->mMutex);
playerc_graphics3d_clear(mDevice);
}
void
Graphics3dProxy::Draw(player_graphics3d_draw_mode_t mode, player_point_3d_t
pts[], int count)
{
scoped_lock_t lock(mPc->mMutex);
playerc_graphics3d_draw(mDevice,mode,pts,count);
}
void
Graphics3dProxy::Color( player_color_t col )
{
scoped_lock_t lock(mPc->mMutex);
playerc_graphics3d_setcolor(mDevice, col);
}
void
Graphics3dProxy::Color( uint8_t red, uint8_t green, uint8_t blue, uint8_t
alpha )
{
player_color_t col;
col.red = red;
col.green = green;
col.blue = blue;
col.alpha = alpha;
this->Color( col );
}
Index: Makefile.am
===================================================================
RCS file:
/cvsroot/playerstage/code/player/client_libs/libplayerc++/Makefile.am,v
retrieving revision 1.36
retrieving revision 1.36.2.1
diff -C2 -d -r1.36 -r1.36.2.1
*** Makefile.am 11 Apr 2006 15:40:31 -0000 1.36
--- Makefile.am 9 Jun 2006 18:27:45 -0000 1.36.2.1
***************
*** 38,41 ****
--- 38,42 ----
gpsproxy.cc \
graphics2dproxy.cc \
+ graphics3dproxy.cc \
gripperproxy.cc \
irproxy.cc \
***************
*** 45,48 ****
--- 46,50 ----
logproxy.cc \
mapproxy.cc \
+ opaqueproxy.cc \
plannerproxy.cc \
position1dproxy.cc \
***************
*** 56,63 ****
speechproxy.cc \
wifiproxy.cc \
! wsnproxy.cc
# not in libplayerc yet \
- aioproxy.cc \
audioproxy.cc \
audiodspproxy.cc \
--- 58,64 ----
speechproxy.cc \
wifiproxy.cc \
! wsnproxy.cc
# not in libplayerc yet \
audioproxy.cc \
audiodspproxy.cc \
***************
*** 66,76 ****
energyproxy.cc \
mcomproxy.cc \
- motorproxy.cc \
- soundproxy.cc \
speechrecognitionproxy.cc \
- truthproxy.cc \
waveformproxy.cc
- # motorproxy.cc
#PLAYERCC_LIB_DIRS=-L${top_builddir}/libplayerxdr \
--- 67,73 ----
***************
*** 83,85 ****
libplayerc___includedir = $(includedir)/player-2.0/libplayerc++
! libplayerc___include_HEADERS = playerc++.h playerclient.h playererror.h
playerc++config.h
--- 80,82 ----
libplayerc___includedir = $(includedir)/player-2.0/libplayerc++
! libplayerc___include_HEADERS = playerc++.h playerclient.h playererror.h
playerc++config.h clientproxy.h utility.h
_______________________________________________
Playerstage-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/playerstage-commit