много исправлений
This commit is contained in:
20
qglview.h
20
qglview.h
@@ -34,13 +34,11 @@ class QGLView: public OpenGLWindow
|
||||
{
|
||||
friend class RendererSelection;
|
||||
Q_OBJECT
|
||||
Q_PROPERTY (QColor backColor READ backColor WRITE setBackColor)
|
||||
Q_PROPERTY (float lineWidth READ lineWidth WRITE setLineWidth)
|
||||
Q_PROPERTY (float FOV READ FOV WRITE setFOV)
|
||||
Q_PROPERTY (float depthStart READ depthStart WRITE setDepthStart)
|
||||
Q_PROPERTY (float gamma READ gamma WRITE setGamma)
|
||||
Q_PROPERTY (bool autoExposure READ autoExposure WRITE setAutoExposure)
|
||||
Q_PROPERTY (QColor ambientColor READ ambientColor WRITE setAmbientColor)
|
||||
Q_PROPERTY (QColor fogColor READ fogColor WRITE setFogColor)
|
||||
Q_PROPERTY (bool fogEnabled READ isFogEnabled WRITE setFogEnabled)
|
||||
Q_PROPERTY (float fogDensity READ fogDensity WRITE setFogDensity)
|
||||
@@ -102,7 +100,6 @@ public:
|
||||
void stop();
|
||||
void start(float freq = 0.);
|
||||
|
||||
QColor backColor() const {return backColor_;}
|
||||
float lineWidth() const {return lineWidth_;}
|
||||
float FOV() const {return camera()->FOV();}
|
||||
float depthStart() const {return camera()->depthStart();}
|
||||
@@ -112,7 +109,6 @@ public:
|
||||
int maxAnisotropicLevel() const {return max_anisotropic;}
|
||||
QString environmentMapFile() const {return renderer_.tex_env.fileHDR();}
|
||||
|
||||
QColor ambientColor() const {return ambientColor_;}
|
||||
QColor fogColor() const {return fogColor_;}
|
||||
float fogDensity() const {return fogDensity_;}
|
||||
float fogDecay() const {return fogDecay_;}
|
||||
@@ -167,6 +163,7 @@ public:
|
||||
const Camera * camera() const {return camera_;}
|
||||
void setCamera(Camera * camera) {camera_ = camera;}
|
||||
void setDefaultCamera() {camera_ = default_camera;}
|
||||
bool isDefaultCamera() const {return camera_ == default_camera;}
|
||||
QByteArray saveCamera();
|
||||
void restoreCamera(const QByteArray & ba);
|
||||
QByteArray saveFeatures();
|
||||
@@ -209,8 +206,8 @@ private:
|
||||
MouseController mouse;
|
||||
QMenu context_menu;
|
||||
QSet<int> keys_;
|
||||
QColor backColor_, fogColor_, ambientColor_, hoverHaloColor_, selectionHaloColor_;
|
||||
QElapsedTimer time, ktm_;
|
||||
QColor fogColor_, hoverHaloColor_, selectionHaloColor_;
|
||||
QElapsedTimer time;
|
||||
GLint max_anisotropic, max_texture_chanels;
|
||||
ObjectBase::RenderMode rmode;
|
||||
QHash<int, QVariant> features_;
|
||||
@@ -218,23 +215,22 @@ private:
|
||||
float lineWidth_;
|
||||
float fps_, fps_tm, fogDensity_, fogDecay_;
|
||||
float hoverHaloFill_, selectionHaloFill_, m_motionBlurFactor;
|
||||
int timer, fps_cnt, sh_id_loc, deleting_;
|
||||
bool is_first_draw, is_init, fogEnabled_, lightEnabled_;
|
||||
bool shaders_supported, changed_, need_init_;
|
||||
bool hoverHalo_, selectionHalo_, shaders_bind;
|
||||
int timer, fps_cnt, sh_id_loc;
|
||||
bool fogEnabled_, lightEnabled_;
|
||||
bool shaders_supported, shaders_bind;
|
||||
bool hoverHalo_, selectionHalo_;
|
||||
bool is_init;
|
||||
|
||||
private slots:
|
||||
void __destroyed();
|
||||
void __objectDeleted(ObjectBase * o);
|
||||
|
||||
public slots:
|
||||
void setBackColor(const QColor & arg) {backColor_ = arg;}
|
||||
void setLineWidth(const float & arg) {lineWidth_ = arg;}
|
||||
void setFOV(const float & arg) {camera()->setFOV(arg);}
|
||||
void setDepthStart(const float & arg) {camera()->setDepthStart(arg);}
|
||||
void setGamma(const float & arg) {renderer_.gamma_ = arg;}
|
||||
void setAutoExposure(bool arg) {renderer_.tone_proc.enabled = arg;}
|
||||
void setAmbientColor(const QColor & arg) {ambientColor_ = arg;}
|
||||
void setEnvironmentMapFile(QString file) {renderer_.tex_env.setFileHDR(file); renderer_.recreateMaterialThumbnails(true);}
|
||||
void setFogColor(const QColor & arg) {fogColor_ = arg;}
|
||||
void setFogDensity(const float & arg) {fogDensity_ = arg;}
|
||||
|
||||
Reference in New Issue
Block a user