| http://www.sim.no/ http://www.coin3d.org/

SoConvexDataCache.h
1 #ifndef COIN_SOCONVEXDATACACHE_H
2 #define COIN_SOCONVEXDATACACHE_H
3
4 /**************************************************************************\
5 *
6 * This file is part of the Coin 3D visualization library.
7 * Copyright (C) by Kongsberg Oil & Gas Technologies.
8 *
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License
11 * ("GPL") version 2 as published by the Free Software Foundation.
12 * See the file LICENSE.GPL at the root directory of this source
13 * distribution for additional information about the GNU GPL.
14 *
15 * For using Coin with software that can not be combined with the GNU
16 * GPL, and for taking advantage of the additional benefits of our
17 * support services, please contact Kongsberg Oil & Gas Technologies
18 * about acquiring a Coin Professional Edition License.
19 *
20 * See http://www.coin3d.org/ for more information.
21 *
22 * Kongsberg Oil & Gas Technologies, Bygdoy Alle 5, 0257 Oslo, NORWAY.
23 * http://www.sim.no/ sales@sim.no coin-support@coin3d.org
24 *
25 \**************************************************************************/
26
27 #include <Inventor/caches/SoCache.h>
28 #include <Inventor/system/inttypes.h>
29
30 class SbVec3f;
31 class SoCoordinateElement;
32 class SbMatrix;
33 class SoConvexDataCacheP;
34
35 class COIN_DLL_API SoConvexDataCache : public SoCache {
36 typedef SoCache inherited;
37 public:
38 SoConvexDataCache(SoState * const state);
39 virtual ~SoConvexDataCache();
40
41 enum Binding {
42 // do not change these values. We rely on them matching
43 // values in SoIndededFaceSet.h and SoGL.cpp...
44 NONE = 0,
45 PER_FACE,
46 PER_FACE_INDEXED,
47 PER_VERTEX,
48 PER_VERTEX_INDEXED
49 };
50
51 void generate(const SoCoordinateElement * const coords,
52 const SbMatrix & matrix,
53 const int32_t *coordindices,
54 const int numcoordindices,
55 const int32_t *matindices, const int32_t *normindices,
56 const int32_t *texindices,
57 const Binding matbinding, const Binding normbinding,
58 const Binding texbinding);
59
60 const int32_t *getCoordIndices(void) const;
61 int getNumCoordIndices(void) const;
62 const int32_t *getMaterialIndices(void) const;
63 int getNumMaterialIndices(void) const;
64 const int32_t *getNormalIndices(void) const;
65 int getNumNormalIndices(void) const;
66 const int32_t *getTexIndices(void) const;
67 int getNumTexIndices(void) const;
68
69 private:
70 SoConvexDataCacheP * pimpl;
71 };
72
73 #endif // !COIN_SOCONVEXDATACACHE_H
SoConvexDataCache
The SoConvexDataCache class is used to cache convexified polygons.SoConvexDataCache is used to speed ...
Definition: SoConvexDataCache.h:35
SoConvexDataCache::Binding
Binding
The Binding enum is used to specify bindings.
Definition: SoConvexDataCache.h:41
SoState
The SoState class manages the Coin scenegraph traversal state data.The SoState class is used by actio...
Definition: SoState.h:35
SoCoordinateElement
The SoCoordinateElement class is yet to be documented.FIXME: write doc.
Definition: SoCoordinateElement.h:31
SbVec3f
The SbVec3f class is a 3 dimensional vector with floating point coordinates.This vector class is used...
Definition: SbVec3f.h:40
SbMatrix
The SbMatrix class is a 4x4 dimensional representation of a matrix.SbMatrix is used by many other cla...
Definition: SbMatrix.h:37
SoCache
The SoCache class is the superclass for all internal cache classes.It organizes reference counting to...
Definition: SoCache.h:34

Copyright © 1998-2010 by Kongsberg Oil & Gas Technologies. All rights reserved.