Fawkes API  Fawkes Development Version
pointcloud.cpp
00001 
00002 /***************************************************************************
00003  *  pcl.cpp - Fawkes PointCloudAspect initializer/finalizer
00004  *
00005  *  Created: Mon Nov 07 13:37:38 2011
00006  *  Copyright  2006-2011  Tim Niemueller [www.niemueller.de]
00007  *
00008  ****************************************************************************/
00009 
00010 /*  This program is free software; you can redistribute it and/or modify
00011  *  it under the terms of the GNU General Public License as published by
00012  *  the Free Software Foundation; either version 2 of the License, or
00013  *  (at your option) any later version. A runtime exception applies to
00014  *  this software (see LICENSE.GPL_WRE file mentioned below for details).
00015  *
00016  *  This program is distributed in the hope that it will be useful,
00017  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019  *  GNU Library General Public License for more details.
00020  *
00021  *  Read the full text in the LICENSE.GPL_WRE file in the doc directory.
00022  */
00023 
00024 #include <aspect/inifins/pointcloud.h>
00025 #include <aspect/pointcloud.h>
00026 #include <aspect/pointcloud/pointcloud_manager.h>
00027 
00028 namespace fawkes {
00029 #if 0 /* just to make Emacs auto-indent happy */
00030 }
00031 #endif
00032 
00033 /** @class PointCloudAspectIniFin <aspect/inifins/pointcloud.h>
00034  * Initializer/finalizer for the PointCloudAspect.
00035  * @author Tim Niemueller
00036  */
00037 
00038 /** Constructor. */
00039 PointCloudAspectIniFin::PointCloudAspectIniFin()
00040   : AspectIniFin("PointCloudAspect")
00041 {
00042   __pcl_manager = new PointCloudManager();
00043 }
00044 
00045 
00046 /** Destructor. */
00047 PointCloudAspectIniFin::~PointCloudAspectIniFin()
00048 {
00049   delete __pcl_manager;
00050 }
00051 
00052 void
00053 PointCloudAspectIniFin::init(Thread *thread)
00054 {
00055   PointCloudAspect *pcl_thread;
00056   pcl_thread = dynamic_cast<PointCloudAspect *>(thread);
00057   if (pcl_thread == NULL) {
00058     throw CannotInitializeThreadException("Thread '%s' claims to have the "
00059                                           "PointCloudAspect, but RTTI says it "
00060                                           "has not. ", thread->name());
00061   }
00062 
00063   pcl_thread->init_PointCloudAspect(__pcl_manager);
00064 }
00065 
00066 void
00067 PointCloudAspectIniFin::finalize(Thread *thread)
00068 {
00069 }
00070 
00071 
00072 } // end namespace fawkes