Namespaces | Functions

model-parsing.cpp File Reference

#include "glut-model.h"
#include <fstream>
#include "common/wave_ex.h"
#include "glut/glut.h"
#include "glut/texture.h"
#include "nstream/nstream.h"
#include "perf/perf.h"
#include "util/file.h"
#include "util/parsing.h"
#include "util/token_stream.h"
Include dependency graph for model-parsing.cpp:

Go to the source code of this file.

Namespaces

namespace  glut

Functions

static void glut::getDictionaryFromNextLine (std::istream &stream, const char *debug_info, dictionary_t &d)
static byte_t glut::getOptionalByte (const dictionary_t &d, const char *key)
static void glut::writePoint3dToStream (std::ostream &stream, const point3d_t &p)
void glut::parseColor (std::istream &stream, img_color_t &color)
void glut::parseMaterial (std::istream &stream, const char *parentDir, material_t &material)
void glut::parsePolygon (MaterialRegistry *mreg, std::istream &stream, polygon_t &polygon)
void glut::parseModel (MaterialRegistry *mreg, std::istream &stream, model_t &model)
void glut::parseLodEntry (MaterialRegistry *mreg, std::istream &stream, lod_entry_t &entry)
void glut::parseLodModel (MaterialRegistry *mreg, std::istream &stream, lod_model_t &lod_model)
void glut::writeModelToStream (std::ostream &stream, const model_t &model)
 assumes you have already written the key name, this will write the opening and closing brackets
smart_ptr< Renderable > glut::loadModel (const char *filename, MaterialRegistry *reg)
 load a model from a Wavepacket Glut Model file (.wgm extension, normally)