Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

ctkutils.h

Go to the documentation of this file.
00001 /*
00002 Copyright (C) 1999  Carsten Winkelholz
00003 
00004 Malte Weiß, 09.07.2002: Replaced MakePow2() by new faster algorithm
00005             19.07.2002: Added MakePolyConvex()
00006 
00007 Address:  FGAN Forschungsgesellschaft fr Angewandte Naturwissenschaften e. V.
00008       Neuenahrer Str. 20
00009       D - 53343 Wachtberg
00010       
00011 Email:    winkelholz@fgan.de
00012 
00013 This program is free software; you can redistribute it and/or
00014 modify it under the terms of the GNU General Public License
00015 as published by the Free Software Foundation; either version 2
00016 of the License, or (at your option) any later version.
00017 
00018 This program is distributed in the hope that it will be useful,
00019 but WITHOUT ANY WARRANTY; without even the implied warranty of
00020 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00021 GNU General Public License for more details.
00022 
00023 You should have received a copy of the GNU General Public License
00024 along with this program; if not, write to the Free Software
00025 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
00026 */
00027 
00028 #ifndef CTKALLG_H
00029 #define CTKALLG_H
00030 
00031 #include <fstream>
00032 #include "oaw/ctk/cybwrlfields.h"
00033 #include "oaw/pdtk/anyc.h"
00034 
00035 
00036 #include "../oawconfig.h"
00037 #include "oaw/misc/utils.h"
00038 
00039 OAW_BEGIN_NAMESPACE
00040 
00041 class CybScriptC;
00042 class CybWorldC;
00043 class SFColor;
00044 
00045 class NodeInfo {
00046  public:
00047   NodeInfo() {}
00048   NodeInfo(StringC strNewName, long nNewId) : strName(strNewName), nId(nNewId) {}
00049 
00050   StringC strName;
00051   long nId;
00052 };
00053 
00054 
00055 
00056 OAW_DLLMAPPING void* LoadWrlData(CybNodeC* pNode, const StringC& name, char*& iter, const char* iterEnd,long& znr);
00057 OAW_DLLMAPPING void CopyWrlData(long,const void*,void*,CybScriptC* pS,CybWorldC* pW);
00058 OAW_DLLMAPPING void DeleteWrlData(long,void*);
00059 OAW_DLLMAPPING void* NewWrlData(long, CybScriptC* pS,CybWorldC* pW);  
00060 OAW_DLLMAPPING long GetWrlDataAnySize(long,void*);
00061 OAW_DLLMAPPING void WriteWrlDataToAny(long type, void* srcData, AnyC& any);
00062 OAW_DLLMAPPING void ReadWrlDataFromAny(AnyC& any,long type, void* srcData,CybWorldC*);
00063 
00064 OAW_DLLMAPPING void ErrorMessage(const char*,long,CybWorldC*);
00065 OAW_DLLMAPPING void WarningMessage(const char*,long,CybWorldC*);
00066 
00067 OAW_DLLMAPPING long ReadUntilFirst(KetteC<NodeInfo>&,char*&, const char*,long&);
00068 
00069 OAW_DLLMAPPING long* LoadIndexField(char*& iter, const char* iterEnd, long& znr, long& n);
00070 OAW_DLLMAPPING MFInt32 LoadMFInt32(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00071 OAW_DLLMAPPING SFBool LoadSFBool(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00072 OAW_DLLMAPPING SFFloat LoadSFFloat(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00073 OAW_DLLMAPPING SFInt32 LoadSFInt32(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00074 OAW_DLLMAPPING SFVec3f LoadSFVec3f(char*& iter, const char* iterEnd, long& znr,CybNodeC* pN, const StringC& isKey);
00075 OAW_DLLMAPPING SFVec2f LoadSFVec2f(char*& iter, const char* iterEnd, long& znr,CybNodeC* pN, const StringC& isKey);
00076 OAW_DLLMAPPING SFColor LoadSFColor(char*& iter, const char* iterEnd, long& znr,CybNodeC* pN, const StringC& isKey);
00077 OAW_DLLMAPPING SFRotation LoadSFRotation(char*& iter, const char* iterEnd, long& znr,CybNodeC* pN, const StringC& isKey);
00078 OAW_DLLMAPPING SFTime LoadSFTime(char*& iter, const char* iterEnd, long& znr,CybNodeC* pN, const StringC& isKey);
00079 OAW_DLLMAPPING MFString LoadMFString(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00080 OAW_DLLMAPPING SFString LoadSFString(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00081 OAW_DLLMAPPING MFFloat LoadMFFloat(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00082 OAW_DLLMAPPING MFVec3f LoadMFVec3f(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00083 OAW_DLLMAPPING MFVec2f LoadMFVec2f(char*& iter, const char* iterEnd,long& znr,CybNodeC* pN, const StringC& isKey);
00084 OAW_DLLMAPPING MFRotation LoadMFRotation(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00085 OAW_DLLMAPPING MFColor LoadMFColor(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00086 OAW_DLLMAPPING CybNodeC* LoadNode(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00087 OAW_DLLMAPPING ArrayC<CybNodeC*> LoadNodeList(char*& iter, const char* iterEnd, long& znr, CybNodeC* pN, const StringC& isKey);
00088 
00089 OAW_DLLMAPPING StringC NextWrlString(char*& iter, const char* iterEnd,long& znr);
00090 OAW_DLLMAPPING StringC NextWrlString(char*& iter, const char* iterEnd,const StringC& str, long& znr);
00091 OAW_DLLMAPPING double NextWrlDouble(char*& iter, const char* iterEnd,long& znr,short& b,char mark);
00092 OAW_DLLMAPPING double NextWrlDouble(char*& iter,const char* end, long& znr, short& b, char mark);
00093 
00094 OAW_DLLMAPPING short MakeImagePow2(long srcWidth, long srcHeight, long srcChannel, const unsigned char* srcPixel, long& desWidth, long& desHeight, unsigned char*& desPixel, long glMaxTexDim, CybWorldC*);
00095 OAW_DLLMAPPING short MakePolyConvex(void *pvSrcVertices, long lStride, int nNumSrcVertices, int **pDesIndices, int *pNumDestVertices);
00096 
00097 
00098 OAW_END_NAMESPACE
00099 
00100 #endif
00101 
00102 
00103 
00104 
00105 

Generated on Tue Jul 29 14:24:09 2003 for Open ActiveWrl by doxygen1.3-rc2