Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

lwdef.h

Go to the documentation of this file.
00001 
00002 /*
00003     TEDDY - General graphics application library
00004     Copyright (C) 1999-2002  Timo Suoranta
00005     tksuoran@cc.helsinki.fi
00006 
00007     This library is free software; you can redistribute it and/or
00008     modify it under the terms of the GNU Lesser General Public
00009     License as published by the Free Software Foundation; either
00010     version 2.1 of the License, or (at your option) any later version.
00011 
00012     This library 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 GNU
00015     Lesser General Public License for more details.
00016 
00017     You should have received a copy of the GNU Lesser General Public
00018     License along with this library; if not, write to the Free Software
00019     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00020 
00021     $Id: lwdef.h,v 1.4 2002/01/11 14:34:59 tksuoran Exp $
00022 */
00023 
00024 
00031 #ifndef TEDDY__IMPORTS__LW_DEF__H
00032 #define TEDDY__IMPORTS__LW_DEF__H
00033 
00034 
00035 #include "Teddy/TeddyConfig.h"
00036 #if defined( TEDDY_INCLUDE_LW_SCENE )
00037 
00038 #include "Teddy/Graphics/Color.h"
00039 #include "Teddy/Maths/Vector.h"
00040 #include "Teddy/SysSupport/StdString.h"
00041 using namespace Teddy::Graphics;
00042 using namespace Teddy::Maths;
00043 
00044 
00045 namespace Teddy   {
00046 namespace Imports {
00047 
00048 
00049 //  Types
00050 typedef unsigned long  ID4;
00051 typedef signed char    I1;
00052 typedef signed short   I2;
00053 typedef signed long    I4;
00054 typedef unsigned char  U1;
00055 typedef unsigned short U2;
00056 typedef unsigned long  U4;
00057 typedef float          F4;
00058 typedef std::string    S0;
00059 typedef unsigned long  VX;
00060 typedef Color          COL4;
00061 typedef Color          COL12;
00062 typedef Vector         VEC12;
00063 typedef float          FP4;
00064 typedef float          ANG4;
00065 typedef std::string    FNAM0;
00066 
00068 #define MAKE_ID(a,b,c,d)    \
00069     ((unsigned long) (a)<<24 | (unsigned long) (b)<<16 | \
00070      (unsigned long) (c)<<8 | (unsigned long) (d))
00071 
00072 
00073 //  LWOB Surface flags
00074 #define LW_SF_LUMINOUS          (1<< 0)
00075 #define LW_SF_OUTLINE           (1<< 1)
00076 #define LW_SF_SMOOTHING         (1<< 2)
00077 #define LW_SF_COLOR_HILIGHTS    (1<< 3)
00078 #define LW_SF_COLOR_FILTER      (1<< 4)
00079 #define LW_SF_OPAQUE_EDGE       (1<< 5)
00080 #define LW_SF_TRANSPARENT_EDGE  (1<< 6)
00081 #define LW_SF_SHARP_TERMINATOR  (1<< 7)
00082 #define LW_SF_DOUBLE_SIDED      (1<< 8)
00083 #define LW_SF_ADDITIVE          (1<< 9)
00084 #define LW_SF_SHADOW_ALPHA      (1<<10)
00085 
00086 #define LW_PLANAR_IMAGE_MAP      1
00087 #define LW_CYLINDRICAL_IMAGE_MAP 2
00088 #define LW_SPHERICAL_IMAGE_MAP   3
00089 #define LW_CUBIC_IMAGE_MAP       4
00090 
00091 #define LW_AXIS_X 0
00092 #define LW_AXIS_Y 1
00093 #define LW_AXIS_Z 2
00094 
00095 #define LW_ALPHA_MODE_DISABLED   0
00096 #define LW_ALPHA_MODE_CONSTANT   1
00097 #define LW_ALPHA_MODE_OPACITY    2  //  default
00098 #define LW_ALPHA_MODE_SHADOW     3
00099 
00100 //  LWO2::BLOK::OPAC
00101 #define LW_OPACITY_TYPE_ADDITIVE             0
00102 #define LW_OPACITY_TYPE_SUBSTRACTIVE         1
00103 #define LW_OPACITY_TYPE_DIFFERENCE           2
00104 #define LW_OPACITY_TYPE_MULTIPLY             3
00105 #define LW_OPACITY_TYPE_DIVIDE               4
00106 #define LW_OPACITY_TYPE_ALPHA                5
00107 #define LW_OPACITY_TYPE_TEXTURE_DISPLACEMENT 6
00108 
00109 //  LWO2::BLOK::PROJ
00110 #define LW_PROJECTION_PLANAR      0
00111 #define LW_PROJECTION_CYLINDRICAL 1
00112 #define LW_PROJECTION_SPHERICAL   2
00113 #define LW_PROJECTION_CUBIC       3
00114 #define LW_PROJECTION_FRONT       4
00115 #define LW_PROJECTION_UV          5
00116 
00117 //  LWO2::BLOK_WRAP
00118 #define LW_WRAP_RESET  0
00119 #define LW_WRAP_REPEAT 1
00120 #define LW_WRAP_MIRROR 2
00121 #define LW_WRAP_EDGE   3
00122 
00123 
00124 #define ID_FORM     MAKE_ID('F','O','R','M')
00125 #define ID_LWOB     MAKE_ID('L','W','O','B')  //  LWOB
00126 #define ID_LWLO     MAKE_ID('L','W','L','O')  //  LWLO
00127 #define ID_LWO2     MAKE_ID('L','W','O','2')
00128 
00130 #define ID_LAYR     MAKE_ID('L','A','Y','R')
00131 #define ID_PNTS     MAKE_ID('P','N','T','S')
00132 #define ID_VMAP     MAKE_ID('V','M','A','P')
00133 #define ID_POLS     MAKE_ID('P','O','L','S')
00134 
00135 #define ID_CRVS     MAKE_ID('C','R','V','S')  // LWOB only
00136 #define ID_PCHS     MAKE_ID('P','C','H','S')  // LWOB only
00137 #define ID_SRFS     MAKE_ID('S','R','F','S')  // LWOB only
00138 #define ID_VLUM     MAKE_ID('V','L','U','M')  // LWOB only
00139 #define ID_VDIF     MAKE_ID('V','D','I','F')  // LWOB only
00140 #define ID_VSPC     MAKE_ID('V','S','P','C')  // LWOB only
00141 #define ID_VRFL     MAKE_ID('V','R','F','L')  // LWOB only
00142 #define ID_VTRN     MAKE_ID('V','T','R','N')  // LWOB only
00143 
00144 #define ID_RFLT     MAKE_ID('R','F','L','T')  // LWOB only
00145 #define ID_EDGE     MAKE_ID('E','D','G','E')  // LWOB only
00146 #define ID_SDAT     MAKE_ID('S','D','A','T')  // LWOB only
00147 #define ID_IMSQ     MAKE_ID('I','M','S','Q')  // LWOB only
00148 #define ID_FLYR     MAKE_ID('F','L','Y','R')  // LWOB only
00149 #define ID_IMCC     MAKE_ID('I','M','C','C')  // LWOB only
00150 #define ID_CTEX     MAKE_ID('C','T','E','X')  // LWOB only
00151 #define ID_DTEX     MAKE_ID('D','T','E','X')  // LWOB only
00152 #define ID_STEX     MAKE_ID('S','T','E','X')  // LWOB only
00153 #define ID_RTEX     MAKE_ID('R','T','E','X')  // LWOB only
00154 #define ID_TTEX     MAKE_ID('T','T','E','X')  // LWOB only
00155 #define ID_LTEX     MAKE_ID('L','T','E','X')  // LWOB only
00156 #define ID_BTEX     MAKE_ID('B','T','E','X')  // LWOB only
00157 
00158 #define ID_TFLG     MAKE_ID('T','F','L','G')  // LWOB only
00159 #define ID_TSIZ     MAKE_ID('T','S','I','Z')  // LWOB only
00160 #define ID_TCTR     MAKE_ID('T','C','T','R')  // LWOB only
00161 #define ID_TFAL     MAKE_ID('T','F','A','L')  // LWOB only
00162 #define ID_TVEL     MAKE_ID('T','V','E','L')  // LWOB only
00163 #define ID_TREF     MAKE_ID('T','R','E','F')  // LWOB only
00164 #define ID_TCLR     MAKE_ID('T','C','L','R')  // LWOB only
00165 #define ID_TVAL     MAKE_ID('T','V','A','L')  // LWOB only
00166 #define ID_TFP      MAKE_ID('T','F','P',' ')  // LWOB only
00167 #define ID_TIP      MAKE_ID('T','I','P',' ')  // LWOB only
00168 #define ID_TSP      MAKE_ID('T','S','P',' ')  // LWOB only
00169 #define ID_TFRQ     MAKE_ID('T','F','R','Q')  // LWOB only
00170 #define ID_TALP     MAKE_ID('T','A','L','P')  // LWOB only
00171 #define ID_TWRP     MAKE_ID('T','W','R','P')  // LWOB only
00172 #define ID_TAAS     MAKE_ID('T','A','A','S')  // LWOB only
00173 #define ID_TOPC     MAKE_ID('T','O','P','C')  // LWOB only
00174 
00175 
00176 #define ID_TAGS     MAKE_ID('T','A','G','S')
00177 #define ID_PTAG     MAKE_ID('P','T','A','G')
00178 #define ID_ENVL     MAKE_ID('E','N','V','L')
00179 #define ID_CLIP     MAKE_ID('C','L','I','P')
00180 #define ID_SURF     MAKE_ID('S','U','R','F')
00181 #define ID_BBOX     MAKE_ID('B','B','O','X')
00182 #define ID_DESC     MAKE_ID('D','E','S','C')
00183 #define ID_TEXT     MAKE_ID('T','E','X','T')
00184 #define ID_ICON     MAKE_ID('I','C','O','N')
00185 
00187 #define ID_FACE     MAKE_ID('F','A','C','E')
00188 #define ID_CURV     MAKE_ID('C','U','R','V')  // was ID_CRVS
00189 #define ID_PRCH     MAKE_ID('P','T','C','H')  // was ID_PCHS
00190 #define ID_MBAL     MAKE_ID('M','B','A','L')
00191 #define ID_BONE     MAKE_ID('B','O','N','E')
00192 
00194 #define ID_SURF     MAKE_ID('S','U','R','F')
00195 #define ID_BNID     MAKE_ID('B','N','I','D')
00196 #define ID_SGMP     MAKE_ID('S','G','M','P')
00197 #define ID_PART     MAKE_ID('P','A','R','T')
00198 
00200 #define ID_STIL     MAKE_ID('S','T','I','L')
00201 #define ID_ISEQ     MAKE_ID('I','S','E','Q')
00202 #define ID_ANIM     MAKE_ID('A','N','I','M')
00203 #define ID_XREF     MAKE_ID('X','R','E','F')
00204 #define ID_STCC     MAKE_ID('S','T','C','C')
00205 #define ID_CONT     MAKE_ID('C','O','N','T')
00206 #define ID_BRIT     MAKE_ID('B','R','I','T')
00207 #define ID_SATR     MAKE_ID('S','A','T','R')
00208 #define ID_HUE      MAKE_ID('H','U','E',' ')
00209 #define ID_GAMM     MAKE_ID('G','A','M','M')
00210 #define ID_NEGA     MAKE_ID('N','E','G','A')
00211 #define ID_CROP     MAKE_ID('C','R','O','P')
00212 #define ID_ALPH     MAKE_ID('A','L','P','H')
00213 #define ID_COMP     MAKE_ID('C','O','M','P')
00214 #define ID_IFLT     MAKE_ID('I','F','L','T')
00215 #define ID_PFLT     MAKE_ID('P','F','L','T')
00216 
00218 #define ID_PRE      MAKE_ID('P','R','E',' ')
00219 #define ID_POST     MAKE_ID('P','O','S','T')
00220 #define ID_KEY      MAKE_ID('K','E','Y',' ')
00221 #define ID_SPAN     MAKE_ID('S','P','A','N')
00222 #define ID_CHAN     MAKE_ID('C','H','A','N')
00223 
00225 #define ID_COLR     MAKE_ID('C','O','L','R')
00226 #define ID_DIFF     MAKE_ID('D','I','F','F')
00227 #define ID_LUMI     MAKE_ID('L','U','M','I')
00228 #define ID_SPEC     MAKE_ID('S','P','E','C')
00229 #define ID_REFL     MAKE_ID('R','E','F','L')
00230 #define ID_TRAN     MAKE_ID('T','R','A','N')
00231 #define ID_TRNL     MAKE_ID('T','R','N','L')
00232 #define ID_GLOS     MAKE_ID('G','L','O','S')
00233 #define ID_SHRP     MAKE_ID('S','H','R','P')
00234 #define ID_BUMP     MAKE_ID('B','U','M','P')
00235 #define ID_SIDE     MAKE_ID('S','I','D','E')
00236 #define ID_SMAN     MAKE_ID('S','M','A','N')
00237 #define ID_RFOP     MAKE_ID('R','F','O','P')
00238 #define ID_RIMG     MAKE_ID('R','I','M','G')
00239 #define ID_RSAN     MAKE_ID('R','S','A','N')
00240 #define ID_RIND     MAKE_ID('R','I','N','D')
00241 #define ID_CLRH     MAKE_ID('C','L','R','H')
00242 #define ID_TROP     MAKE_ID('T','R','O','P')
00243 #define ID_TIMG     MAKE_ID('T','I','M','G')
00244 #define ID_CLRF     MAKE_ID('C','L','R','F')
00245 #define ID_ADTR     MAKE_ID('A','D','T','R')
00246 #define ID_GLOW     MAKE_ID('G','L','O','W')
00247 #define ID_LINE     MAKE_ID('L','I','N','E')
00248 #define ID_ALPH     MAKE_ID('A','L','P','H')
00249 #define ID_AVAL     MAKE_ID('A','V','A','L')
00250 #define ID_GVAL     MAKE_ID('G','V','A','L')
00251 #define ID_BLOK     MAKE_ID('B','L','O','K')
00252 #define ID_LCOL     MAKE_ID('L','C','O','L')  //  Documentation?
00253 #define ID_LSIZ     MAKE_ID('L','S','I','Z')  //
00254 #define ID_CMNT     MAKE_ID('C','M','N','T')  //
00255 
00257 #define ID_CHAN     MAKE_ID('C','H','A','N')
00258 #define ID_TYPE     MAKE_ID('T','Y','P','E')
00259 #define ID_NAME     MAKE_ID('N','A','M','E')
00260 #define ID_ENAB     MAKE_ID('E','N','A','B')
00261 #define ID_OPAC     MAKE_ID('O','P','A','C')
00262 #define ID_FLAG     MAKE_ID('F','L','A','G')
00263 #define ID_PROJ     MAKE_ID('P','R','O','J')
00264 #define ID_STCK     MAKE_ID('S','T','C','K')
00265 #define ID_TAMP     MAKE_ID('T','A','M','P')
00266 
00268 #define ID_TMAP     MAKE_ID('T','M','A','P')
00269 #define ID_AXIS     MAKE_ID('A','X','I','S')
00270 #define ID_CNTR     MAKE_ID('C','N','T','R')
00271 #define ID_SIZE     MAKE_ID('S','I','Z','E')
00272 #define ID_ROTA     MAKE_ID('R','O','T','A')
00273 #define ID_OREF     MAKE_ID('O','R','E','F')
00274 #define ID_FALL     MAKE_ID('F','A','L','L')
00275 #define ID_CSYS     MAKE_ID('C','S','Y','S')
00276 
00278 #define ID_IMAP     MAKE_ID('I','M','A','P')
00279 #define ID_IMAG     MAKE_ID('I','M','A','G')
00280 #define ID_WRAP     MAKE_ID('W','R','A','P')
00281 #define ID_WRPW     MAKE_ID('W','R','P','W')
00282 #define ID_WRPH     MAKE_ID('W','R','P','H')
00283 #define ID_VMAP     MAKE_ID('V','M','A','P')
00284 #define ID_AAST     MAKE_ID('A','A','S','T')
00285 #define ID_PIXB     MAKE_ID('P','I','X','B')
00286 
00288 #define ID_PROC     MAKE_ID('P','R','O','C')
00289 #define ID_COLR     MAKE_ID('C','O','L','R')
00290 #define ID_VALU     MAKE_ID('V','A','L','U')
00291 #define ID_FUNC     MAKE_ID('F','U','N','C')
00292 #define ID_FTPS     MAKE_ID('F','T','P','S')
00293 #define ID_ITPS     MAKE_ID('I','T','P','S')
00294 #define ID_ETPS     MAKE_ID('E','T','P','S')
00295 
00297 #define ID_GRAD     MAKE_ID('G','R','A','D')
00298 #define ID_GRST     MAKE_ID('G','R','S','T')
00299 #define ID_GREN     MAKE_ID('G','R','E','N')
00300 
00302 #define ID_SHDR     MAKE_ID('S','H','D','R')
00303 #define ID_DATA     MAKE_ID('D','A','T','A')
00304 
00305 
00307 #define ID_TXUV     MAKE_ID('T','X','U','V')
00308 #define ID_MNUW     MAKE_ID('M','N','U','W')
00309 #define ID_MORF     MAKE_ID('M','O','R','F')
00310 #define ID_SPOT     MAKE_ID('S','P','O','T')
00311 #define ID_RGBA     MAKE_ID('R','G','B','A')
00312 
00313 #define ID_PNAM     MAKE_ID('P','N','A','M') 
00314 #define ID_INAM     MAKE_ID('I','N','A','M') 
00315 #define ID_GRPT     MAKE_ID('G','R','P','T') 
00316 #define ID_FKEY     MAKE_ID('F','K','E','Y') 
00317 #define ID_IKEY     MAKE_ID('I','K','E','Y') 
00318 
00319 
00320 };  //  namespace Imports
00321 };  //  namespace Teddy
00322 
00323 
00324 #endif  //  TEDDY_INCLUDE_LW_SCENE
00325 #endif  //  TEDDY__IMPORTS__LW_DEF__H
00326