source: flair-src/trunk/lib/FlairSimulator/src/Parser.h@ 156

Last change on this file since 156 was 138, checked in by Sanahuja Guillaume, 8 years ago

color cylinder

File size: 1.5 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5// created: 2013/08/02
6// filename: Parser.h
7//
8// author: César Richard
9// Copyright Heudiasyc UMR UTC/CNRS 7253
10//
11// version: $Id: $
12//
13// purpose: classe chargeant un XML decrivant une map
14//
15/*********************************************************************/
16
17#ifndef PARSER_H
18#define PARSER_H
19
20#include <Gui.h>
21#include <libxml/parser.h>
22#include <libxml/tree.h>
23#include <SColor.h>
24
25namespace flair {
26 namespace core {
27 class Vector3D;
28 }
29}
30
31namespace flair {
32namespace simulator {
33class Parser : public Gui {
34
35 /*can create:
36 - cylinders: in y axis
37 - fixed cameras
38
39 */
40public:
41 Parser(Simulator *parent, int app_width, int app_height, int scene_width,
42 int scene_height, std::string media_path, std::string xmlFile);
43 ~Parser();
44
45private:
46 xmlDoc *doc;
47 std::string media_path;
48 Simulator *parent;
49 void processElements(xmlNode *a_node);
50 void processObjects(xmlNode *a_node);
51 void processParams(xmlNode *a_node);
52 irr::video::SColor getScolor(xmlNode *mesh_node);
53 irr::core::vector3df getMeshVect(xmlNode *mesh_node, xmlChar *param);
54 irr::core::vector3df getSceneVect(xmlNode *mesh_node, xmlChar *param,
55 bool isScale = false);
56 core::Vector3D getMeshVector3D(xmlNode *mesh_node, xmlChar *param);
57};
58}
59}
60#endif // PARSER_H
Note: See TracBrowser for help on using the repository browser.