Index: orxonox/trunk/src/array.cc
===================================================================
--- orxonox/trunk/src/array.cc	(revision 2835)
+++ orxonox/trunk/src/array.cc	(revision 2835)
@@ -0,0 +1,93 @@
+/* 
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific:
+   main-programmer: Benjamin Grauer
+   co-programmer: ...
+*/
+
+#include "array.h"
+
+Array::Array ()
+{
+  createArray ();
+}
+
+void Array::createArray ()
+{
+  if (verbose >= 2)
+    printf ("crating new Array\n");
+  firstEntry = new Entry;
+  firstEntry->next =NULL;
+  currentEntry=firstEntry;
+  finalized = false;
+  entryCount = 0; //0 means one entry
+  return;
+}
+
+void Array::finalizeArray (void)
+{
+  if (verbose >= 3)
+    printf ("Finalizing array.\n");  
+  if ((array = (GLfloat*)malloc( entryCount* sizeof(GLfloat))) == NULL)
+    printf ("could not allocate %i data Blocks\n", entryCount);
+  Entry* walker = firstEntry;
+  for (int i=0; i<entryCount; i++)
+    {
+      array[i] = walker->value;
+      walker = walker->next;
+    }
+  finalized = true;
+  return;
+}
+
+
+void Array::addEntry (GLfloat entry)
+{
+  if (!finalized)
+    {
+      if (verbose >= 3)
+	printf ("adding new Entry to Array: %f\n", entry);
+      
+      entryCount++;
+      currentEntry->value = entry;
+      currentEntry->next = new Entry;
+      currentEntry = currentEntry->next;
+      currentEntry->next = NULL;
+    }
+  else 
+    if (verbose >= 1)
+      printf ("adding failed, because list has been finalized\n");
+}
+
+void Array::addEntry (GLfloat entry0, GLfloat entry1, GLfloat entry2)
+{
+  addEntry (entry0);
+  addEntry (entry1);
+  addEntry (entry2);
+}
+  
+
+GLfloat* Array::getArray ()
+{
+  return array;
+}
+
+int Array::getCount()
+{
+  return entryCount;
+}
+
+
+
+void Array::debug ()
+{
+  printf ("entryCount=%i, address=%p\n", entryCount, array);
+}
Index: orxonox/trunk/src/array.h
===================================================================
--- orxonox/trunk/src/array.h	(revision 2835)
+++ orxonox/trunk/src/array.h	(revision 2835)
@@ -0,0 +1,38 @@
+#ifndef _ARRAY_H
+#define _ARRAY_H
+
+extern int verbose;
+
+#include <GL/gl.h>
+#include <GL/glu.h>
+#include <fstream>
+class Array
+{
+ public:
+  Array ();
+
+  void createArray ();
+  void finalizeArray (void);
+  void addEntry (GLfloat entry);
+  void addEntry(GLfloat entry0, GLfloat entry1, GLfloat entry2);
+  
+  GLfloat* getArray ();
+  int getCount();
+  void debug(void);
+ private:
+  struct Entry
+  {
+    GLfloat value;
+    Entry* next;
+  };
+
+  GLfloat* array;
+  int entryCount;
+  bool finalized;
+  Entry* firstEntry;
+  Entry* currentEntry;
+  
+  
+};
+
+#endif
Index: orxonox/trunk/src/material.cc
===================================================================
--- orxonox/trunk/src/material.cc	(revision 2835)
+++ orxonox/trunk/src/material.cc	(revision 2835)
@@ -0,0 +1,188 @@
+/* 
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific:
+   main-programmer: Benjamin Grauer
+   co-programmer: ...
+*/
+
+#include "material.h"
+
+Material::Material()
+{
+  init();
+  
+  setName ("");
+}
+
+Material::Material (char* mtlName)
+{
+  init();
+  
+  setName (mtlName);
+}
+
+Material* Material::addMaterial(char* mtlName)
+{
+  if (verbose >=2)
+    printf ("adding Material %s\n", mtlName);
+  Material* newMat = new Material(mtlName);
+  Material* tmpMat = this;
+  while (tmpMat->nextMat != NULL)
+    {
+      tmpMat = tmpMat->nextMat;
+    }
+      tmpMat->nextMat = newMat;
+      return newMat;
+  
+}
+
+void Material::init(void)
+{
+  if (verbose >= 3)
+    printf ("initializing new Material\n");
+  nextMat = NULL;
+
+  setIllum(1);
+  setDiffuse(0,0,0);
+  setAmbient(0,0,0);
+  setSpecular(0,0,0);
+  setTransparency(0.0);
+}
+
+
+void Material::setName (char* mtlName)
+{
+  if (verbose >= 3)
+    printf("setting Material Name to %s", mtlName);
+  strcpy(name, mtlName);
+  //  printf ("adding new Material: %s, %p\n", this->getName(), this);
+
+}
+char* Material::getName (void)
+{
+  return name;
+}
+
+
+void Material::setIllum (int illum)
+{
+  if (verbose >= 3)
+    printf("setting illumModel of Material %s to %i", name, illum);
+  illumModel = illum;
+  //  printf ("setting illumModel to: %i\n", illumModel);
+}
+void Material::setIllum (char* illum)
+{
+  setIllum (atoi(illum));
+}
+
+void Material::setDiffuse (float r, float g, float b)
+{
+  if (verbose >= 3)
+    printf ("setting Diffuse Color of Material %s to r=%f g=%f b=%f\n", name, r, g, b);
+  diffuse[0] = r;
+  diffuse[1] = g;
+  diffuse[2] = b;  
+  diffuse[3] = 1.0;
+
+}
+void Material::setDiffuse (char* rgb)
+{
+  char r[20],g[20],b[20];
+  sscanf (rgb, "%s %s %s", r, g, b);
+  setDiffuse (atof(r), atof(g), atof(b));
+}
+
+void Material::setAmbient (float r, float g, float b)
+{
+  if (verbose >=3)
+    printf ("setting Ambient Color of Material %s to r=%f g=%f b=%f\n", name, r, g, b);
+  ambient[0] = r;
+  ambient[1] = g;
+  ambient[2] = b;
+  ambient[3] = 1.0;
+}
+void Material::setAmbient (char* rgb)
+{
+  char r[20],g[20],b[20];
+  sscanf (rgb, "%s %s %s", r, g, b);
+  setAmbient (atof(r), atof(g), atof(b));
+}
+
+void Material::setSpecular (float r, float g, float b)
+{
+  if (verbose >= 3)
+    printf ("setting Specular Color of Material %s to r=%f g=%f b=%f\n", name, r, g, b);
+  specular[0] = r;
+  specular[1] = g;
+  specular[2] = b;
+  specular[3] = 1.0;
+ }
+void Material::setSpecular (char* rgb)
+{
+  char r[20],g[20],b[20];
+  sscanf (rgb, "%s %s %s", r, g, b);
+  setSpecular (atof(r), atof(g), atof(b));
+}
+
+
+void Material::setTransparency (float trans)
+{
+  if (verbose >= 3)
+    printf ("setting Transparency of Material %s to %f\n", name, trans);
+  transparency = trans;
+}
+void Material::setTransparency (char* trans)
+{
+  char tr[20];
+  sscanf (trans, "%s", tr);
+  setTransparency (atof(tr));
+}
+
+
+Material* Material::search (char* mtlName)
+{
+  if (verbose >=3)
+    printf ("Searching for material %s", mtlName);
+  Material* searcher = this;
+  while (searcher != NULL)
+    {
+      if (verbose >= 3)
+	printf (".");
+      if (!strcmp (searcher->getName(), mtlName))
+	{
+	  if (verbose >= 3)
+	    printf ("found.\n");
+	  return searcher;
+	}
+      searcher = searcher->nextMat;
+    }
+  return NULL;
+}
+
+bool Material::select (void)
+{
+  // setting diffuse color
+  //  glColor3f (diffuse[0], diffuse[1], diffuse[2]);
+  glMaterialfv(GL_FRONT, GL_DIFFUSE, diffuse);
+
+  // setting ambient color
+  glMaterialfv(GL_FRONT, GL_AMBIENT, ambient);
+
+  // setting up Sprecular
+  glMaterialfv(GL_FRONT, GL_SPECULAR, specular);
+  
+  // setting illumination Model 
+  if (illumModel == 1)
+    glShadeModel(GL_FLAT);
+  else if (illumModel >= 2)
+    glShadeModel(GL_SMOOTH);
+}
Index: orxonox/trunk/src/material.h
===================================================================
--- orxonox/trunk/src/material.h	(revision 2835)
+++ orxonox/trunk/src/material.h	(revision 2835)
@@ -0,0 +1,50 @@
+#ifndef _MATERIAL_H
+#define _MATERIAL_H
+
+extern int verbose;
+
+#include <GL/gl.h>
+#include <GL/glu.h>
+#include <stdlib.h>
+#include <fstream>
+
+class Material
+{
+ public:
+  Material ();
+  Material (char* mtlName);
+  Material* addMaterial(char* mtlName);
+
+  void init(void);
+  ~Material ();
+
+
+  void setName (char* mtlName);
+  char* getName (void);
+  void setIllum (int illum);
+  void setIllum (char* illum);
+  void setDiffuse (float r, float g, float b);
+  void setDiffuse (char* rgb);
+  void setAmbient (float r, float g, float b);
+  void setAmbient (char* rgb);
+  void setSpecular (float r, float g, float b);
+  void setSpecular (char* rgb);
+  void setTransparency (float trans);
+  void setTransparency (char* trans);
+
+  Material* search (char* mtlName);
+
+  bool select (void);
+
+  Material* nextMat;
+
+ private:
+  char name [50];
+  int illumModel;
+  float diffuse [4];
+  float ambient [4];
+  float specular [4];
+  float transparency;
+
+};
+#endif
Index: orxonox/trunk/src/object.cc
===================================================================
--- orxonox/trunk/src/object.cc	(revision 2835)
+++ orxonox/trunk/src/object.cc	(revision 2835)
@@ -0,0 +1,408 @@
+/* 
+   orxonox - the future of 3D-vertical-scrollers
+
+   Copyright (C) 2004 orx
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2, or (at your option)
+   any later version.
+
+   ### File Specific:
+   main-programmer: Benjamin Grauer
+   co-programmer: ...
+*/
+
+int verbose = 0;
+
+#include "object.h"
+
+Object::Object ()
+{
+
+  initialize();
+
+  importFile ("reaphigh.obj");
+
+  finalize();
+}
+
+Object::Object(char* fileName)
+{
+  initialize();
+
+  importFile (fileName);
+
+  finalize();
+}
+
+Object::Object(char* fileName, float scaling)
+{
+  initialize();
+  scaleFactor = scaling;
+
+  importFile (fileName);
+
+  finalize();
+}
+
+bool Object::initialize (void)
+{
+  if (verbose >=3)
+    printf("new 3D-Object is being created\n"); 
+  faceMode = -1;
+  if ( (listNumber = glGenLists(1)) == 0 )
+    {
+      printf ("list could not be created for this Object\n");
+      return false;
+    }
+
+  mtlFileName = "";
+  scaleFactor = 1;
+  vertices = new Array();
+  normals = new Array();
+  vTexture = new Array();
+
+  glNewList (listNumber, GL_COMPILE);
+  glEnableClientState (GL_VERTEX_ARRAY);
+  glEnableClientState (GL_NORMAL_ARRAY);
+  //  glEnableClientState (GL_TEXTURE_COORD_ARRAY);
+
+  return true;
+}
+
+bool Object::importFile (char* fileName)
+{
+  if (verbose >=3)
+    printf("preparing to read in file: %s\n", fileName);   
+  objFileName = fileName;
+  this->readFromObjFile (objFileName);
+  return true;
+}
+
+bool Object::finalize(void)
+{
+  if (verbose >=3)
+    printf("finalizing the 3D-Object\n"); 
+  OBJ_FILE->close();
+  glEnd();
+  glEndList();
+  return true;
+}
+
+void Object::draw (void)
+{
+  if (verbose >=3)
+    printf("drawing the 3D-Object\n"); 
+  glCallList (listNumber);
+}
+
+
+bool Object::readFromObjFile (char* fileName)
+{
+  OBJ_FILE = new ifstream(fileName);
+  if (!OBJ_FILE->is_open())
+    {
+      if (verbose >=1)
+	printf ("unable to open .OBJ file: %s\n Loading Box Object instead.\n", fileName);
+      BoxObject();
+      return false;
+    }
+  objFileName = fileName;
+  char Buffer[500];
+  while(!OBJ_FILE->eof())
+    {
+      OBJ_FILE->getline(Buffer, 500);
+      if (verbose >=4)
+	printf ("Read input line: %s\n",Buffer);
+      
+
+      // case vertice
+      if (!strncmp(Buffer, "v ", 2))
+	{
+	  readVertex(Buffer+2);
+	}
+
+      // case face
+      else if (!strncmp(Buffer, "f ", 2))
+	{
+	  readFace (Buffer+2);
+	}
+      
+      else if (!strncmp(Buffer, "mtllib", 6))
+	{
+	  readMtlLib (Buffer+7);
+	}
+
+      else if (!strncmp(Buffer, "usemtl", 6))
+	{
+	  readUseMtl (Buffer+7);
+	}
+
+      // case VertexNormal
+      else if (!strncmp(Buffer, "vn ", 2))
+      {
+	readVertexNormal(Buffer+3);
+      }
+
+      // case vt
+      else if (!strncmp(Buffer, "vt ", 2))
+      {
+	readVertexTexture(Buffer+3);
+      }
+	  
+
+    }
+  
+
+  
+  
+}
+
+
+bool Object::readVertex (char* vertexString)
+{
+  readVertices = true;
+  char subbuffer1[20];
+  char subbuffer2[20];
+  char subbuffer3[20];
+  sscanf (vertexString, "%s %s %s", subbuffer1, subbuffer2, subbuffer3);
+  if (verbose >= 3)
+    printf ("reading in a vertex: %s %s %s\n", subbuffer1, subbuffer2, subbuffer3);
+  vertices->addEntry(atof(subbuffer1)*scaleFactor, atof(subbuffer2)*scaleFactor, atof(subbuffer3)*scaleFactor);
+  return true;
+}
+
+bool Object::readFace (char* faceString)
+{
+  if (readVertices == true)
+    {
+      vertices->finalizeArray();
+      glVertexPointer(3, GL_FLOAT, 0, vertices->getArray());
+      normals->finalizeArray();
+      glNormalPointer(GL_FLOAT, 0, normals->getArray());
+      vTexture->finalizeArray();
+    }
+
+  readVertices = false;
+  char subbuffer1[20];
+  char subbuffer2[20];
+  char subbuffer3[20];
+  char subbuffer4[20] ="";
+  sscanf (faceString, "%s %s %s %s", subbuffer1, subbuffer2, subbuffer3, subbuffer4);
+  if (!strcmp(subbuffer4, ""))
+    {
+      if (faceMode != 3)
+	{
+	  if (faceMode != -1)
+	    glEnd();
+	  glBegin(GL_TRIANGLES);
+	}
+      
+      faceMode = 3;
+      if (verbose >=3)
+	printf ("found triag: %s, %s, %s\n", subbuffer1, subbuffer2, subbuffer3);
+      addGLElement(subbuffer1);
+      addGLElement(subbuffer2);
+      addGLElement(subbuffer3);
+      return true;
+    }
+  else
+    {
+      if (faceMode != 4)
+	{
+	  if (faceMode != -1)
+	    glEnd();
+	  glBegin(GL_QUADS);
+	}
+      faceMode = 4;
+      if (verbose >=3 )
+	printf ("found quad: %s, %s, %s, %s\n", subbuffer1, subbuffer2, subbuffer3, subbuffer4);
+      addGLElement(subbuffer1);
+      addGLElement(subbuffer2);
+      addGLElement(subbuffer3);
+      addGLElement(subbuffer4);
+      return true;
+    }
+}
+
+bool Object::addGLElement (char* elementString)
+{
+  if (verbose >=3)
+    printf ("importing grafical Element.... including to openGL\n");
+  char* vertex = elementString;
+
+  char* texture;
+  texture = strstr (vertex, "/");
+  texture[0] = '\0';
+  texture ++;
+  glTexCoord2fv(vTexture->getArray()+(atoi(texture)-1)*2);
+
+  char* normal;
+  if ((normal = strstr (texture, "/")) !=NULL)
+    {
+      normal[0] = '\0';
+      normal ++;
+      //glArrayElement(atoi(vertex)-1);
+      glNormal3fv(normals->getArray() +(atoi(normal)-1)*3);
+    }
+  glVertex3fv(vertices->getArray() +(atoi(vertex)-1)*3);
+
+}
+
+bool Object::readVertexNormal (char* normalString)
+{
+  readVertices = true;
+  char subbuffer1[20];
+  char subbuffer2[20];
+  char subbuffer3[20];
+  sscanf (normalString, "%s %s %s", subbuffer1, subbuffer2, subbuffer3);
+  if (verbose >=3 )
+    printf("found vertex-Normal %s, %s, %s\n", subbuffer1,subbuffer2,subbuffer3);
+  normals->addEntry(atof(subbuffer1), atof(subbuffer2), atof(subbuffer3));
+  return true;
+}
+
+bool Object::readVertexTexture (char* vTextureString)
+{
+  readVertices = true;
+  char subbuffer1[20];
+  char subbuffer2[20];
+  sscanf (vTextureString, "%s %s", subbuffer1, subbuffer2);
+  if (verbose >=3 )
+    printf("found vertex-Texture %s, %s\n", subbuffer1,subbuffer2);
+  vTexture->addEntry(atof(subbuffer1));
+  vTexture->addEntry(atof(subbuffer2));
+  return true;
+}
+
+
+bool Object::readMtlLib (char* mtlFile)
+{
+  MTL_FILE = new ifstream (mtlFile);
+  if (!MTL_FILE->is_open())
+    {
+      if (verbose >= 1)
+	printf ("unable to open file: %s\n", mtlFile);
+      return false;
+    }
+  mtlFileName = mtlFile;
+  if (verbose >=2)
+    printf ("Opening mtlFile: %s\n", mtlFileName);
+  char Buffer[500];
+  vertices = new Array();
+  material = new Material();
+  Material* tmpMat = material;
+  while(!MTL_FILE->eof())
+    {
+      MTL_FILE->getline(Buffer, 500);
+      if (verbose >= 4)
+	printf("found line in mtlFile: %s\n", Buffer);
+      
+
+      // create new Material
+      if (!strncmp(Buffer, "newmtl ", 2))
+	{
+	  tmpMat = tmpMat->addMaterial(Buffer+7);
+	  //	  printf ("%s, %p\n", tmpMat->getName(), tmpMat);
+	}
+      // setting a illumMode
+      else if (!strncmp(Buffer, "illum", 5))
+	{
+	  tmpMat->setIllum(Buffer+6);
+
+	}
+      // setting Diffuse Color
+      else if (!strncmp(Buffer, "Kd", 2))
+	{
+	  tmpMat->setDiffuse(Buffer+3);
+	}
+      // setting Ambient Color
+      else if (!strncmp(Buffer, "Ka", 2))
+	{
+	  tmpMat->setAmbient(Buffer+3);
+	}
+      // setting Specular Color
+      else if (!strncmp(Buffer, "Ks", 2))
+	{
+	  tmpMat->setSpecular(Buffer+3);
+	}
+    }
+  return true;
+}
+
+bool Object::readUseMtl (char* matString)
+{
+  if (!strcmp (mtlFileName, ""))
+    {
+      if (verbose >= 1)
+	printf ("Not using new defined material, because no mtlFile found yet\n");
+      return false;
+    }
+      
+  if (faceMode != -1)
+    glEnd();
+  faceMode = 0;
+  if (verbose >= 2)
+    printf ("using material %s for coming Faces.\n", matString);
+  material->search(matString)->select();
+}
+
+
+void Object::BoxObject(void)
+{
+  readVertex ("-0.500000 -0.500000 0.500000");
+  readVertex ("0.500000 -0.500000 0.500000");
+  readVertex ("-0.500000 0.500000 0.500000");
+  readVertex ("0.500000 0.500000 0.500000");
+  readVertex ("-0.500000 0.500000 -0.500000");
+  readVertex ("0.500000 0.500000 -0.500000");
+  readVertex ("-0.500000 -0.500000 -0.500000");
+  readVertex ("0.500000 -0.500000 -0.500000");
+  readVertexTexture ("0.000000 0.000000");
+  readVertexTexture ("1.000000 0.000000");
+  readVertexTexture ("0.000000 1.000000");
+  readVertexTexture ("1.000000 1.000000");
+  readVertexTexture ("0.000000 2.000000");
+  readVertexTexture ("1.000000 2.000000");
+  readVertexTexture ("0.000000 3.000000");
+  readVertexTexture ("1.000000 3.000000");
+  readVertexTexture ("0.000000 4.000000");
+  readVertexTexture ("1.000000 4.000000");
+  readVertexTexture ("2.000000 0.000000");
+  readVertexTexture ("2.000000 1.000000");
+  readVertexTexture ("-1.000000 0.000000");
+  readVertexTexture ("-1.000000 1.000000");
+  
+  readVertexNormal ("0.000000 0.000000 1.000000");
+  readVertexNormal ("0.000000 0.000000 1.000000");
+  readVertexNormal ("0.000000 0.000000 1.000000");
+  readVertexNormal ("0.000000 0.000000 1.000000");
+  readVertexNormal ("0.000000 1.000000 0.000000");
+  readVertexNormal ("0.000000 1.000000 0.000000");
+  readVertexNormal ("0.000000 1.000000 0.000000");
+  readVertexNormal ("0.000000 1.000000 0.000000");
+  readVertexNormal ("0.000000 0.000000 -1.000000");
+  readVertexNormal ("0.000000 0.000000 -1.000000");
+  readVertexNormal ("0.000000 0.000000 -1.000000");
+  readVertexNormal ("0.000000 0.000000 -1.000000");
+  readVertexNormal ("0.000000 -1.000000 0.000000");
+  readVertexNormal ("0.000000 -1.000000 0.000000");
+  readVertexNormal ("0.000000 -1.000000 0.000000");
+  readVertexNormal ("0.000000 -1.000000 0.000000");
+  readVertexNormal ("1.000000 0.000000 0.000000");
+  readVertexNormal ("1.000000 0.000000 0.000000");
+  readVertexNormal ("1.000000 0.000000 0.000000");
+  readVertexNormal ("1.000000 0.000000 0.000000");
+  readVertexNormal ("-1.000000 0.000000 0.000000");
+  readVertexNormal ("-1.000000 0.000000 0.000000");
+  readVertexNormal ("-1.000000 0.000000 0.000000");
+  readVertexNormal ("-1.000000 0.000000 0.000000");
+
+  readFace ("1/1/1 2/2/2 4/4/3 3/3/4");
+  readFace ("3/3/5 4/4/6 6/6/7 5/5/8");
+  readFace ("5/5/9 6/6/10 8/8/11 7/7/12");
+  readFace ("7/7/13 8/8/14 2/10/15 1/9/16");
+  readFace ("2/2/17 8/11/18 6/12/19 4/4/20");
+  readFace ("7/13/21 1/1/22 3/3/23 5/14/24");
+}
Index: orxonox/trunk/src/object.h
===================================================================
--- orxonox/trunk/src/object.h	(revision 2835)
+++ orxonox/trunk/src/object.h	(revision 2835)
@@ -0,0 +1,65 @@
+/*!
+ \file object.h
+ \brief Contains the Object Class that handles 3D-Objects
+*/
+
+#ifndef _OBJECT_H
+#define _OBJECT_H
+
+#include <GL/gl.h>
+#include <GL/glu.h>
+
+#include "array.h"
+#include "material.h"
+#include <fstream>
+
+using namespace std;
+
+//! Class that handles 3D-Objects. it can also read them in and display them.
+class Object
+{
+ public:
+  Object ();
+  Object (char* fileName);
+  Object(char* fileName, float scaling);
+  ~Object ();
+  
+  bool importFile (char* fileName);
+  bool initialize (void);
+  bool finalize(void);
+  void draw (void);
+
+  bool readFromObjFile (char* fileName);
+
+
+ private:
+  GLuint listNumber;
+  Array* vertices;
+  int verticesCount;
+  Array* colors;
+  Array* normals;
+  Array* vTexture;
+  char* objFileName;
+  char* mtlFileName;
+  int faceMode;
+  bool readVertices;
+  Material* material;
+  float scaleFactor;
+
+  ifstream* OBJ_FILE;
+  ifstream* MTL_FILE;
+  
+  bool readVertex (char* vertexString);
+  bool readFace (char* faceString);
+  bool readVT (char* vtString);
+  bool readVertexNormal (char* normalString);
+  bool readVertexTexture (char* vTextureString);
+  bool readMtlLib (char* matFile);
+  bool readUseMtl (char* mtlString);
+
+  bool addGLElement (char* elementString);
+
+  void BoxObject (void);
+};
+
+#endif
