Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/importer/array.h @ 3184

Last change on this file since 3184 was 3184, checked in by bensch, 19 years ago

orxonox/trunk: osX-compatibility

File size: 837 bytes
Line 
1/*!
2  \file array.h
3  \brief Contains the Array Class that handles float arrays.
4  this class creates a Array of a semi-Dynamic length.
5  beware, that after finalizing the array may not be resized again.
6*/
7
8#ifndef _ARRAY_H
9#define _ARRAY_H
10
11extern int verbose; //!< will be obsolete soon
12
13#include "stdincl.h"
14#include <fstream>
15
16
17//! Array Class that handles dynamic-float arrays.
18class Array
19{
20 public:
21  Array ();
22  ~Array();
23
24  void initializeArray ();
25  void finalizeArray (void);
26  void addEntry (GLfloat entry);
27  void addEntry(GLfloat entry0, GLfloat entry1, GLfloat entry2);
28 
29  GLfloat* getArray ();
30  int getCount();
31  void debug(void);
32 private:
33  struct Entry
34  {
35    GLfloat value;
36    Entry* next;
37  };
38
39  GLfloat* array;
40  int entryCount;
41  bool finalized;
42  Entry* firstEntry;
43  Entry* currentEntry;
44 
45 
46};
47
48#endif
Note: See TracBrowser for help on using the repository browser.