Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

empty_Filter.cpp

Go to the documentation of this file.
00001 /* ---------------------------------------------------------------------------
00002     Phission :
00003         Realtime Vision Processing System
00004 
00005     Copyright (C) 2003-2006 Philip D.S. Thoren (pthoren@cs.uml.edu)
00006     University of Massachusetts at Lowell,
00007     Laboratory for Artificial Intelligence and Robotics
00008 
00009  ---------------------------------------------------------------------------
00010     <Add other copyrights here> 
00011  ---------------------------------------------------------------------------
00012 
00013     This file is part of Phission.
00014 
00015     Phission is free software; you can redistribute it and/or modify
00016     it under the terms of the GNU Lesser General Public License as published by
00017     the Free Software Foundation; either version 2 of the License, or
00018     (at your option) any later version.
00019 
00020     Phission is distributed in the hope that it will be useful,
00021     but WITHOUT ANY WARRANTY; without even the implied warranty of
00022     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00023     GNU Lesser General Public License for more details.
00024 
00025     You should have received a copy of the GNU Lesser General Public License
00026     along with Phission; if not, write to the Free Software
00027     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00028 
00029  ---------------------------------------------------------------------------*/
00030 #ifdef HAVE_CONFIG_H
00031     #include <phissionconfig.h>
00032 #endif
00033 
00034 #include <phStandard.h>
00035 
00036 #include <empty_Filter.h>
00037 
00038 #include <phError.h>
00039 #include <phMemory.h>
00040 #include <phPrint.h>
00041 
00042 /* ---------------------------------------------------------------------- */
00043 /* ( int value) */
00044 /* ---------------------------------------------------------------------- */
00045 empty_Filter::empty_Filter(unsigned int value) :
00046     phFilter("empty_Filter")
00047 
00048 {
00049     this->m_format = phImageValidFormatMask;
00050     this->set(value);
00051 }
00052 
00053 /* ---------------------------------------------------------------------- */
00054 empty_Filter::~empty_Filter()
00055 {
00056 }
00057 
00058 /* ------------------------------------------------------------------------ */
00059 phFilter *empty_Filter::cloneFilter()
00060 {
00061     phFUNCTION("empty_Filter::cloneFilter")
00062     int locked = 0;
00063     empty_Filter *empty = new empty_Filter();
00064     
00065     phTHIS_LOOSE_LOCK(locked);
00066     
00067     empty->set(this->m_value);
00068 
00069     phTHIS_LOOSE_UNLOCK(locked);
00070 
00071     return (phFilter *)empty;
00072 }
00073 
00074 /* ---------------------------------------------------------------------- */
00075 int empty_Filter::set(unsigned int value)
00076 {
00077     phFUNCTION("empty_Filter::set")
00078     int locked = 0;
00079 
00080     /* LOOSE locking means that if it fails it won't adjust 'locked' and
00081      * it will continue with the main body of this method */
00082     phTHIS_LOOSE_LOCK(locked);
00083     
00084     this->m_value = value;
00085 
00086     phTHIS_LOOSE_UNLOCK(locked);
00087     
00088     return phSUCCESS;
00089 }
00090 
00091 /* ---------------------------------------------------------------------- */
00092 int empty_Filter::filter()
00093 {
00094     phFUNCTION("empty_Filter::filter")
00095    
00096     /* defined before being called:
00097      *  width
00098      *  height
00099      *  depth
00100      *  Image
00101      */
00102     
00103     /* Begin Filter */
00104     
00105     /* End Filter */
00106     
00107     /* make sure to free up any space here, not including Image */
00108     
00109     return phSUCCESS;
00110     
00111 #if 0
00112 /* Comment this back in if you use any macros that jump to here, ie phCHECK_RC,
00113  * or phCHECK_PTR */
00114 
00115 error:
00116     /* make sure to free up any space here, not including Image */
00117     
00118     return phFAIL;
00119     
00120 #endif
00121 }
00122 
00123 




Copyright (C) 2002 - 2007 Philip D.S. Thoren ( pthoren@users.sourceforge.net )
University Of Massachusetts at Lowell
Robotics Lab
SourceForge.net Logo

Generated on Sat Jun 16 02:44:09 2007 for phission by  doxygen 1.4.4