00001 /* 00002 FixedLocation - directly positioning a MObject to a fixed location 00003 00004 Copyright (C) Lumiera.org 00005 2008, Hermann Vosseler <Ichthyostega@web.de> 00006 00007 This program is free software; you can redistribute it and/or 00008 modify it under the terms of the GNU General Public License as 00009 published by the Free Software Foundation; either version 2 of the 00010 License, or (at your option) any later version. 00011 00012 This program is distributed in the hope that it will be useful, 00013 but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 GNU General Public License for more details. 00016 00017 You should have received a copy of the GNU General Public License 00018 along with this program; if not, write to the Free Software 00019 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00020 00021 * *****************************************************/ 00022 00023 00024 #include "proc/mobject/session/fixedlocation.hpp" 00025 00026 namespace mobject 00027 { 00028 namespace session 00029 { 00030 00031 FixedLocation* 00032 FixedLocation::clone () const 00033 { 00034 return new FixedLocation (*this); 00035 } 00036 00037 00039 void 00040 FixedLocation::intersect (LocatingSolution& solution) const 00041 { 00042 LocatingPin::intersect (solution); 00043 00044 TODO ("either set position or make overconstrained"); 00045 if (solution.minTime <= this->time_) 00046 solution.minTime = this->time_; 00047 else 00048 solution.impo = true; 00049 if (solution.maxTime >= this->time_) 00050 solution.maxTime = this->time_; 00051 else 00052 solution.impo = true; 00053 } 00054 00055 00056 00057 } // namespace mobject::session 00058 00059 } // namespace mobject
1.5.6