Go to the documentation of this file.00001 #include "ForwardKinematicsService_impl.h"
00002 #include "ForwardKinematics.h"
00003
00004 ForwardKinematicsService_impl::ForwardKinematicsService_impl() : m_comp(NULL)
00005 {
00006 }
00007
00008 ForwardKinematicsService_impl::~ForwardKinematicsService_impl()
00009 {
00010 }
00011
00012
00013 void ForwardKinematicsService_impl::setComp(ForwardKinematics *i_comp)
00014 {
00015 m_comp = i_comp;
00016 }
00017
00018 ::CORBA::Boolean ForwardKinematicsService_impl::selectBaseLink(const char* linkname)
00019 {
00020 return m_comp->selectBaseLink(linkname);
00021 }
00022
00023
00024 ::CORBA::Boolean ForwardKinematicsService_impl::getReferencePose(const char* linkname, RTC::TimedDoubleSeq_out pose)
00025 {
00026 char* frame_name = (char *)strrchr(linkname, ':');
00027 if ( frame_name ) {
00028 ((char *)linkname)[frame_name - linkname] = '\0';
00029 frame_name++;
00030 }
00031 return m_comp->getReferencePose(linkname, pose, frame_name);
00032 }
00033 ::CORBA::Boolean ForwardKinematicsService_impl::getCurrentPose(const char* linkname, RTC::TimedDoubleSeq_out pose)
00034 {
00035 char* frame_name = (char *)strrchr(linkname, ':');
00036 if ( frame_name ) {
00037 ((char *)linkname)[frame_name - linkname] = '\0';
00038 frame_name++;
00039 }
00040 return m_comp->getCurrentPose(linkname, pose, frame_name);
00041 }
00042
00043 ::CORBA::Boolean ForwardKinematicsService_impl::getRelativeCurrentPosition(const char* linknameFrom, const char *linknameTo, const OpenHRP::ForwardKinematicsService::position target, OpenHRP::ForwardKinematicsService::position result)
00044 {
00045 return m_comp->getRelativeCurrentPosition(linknameFrom, linknameTo, target, result);
00046 }