00001 /* ImLib3D 00002 * Copyright (c) 2001, ULP-IPB Strasbourg. 00003 * 00004 * This program is free software; you can redistribute it and/or modify 00005 * it under the terms of the GNU General Public License as published by 00006 * the Free Software Foundation; either version 2 of the License, or (at 00007 * your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, but 00010 * WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 * General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00017 */ 00019 #ifndef _Complex_hpp 00020 #define _Complex_hpp 00021 00022 #include<ImLib3D/CppTools.hpp> 00023 00024 #include<complex> 00025 typedef complex<double> complexd; 00026 typedef complex<float > complexf; 00027 00028 template<> inline string TypeName<complexf >(){return "complex<float>";} 00029 template<> inline string TypeName<complexd >(){return "complex<double>";} 00030 00031 #if __GNUC__>=3 00032 inline complexd operator*(float v,const complexd &c){return ((double)v)*c;} 00033 #endif //__GNUC__==3 00034 00035 #endif //_Complex_hpp