00001 /*---------------------------------------------------------------------------*\ 00002 * OpenSG * 00003 * * 00004 * * 00005 * Copyright (C) 2000-2002 by the OpenSG Forum * 00006 * * 00007 * www.opensg.org * 00008 * * 00009 * contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de * 00010 * * 00011 \*---------------------------------------------------------------------------*/ 00012 /*---------------------------------------------------------------------------*\ 00013 * License * 00014 * * 00015 * This library is free software; you can redistribute it and/or modify it * 00016 * under the terms of the GNU Library General Public License as published * 00017 * by the Free Software Foundation, version 2. * 00018 * * 00019 * This library is distributed in the hope that it will be useful, but * 00020 * WITHOUT ANY WARRANTY; without even the implied warranty of * 00021 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00022 * Library General Public License for more details. * 00023 * * 00024 * You should have received a copy of the GNU Library General Public * 00025 * License along with this library; if not, write to the Free Software * 00026 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * 00027 * * 00028 \*---------------------------------------------------------------------------*/ 00029 /*---------------------------------------------------------------------------*\ 00030 * Changes * 00031 * * 00032 * * 00033 * * 00034 * * 00035 * * 00036 * * 00037 \*---------------------------------------------------------------------------*/ 00038 00039 00040 #ifndef _OSGGEOPROPNORMALS_H_ 00041 #define _OSGGEOPROPNORMALS_H_ 00042 #ifdef __sgi 00043 #pragma once 00044 #endif 00045 00046 #include <OSGGeoPropertyBase.h> 00047 00048 OSG_BEGIN_NAMESPACE 00049 00054 struct GeoNormals3fPropertyDesc : public GeoNormalsPropertyDesc 00055 { 00056 static FieldDescription *_desc[]; 00057 00058 /*---------------------------------------------------------------------*/ 00062 static const Char8 *getTypeName (void) { return "GeoNormals3f"; } 00063 static const Char8 *getClassName (void) { return "GeoNormals3fProperty"; } 00064 static const Char8 *getFieldName (void) { return "normals"; } 00065 static const Char8 *getGroupName (void) { return "GeoNormals"; } 00066 00067 static InitContainerF getInitMethod(void) { return NULL; } 00068 00069 static UInt32 getFormat (void) { return GL_FLOAT; } 00070 static UInt32 getFormatSize(void) { return sizeof(GLfloat); } 00071 static UInt32 getDimension (void) { return 3; } 00072 static UInt32 getStride (void) { return 0; } 00073 00074 static FieldDescription **getDesc (void) { return _desc; } 00075 00077 /*---------------------------------------------------------------------*/ 00081 typedef GeoNormals Inherited; 00082 typedef GeoNormals::PtrType InheritedPtr; 00083 00084 typedef GeoNormalsPropertyDesc InheritedDesc; 00085 00086 typedef MFVec3f StoredFieldType; 00087 typedef InheritedDesc::GenericType GenericType; 00088 00089 #ifndef OSG_SUPPORT_NO_GEO_INTERFACE 00090 typedef GeoPropertyInterface<GeoNormalsPropertyDesc> Interface; 00091 #endif 00092 00094 }; 00095 00096 #if !defined(OSG_DO_DOC) // created as a dummy class, remove to prevent doubles 00097 typedef GeoProperty<GeoNormals3fPropertyDesc> GeoNormals3f; 00098 #endif 00099 00100 #if !defined(OSG_COMPILEGEOPROPNORMALINST) && !defined(OSG_DO_DOC) 00101 OSG_FC_DLLEXPORT_DECL(GeoProperty, 00102 GeoNormals3fPropertyDesc, 00103 OSG_SYSTEMLIB_DLLTMPLMAPPING) 00104 #endif 00105 00110 struct GeoNormals3sPropertyDesc : public GeoNormalsPropertyDesc 00111 { 00112 static FieldDescription *_desc[]; 00113 00114 /*---------------------------------------------------------------------*/ 00118 static const Char8 *getTypeName (void) { return "GeoNormals3s"; } 00119 static const Char8 *getClassName (void) { return "GeoNormals3sProperty"; } 00120 static const Char8 *getFieldName (void) { return "normals"; } 00121 static const Char8 *getGroupName (void) { return "GeoNormals"; } 00122 00123 static InitContainerF getInitMethod(void) { return NULL; } 00124 00125 static UInt32 getFormat (void) { return GL_SHORT; } 00126 static UInt32 getFormatSize(void) { return sizeof(GLshort); } 00127 static UInt32 getDimension (void) { return 3; } 00128 static UInt32 getStride (void) { return 0; } 00129 00130 static FieldDescription **getDesc (void) { return _desc; } 00131 00133 /*---------------------------------------------------------------------*/ 00137 typedef GeoNormals Inherited; 00138 typedef GeoNormals::PtrType InheritedPtr; 00139 00140 typedef GeoNormalsPropertyDesc InheritedDesc; 00141 00142 typedef MFVec3s StoredFieldType; 00143 typedef InheritedDesc::GenericType GenericType; 00144 00145 #ifndef OSG_SUPPORT_NO_GEO_INTERFACE 00146 typedef GeoPropertyInterface<GeoNormalsPropertyDesc> Interface; 00147 #endif 00148 00150 }; 00151 00152 #if !defined(OSG_DO_DOC) // created as a dummy class, remove to prevent doubles 00153 typedef GeoProperty<GeoNormals3sPropertyDesc> GeoNormals3s; 00154 #endif 00155 00156 #if !defined(OSG_COMPILEGEOPROPNORMALINST) && !defined(OSG_DO_DOC) 00157 OSG_FC_DLLEXPORT_DECL(GeoProperty, 00158 GeoNormals3sPropertyDesc, 00159 OSG_SYSTEMLIB_DLLTMPLMAPPING) 00160 #endif 00161 00166 struct GeoNormals3bPropertyDesc : public GeoNormalsPropertyDesc 00167 { 00168 static FieldDescription *_desc[]; 00169 00170 /*---------------------------------------------------------------------*/ 00174 static const Char8 *getTypeName (void) { return "GeoNormals3b"; } 00175 static const Char8 *getClassName (void) { return "GeoNormals3bProperty"; } 00176 static const Char8 *getFieldName (void) { return "normals"; } 00177 static const Char8 *getGroupName (void) { return "GeoNormals"; } 00178 00179 static InitContainerF getInitMethod(void) { return NULL; } 00180 00181 static UInt32 getFormat (void) { return GL_BYTE; } 00182 static UInt32 getFormatSize(void) { return sizeof(GLbyte); } 00183 static UInt32 getDimension (void) { return 3; } 00184 static UInt32 getStride (void) { return 0; } 00185 00186 static FieldDescription **getDesc (void) { return _desc; } 00187 00189 /*---------------------------------------------------------------------*/ 00193 typedef GeoNormals Inherited; 00194 typedef GeoNormals::PtrType InheritedPtr; 00195 00196 typedef GeoNormalsPropertyDesc InheritedDesc; 00197 00198 typedef MFVec3b StoredFieldType; 00199 typedef InheritedDesc::GenericType GenericType; 00200 00201 #ifndef OSG_SUPPORT_NO_GEO_INTERFACE 00202 typedef GeoPropertyInterface<GeoNormalsPropertyDesc> Interface; 00203 #endif 00204 00206 }; 00207 00208 #if !defined(OSG_DO_DOC) // created as a dummy class, remove to prevent doubles 00209 typedef GeoProperty<GeoNormals3bPropertyDesc> GeoNormals3b; 00210 #endif 00211 00212 #if !defined(OSG_COMPILEGEOPROPNORMALINST) && !defined(OSG_DO_DOC) 00213 OSG_FC_DLLEXPORT_DECL(GeoProperty, 00214 GeoNormals3bPropertyDesc, 00215 OSG_SYSTEMLIB_DLLTMPLMAPPING) 00216 #endif 00217 00218 OSG_END_NAMESPACE 00219 00220 #include <OSGGeoPropNormals.inl> 00221 00222 #endif /* _OSGGEOPROPNORMALS_H_ */
1.4.3