Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

sceneserver_c.cpp

Go to the documentation of this file.
00001 /* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*-
00002 
00003    this file is part of rcssserver3D
00004    Fri May 9 2003
00005    Copyright (C) 2002,2003 Koblenz University
00006    Copyright (C) 2003 RoboCup Soccer Server 3D Maintenance Group
00007    $Id: sceneserver_c.cpp,v 1.5 2004/04/08 14:49:00 rollmark Exp $
00008 
00009    This program is free software; you can redistribute it and/or modify
00010    it under the terms of the GNU General Public License as published by
00011    the Free Software Foundation; version 2 of the License.
00012 
00013    This program is distributed in the hope that it will be useful,
00014    but WITHOUT ANY WARRANTY; without even the implied warranty of
00015    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016    GNU General Public License for more details.
00017 
00018    You should have received a copy of the GNU General Public License
00019    along with this program; if not, write to the Free Software
00020    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00021 
00022    SceneServer
00023 
00024    The scene server manages displayable subtrees within the object
00025    hierarchy. Each subtree begins with a Scene node. The scene server
00026    knows which scene node is currently active and updates/displays
00027    that node (and its corresponding subtree).
00028 */
00029 
00030 #include "sceneserver.h"
00031 
00032 using namespace boost;
00033 using namespace oxygen;
00034 using namespace zeitgeist;
00035 using namespace std;
00036 
00037 FUNCTION(SceneServer,createScene)
00038 {
00039     string inLocation;
00040 
00041     if (
00042         (in.GetSize() != 1) ||
00043         (! in.GetValue(in.begin(),inLocation))
00044         )
00045         {
00046             return false;
00047         }
00048 
00049     obj->CreateScene(inLocation);
00050     return true;
00051 }
00052 
00053 FUNCTION(SceneServer,setActiveScene)
00054 {
00055     string inLocation;
00056 
00057     if (
00058         (in.GetSize() != 1) ||
00059         (! in.GetValue(in.begin(),inLocation))
00060         )
00061         {
00062             return false;
00063         }
00064 
00065     obj->SetActiveScene(inLocation);
00066     return true;
00067 }
00068 
00069 FUNCTION(SceneServer,initSceneImporter)
00070 {
00071     string inImporterName;
00072 
00073     if (
00074         (in.GetSize() != 1) ||
00075         (! in.GetValue(in.begin(),inImporterName))
00076         )
00077         {
00078             return false;
00079         }
00080 
00081     return obj->InitSceneImporter(inImporterName);
00082 }
00083 
00084 void CLASS(SceneServer)::DefineClass()
00085 {
00086     DEFINE_BASECLASS(zeitgeist/Node);
00087     DEFINE_FUNCTION(createScene);
00088     DEFINE_FUNCTION(setActiveScene);
00089     DEFINE_FUNCTION(initSceneImporter);
00090 }

Generated on Thu Apr 6 15:25:39 2006 for rcssserver3d by  doxygen 1.4.4