Linux multi-monitor fullscreen support
[ryzomcore.git] / nel / tools / 3d / object_viewer_widget / src / interfaces.h
blobe47f5875f17860a30abeed59b16bd92e448d15ca
1 /*
2 Object Viewer Qt Widget
3 Copyright (C) 2010 Adrian Jaekel <aj at elane2k dot com>
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
19 #ifndef INTERFACES_H
20 #define INTERFACES_H
22 #include "stdpch.h"
23 #include "entity.h"
25 #include <QtPlugin>
27 namespace NL3D
29 class UPlayListManager;
30 class UDriver;
31 class UScene;
34 namespace NLQT
37 class IObjectViewer
40 public:
42 virtual ~IObjectViewer() {}
44 virtual QString name() const = 0;
46 // object viewer stuff
47 virtual void init() = 0;
48 virtual void release() = 0;
49 virtual void updateInput() = 0;
50 virtual void renderDriver() = 0;
51 virtual void renderScene() = 0;
52 virtual void renderDebug2D() = 0;
53 virtual void saveScreenshot(const std::string &nameFile, bool jpg, bool png, bool tga) = 0;
54 virtual bool loadMesh (const std::string &meshFileName, const std::string &skelFileName) = 0;
55 virtual void resetScene() = 0;
56 virtual void setBackgroundColor(NLMISC::CRGBA backgroundColor) = 0;
57 virtual void setGraphicsDriver(bool Direct3D) = 0;
58 virtual void setSizeViewport(uint16 w, uint16 h) = 0;
59 virtual void setBloomEffect(bool enabled) = 0;
60 virtual void setCurrentObject(const std::string &name) = 0;
61 virtual const std::string& getCurrentObject() = 0;
62 virtual CEntity& getEntity(const std::string &name) = 0;
63 virtual void getListObjects(std::vector<std::string> &listObj) = 0;
64 virtual NLMISC::CRGBA getBackgroundColor() = 0;
65 virtual bool getDirect3D() = 0;
66 virtual bool getBloomEffect() const = 0;
67 virtual NL3D::UDriver *getDriver() = 0;
68 virtual NL3D::UScene *getScene() = 0;
69 virtual NL3D::UPlayListManager *getPlayListManager() = 0;
70 virtual void setCamera(NL3D::UScene *scene, NLMISC::CAABBox &bbox, NL3D::UTransform &entity, bool high_z) = 0;
71 virtual bool setupLight(const NLMISC::CVector &position, const NLMISC::CVector &direction) = 0;
72 virtual void setVisible(bool visible) = 0;
73 virtual QWidget* getWidget() = 0;
74 virtual void setNelContext(NLMISC::INelContext &nelContext) = 0;
75 virtual QIcon* saveOneImage(std::string shapename) = 0;
79 } /* namespace NLQT */
81 Q_DECLARE_INTERFACE(NLQT::IObjectViewer,"com.ryzom.dev.IObjectViewer/0.1")
83 #endif