root/OpenSceneGraph/trunk/src/osg/Array.cpp @ 13041

Revision 13041, 1.4 kB (checked in by robert, 3 years ago)

Ran script to remove trailing spaces and tabs

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
2 *
3 * This library is open source and may be redistributed and/or modified under
4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5 * (at your option) any later version.  The full license is in LICENSE file
6 * included with this distribution, and on the openscenegraph.org website.
7 *
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 * OpenSceneGraph Public License for more details.
12*/
13#include <osg/Array>
14
15using namespace osg;
16
17static const char* s_ArrayNames[] =
18{
19    "Array", // 0
20    "ByteArray",     // 1
21    "ShortArray",    // 2
22    "IntArray",      // 3
23
24    "UByteArray",    // 4
25    "UShortArray",   // 5
26    "UIntArray",     // 6
27    "Vec4ubArray",   // 7
28
29    "FloatArray",    // 8
30    "Vec2Array",     // 9
31    "Vec3Array",     // 10
32    "Vec4Array",     // 11
33
34    "Vec2sArray",    // 12
35    "Vec3sArray",    // 13
36    "Vec4sArray",    // 14
37
38    "Vec2bArray",    // 15
39    "Vec3bArray",    // 16
40    "Vec4bArray",    // 17
41
42    "DoubleArray",   // 18
43    "Vec2dArray",    // 19
44    "Vec3dArray",    // 20
45    "Vec4dArray",    // 21
46};
47
48const char* Array::className() const
49{
50    if (_arrayType>=ArrayType && _arrayType<=Vec4dArrayType)
51        return s_ArrayNames[_arrayType];
52    else
53        return "UnknownArray";
54}
Note: See TracBrowser for help on using the browser.