ScummVM API documentation
te_camera_xml_parser.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef TETRAEDGE_TE_TE_CAMERA_XML_PARSER_H
23 #define TETRAEDGE_TE_TE_CAMERA_XML_PARSER_H
24 
25 #include "tetraedge/te/te_xml_parser.h"
26 #include "tetraedge/te/te_camera.h"
27 
28 namespace Tetraedge {
29 
31 public:
32  // Parser
33  CUSTOM_XML_PARSER(TeCameraXmlParser) {
34  XML_KEY(camera)
35  XML_KEY(position)
36  XML_PROP(x, true)
37  XML_PROP(y, true)
38  XML_PROP(z, true)
39  KEY_END()
40  XML_KEY(rotation)
41  XML_PROP(x, true)
42  XML_PROP(y, true)
43  XML_PROP(z, true)
44  XML_PROP(w, true)
45  KEY_END()
46  XML_KEY(scale)
47  XML_PROP(x, true)
48  XML_PROP(y, true)
49  XML_PROP(z, true)
50  KEY_END()
51  XML_KEY(fov)
52  XML_PROP(value, true)
53  KEY_END()
54  XML_KEY(aspect)
55  XML_PROP(value, true)
56  KEY_END()
57  XML_KEY(near)
58  XML_PROP(value, true)
59  KEY_END()
60  XML_KEY(far)
61  XML_PROP(value, true)
62  KEY_END()
63  KEY_END()
64  } PARSER_END()
65 
66 public:
67  bool parserCallback_camera(ParserNode *node) { return true; }
68  bool parserCallback_position(ParserNode *node);
69  bool parserCallback_rotation(ParserNode *node);
70  bool parserCallback_scale(ParserNode *node);
71  bool parserCallback_fov(ParserNode *node);
72  bool parserCallback_aspect(ParserNode *node);
73  bool parserCallback_near(ParserNode *node);
74  bool parserCallback_far(ParserNode *node);
75 
76  TeCamera *_cam;
77 };
78 
79 } // end namespace Tetraedge
80 
81 #endif // TETRAEDGE_TE_TE_CAMERA_XML_PARSER_H
Definition: te_camera.h:38
Definition: detection.h:27
Definition: xmlparser.h:145
Definition: te_camera_xml_parser.h:30
Graphics::Surface * scale(const Graphics::Surface &srcImage, int xSize, int ySize)
Definition: te_xml_parser.h:38