git-svn-id: svn://db.shs.com.ru/libs@536 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -23,9 +23,7 @@
|
||||
|
||||
int main(int argc, char ** argv) {
|
||||
QApplication a(argc, argv);
|
||||
#if QT_VERSION >= 0x050000
|
||||
a.setAttribute(Qt::AA_UseHighDpiPixmaps, true);
|
||||
#endif
|
||||
QGLViewWindow w;
|
||||
w.show();
|
||||
QStringList al(a.arguments());
|
||||
|
||||
@@ -36,61 +36,61 @@ QGLViewWindow::QGLViewWindow(QWidget * parent): QMainWindow(parent), Ui::QGLView
|
||||
icon_light = QIcon(":/icons/type-light.png");
|
||||
|
||||
sel_obj = 0;
|
||||
view->camera().setAim(QVector3D());
|
||||
view->camera().setPos(QVector3D(2, 2, 2));
|
||||
view->setFrameShape(QFrame::NoFrame);
|
||||
view->setRenderer(new RendererSimple(view));
|
||||
view->setMouseRotateEnabled(true);
|
||||
view->setMouseSelectionEnabled(true);
|
||||
view->setSelectionHaloEnabled(true);
|
||||
view->setHoverHaloEnabled(true);
|
||||
view->setHoverHaloFillAlpha(0.);
|
||||
view->setSelectionHaloFillAlpha(0.);
|
||||
view->setBackColor(Qt::lightGray);
|
||||
view->setDepthStart(0.001);
|
||||
view->setDepthEnd(100000.);
|
||||
view->view()->camera().setAim(QVector3D());
|
||||
view->view()->camera().setPos(QVector3D(2, 2, 2));
|
||||
// view->setFrameShape(QFrame::NoFrame);
|
||||
view->view()->setRenderer(new RendererSimple(view->view()));
|
||||
view->view()->setMouseRotateEnabled(true);
|
||||
view->view()->setMouseSelectionEnabled(true);
|
||||
view->view()->setSelectionHaloEnabled(true);
|
||||
view->view()->setHoverHaloEnabled(true);
|
||||
view->view()->setHoverHaloFillAlpha(0.);
|
||||
view->view()->setSelectionHaloFillAlpha(0.);
|
||||
view->view()->setBackColor(Qt::lightGray);
|
||||
view->view()->setDepthStart(0.001);
|
||||
view->view()->setDepthEnd(100000.);
|
||||
|
||||
spinFOV->setValue(view->FOV());
|
||||
spinDepthStart->setValue(view->depthStart());
|
||||
spinDepthEnd->setValue(view->depthEnd());
|
||||
groupHoverHalo->setChecked(view->isHoverHaloEnabled());
|
||||
groupSelectionHalo->setChecked(view->isSelectionHaloEnabled());
|
||||
spinHoverHaloFill->setValue(view->hoverHaloFillAlpha());
|
||||
spinSelectionHaloFill->setValue(view->selectionHaloFillAlpha());
|
||||
colorHoverHalo->setColor(view->hoverHaloColor());
|
||||
colorSelectionHalo->setColor(view->selectionHaloColor());
|
||||
checkFXAA->setChecked(view->isFeatureEnabled(QGLView::qglFXAA));
|
||||
checkMSAA->setChecked(view->isFeatureEnabled(QGLView::qglMSAA));
|
||||
colorBack->setColor(view->backColor());
|
||||
colorAmbient->setColor(view->ambientColor());
|
||||
checkCameraOrbit->setChecked(view->isCameraOrbit());
|
||||
spinFOV->setValue(view->view()->FOV());
|
||||
spinDepthStart->setValue(view->view()->depthStart());
|
||||
spinDepthEnd->setValue(view->view()->depthEnd());
|
||||
groupHoverHalo->setChecked(view->view()->isHoverHaloEnabled());
|
||||
groupSelectionHalo->setChecked(view->view()->isSelectionHaloEnabled());
|
||||
spinHoverHaloFill->setValue(view->view()->hoverHaloFillAlpha());
|
||||
spinSelectionHaloFill->setValue(view->view()->selectionHaloFillAlpha());
|
||||
colorHoverHalo->setColor(view->view()->hoverHaloColor());
|
||||
colorSelectionHalo->setColor(view->view()->selectionHaloColor());
|
||||
checkFXAA->setChecked(view->view()->isFeatureEnabled(QGLView::qglFXAA));
|
||||
checkMSAA->setChecked(view->view()->isFeatureEnabled(QGLView::qglMSAA));
|
||||
colorBack->setColor(view->view()->backColor());
|
||||
colorAmbient->setColor(view->view()->ambientColor());
|
||||
checkCameraOrbit->setChecked(view->view()->isCameraOrbit());
|
||||
|
||||
groupShadows->setChecked(view->isFeatureEnabled(QGLView::qglShadowsEnabled));
|
||||
groupEyeAccomodation->setChecked(view->isFeatureEnabled(QGLView::qglEyeAccomodationEnabled));
|
||||
groupBloom->setChecked(view->isFeatureEnabled(QGLView::qglBloomEnabled));
|
||||
groupMotionBlur->setChecked(view->isFeatureEnabled(QGLView::qglMotionBlurEnabled));
|
||||
groupReflections->setChecked(view->isFeatureEnabled(QGLView::qglReflectionsEnabled));
|
||||
checkSoftShadows->setChecked(view->isFeatureEnabled(QGLView::qglShadowsSoftEnabled));
|
||||
groupSSAO->setChecked(view->isFeatureEnabled(QGLView::qglSSAOEnabled));
|
||||
spinAccom->setValue(view->feature(QGLView::qglEyeAccomodationTime).toDouble());
|
||||
spinAccomMS->setValue(view->feature(QGLView::qglEyeAccomodationMaxSpeed).toDouble());
|
||||
checkReflectionsBlur->setChecked(view->isFeatureEnabled(QGLView::qglReflectionsBlur));
|
||||
spinShadowmapSize->setValue(view->feature(QGLView::qglShadowsMapSize).toInt());
|
||||
spinMotionBlurFactor->setValue(view->feature(QGLView::qglMotionBlurFactor).toDouble());
|
||||
spinMotionBlurSteps->setValue(view->feature(QGLView::qglMotionBlurSteps).toInt());
|
||||
spinBloomFactor->setValue(view->feature(QGLView::qglBloomFactor).toDouble());
|
||||
spinBloomRadius->setValue(view->feature(QGLView::qglBloomRadius).toInt());
|
||||
spinBloomThreshold->setValue(view->feature(QGLView::qglBloomThreshold).toDouble());
|
||||
spinSSAORadius->setValue(view->feature(QGLView::qglSSAORadius).toInt());
|
||||
groupDOF->setChecked(view->isFeatureEnabled(QGLView::qglDepthOfFieldEnabled));
|
||||
checkDOFAutoFocus->setChecked(view->isFeatureEnabled(QGLView::qglDepthOfFieldAutoFocusEnabled));
|
||||
spinDOFFocus->setValue(view->feature(QGLView::qglDepthOfFieldFocus).toDouble());
|
||||
spinDOFDiaphragm->setValue(view->feature(QGLView::qglDepthOfFieldDiaphragm).toDouble());
|
||||
spinDOFSpeed->setValue(view->feature(QGLView::qglDepthOfFieldAutoFocusSpeed).toDouble());
|
||||
groupShadows->setChecked(view->view()->isFeatureEnabled(QGLView::qglShadowsEnabled));
|
||||
groupEyeAccomodation->setChecked(view->view()->isFeatureEnabled(QGLView::qglEyeAccomodationEnabled));
|
||||
groupBloom->setChecked(view->view()->isFeatureEnabled(QGLView::qglBloomEnabled));
|
||||
groupMotionBlur->setChecked(view->view()->isFeatureEnabled(QGLView::qglMotionBlurEnabled));
|
||||
groupReflections->setChecked(view->view()->isFeatureEnabled(QGLView::qglReflectionsEnabled));
|
||||
checkSoftShadows->setChecked(view->view()->isFeatureEnabled(QGLView::qglShadowsSoftEnabled));
|
||||
groupSSAO->setChecked(view->view()->isFeatureEnabled(QGLView::qglSSAOEnabled));
|
||||
spinAccom->setValue(view->view()->feature(QGLView::qglEyeAccomodationTime).toDouble());
|
||||
spinAccomMS->setValue(view->view()->feature(QGLView::qglEyeAccomodationMaxSpeed).toDouble());
|
||||
checkReflectionsBlur->setChecked(view->view()->isFeatureEnabled(QGLView::qglReflectionsBlur));
|
||||
spinShadowmapSize->setValue(view->view()->feature(QGLView::qglShadowsMapSize).toInt());
|
||||
spinMotionBlurFactor->setValue(view->view()->feature(QGLView::qglMotionBlurFactor).toDouble());
|
||||
spinMotionBlurSteps->setValue(view->view()->feature(QGLView::qglMotionBlurSteps).toInt());
|
||||
spinBloomFactor->setValue(view->view()->feature(QGLView::qglBloomFactor).toDouble());
|
||||
spinBloomRadius->setValue(view->view()->feature(QGLView::qglBloomRadius).toInt());
|
||||
spinBloomThreshold->setValue(view->view()->feature(QGLView::qglBloomThreshold).toDouble());
|
||||
spinSSAORadius->setValue(view->view()->feature(QGLView::qglSSAORadius).toInt());
|
||||
groupDOF->setChecked(view->view()->isFeatureEnabled(QGLView::qglDepthOfFieldEnabled));
|
||||
checkDOFAutoFocus->setChecked(view->view()->isFeatureEnabled(QGLView::qglDepthOfFieldAutoFocusEnabled));
|
||||
spinDOFFocus->setValue(view->view()->feature(QGLView::qglDepthOfFieldFocus).toDouble());
|
||||
spinDOFDiaphragm->setValue(view->view()->feature(QGLView::qglDepthOfFieldDiaphragm).toDouble());
|
||||
spinDOFSpeed->setValue(view->view()->feature(QGLView::qglDepthOfFieldAutoFocusSpeed).toDouble());
|
||||
|
||||
axis = new GLObjectBase();
|
||||
GLObjectBase * obj;
|
||||
double al = 1.;
|
||||
float al = 1.;
|
||||
obj = new GLPrimitiveLine(QVector3D(0, 0, -al), QVector3D(0, 0, al));
|
||||
obj->material().color_diffuse = Qt::darkBlue; obj->setAcceptLight(false);
|
||||
axis->addChild(obj);
|
||||
@@ -100,19 +100,20 @@ QGLViewWindow::QGLViewWindow(QWidget * parent): QMainWindow(parent), Ui::QGLView
|
||||
obj = new GLPrimitiveLine(QVector3D(0, -al, 0), QVector3D(0, al, 0));
|
||||
obj->material().color_diffuse = Qt::darkGreen; obj->setAcceptLight(false);
|
||||
axis->addChild(obj);
|
||||
view->addObject(axis);
|
||||
view->view()->addObject(axis);
|
||||
|
||||
cam_light = new Light();
|
||||
cam_light->intensity = 0.5;
|
||||
cam_light->setName("Camera_Light");
|
||||
view->camera().addChild(cam_light);
|
||||
view->start(-1);
|
||||
view->view()->camera().addChild(cam_light);
|
||||
view->view()->start(-1);
|
||||
startTimer(1000/60);
|
||||
|
||||
connect(view, SIGNAL(selectionChanged(GLObjectBase*,GLObjectBase*)), this, SLOT(selectionChanged(GLObjectBase*,GLObjectBase*)));
|
||||
connect(view->view(), SIGNAL(selectionChanged(GLObjectBase*,GLObjectBase*)), this, SLOT(selectionChanged(GLObjectBase*,GLObjectBase*)));
|
||||
connect(view->view(), SIGNAL(keyEvent(Qt::Key, Qt::KeyboardModifiers)), this, SLOT(view_keyEvent(Qt::Key, Qt::KeyboardModifiers)));
|
||||
connect(matEditor, SIGNAL(changed()), this, SLOT(materialChanged()));
|
||||
|
||||
//view->addObject(&partsys);
|
||||
//view->view()->addObject(&partsys);
|
||||
partsys.material().color_diffuse = Qt::red;
|
||||
treeProps->assignObject(&partsys);
|
||||
session.load();
|
||||
@@ -138,24 +139,8 @@ void QGLViewWindow::timerEvent(QTimerEvent * ) {
|
||||
//static double t = 0.;
|
||||
//cam_light->intensity = checkCameraLight->isChecked() ? 0.5 : 0.;
|
||||
cam_light->setVisible(checkCameraLight->isChecked());
|
||||
//((RendererSimple*)(view->renderer()))->mpos = view->mapFromGlobal(QCursor::pos());
|
||||
statusBar()->showMessage(QString("FPS: %1").arg(QString::number(view->currentFPS(), 'f', 2)));
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_view_glKeyPressEvent(QKeyEvent * e) {
|
||||
if (e->key() != Qt::Key_F11) return;
|
||||
if (view->windowState().testFlag(Qt::WindowFullScreen)) {
|
||||
centralwidget->layout()->addWidget(view);
|
||||
} else {
|
||||
view->setParent(0);
|
||||
view->showFullScreen();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_view_glInitializeDone() {
|
||||
|
||||
//((RendererSimple*)(view->view()->renderer()))->mpos = view->view()->mapFromGlobal(QCursor::pos());
|
||||
statusBar()->showMessage(QString("FPS: %1").arg(QString::number(view->view()->currentFPS(), 'f', 2)));
|
||||
}
|
||||
|
||||
|
||||
@@ -180,7 +165,7 @@ void QGLViewWindow::importFile(const QString & path) {
|
||||
return;
|
||||
}
|
||||
o->setName(fi.baseName());
|
||||
view->addObject(o);
|
||||
view->view()->addObject(o);
|
||||
objectsTreeChanged();
|
||||
}
|
||||
|
||||
@@ -233,18 +218,18 @@ void QGLViewWindow::materialChanged() {
|
||||
void QGLViewWindow::on_comboRenderer_currentIndexChanged(int val) {
|
||||
GLRendererBase * pr = 0;
|
||||
switch (val) {
|
||||
case 0: view->setRenderer(new RendererSimple(view), &pr); break;
|
||||
case 1: view->setRenderer(new RendererDeferredShading(view), &pr); break;
|
||||
//case 2: view->setRenderer(new RendererRT(view), &pr); break;
|
||||
case 0: view->view()->setRenderer(new RendererSimple(view->view()), &pr); break;
|
||||
case 1: view->view()->setRenderer(new RendererDeferredShading(view->view()), &pr); break;
|
||||
//case 2: view->view()->setRenderer(new RendererRT(view), &pr); break;
|
||||
}
|
||||
if (pr != 0) delete pr;
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_actionReset_triggered() {
|
||||
view->removeObject(axis, false);
|
||||
view->clearObjects(true);
|
||||
view->addObject(axis);
|
||||
view->view()->removeObject(axis, false);
|
||||
view->view()->clearObjects(true);
|
||||
view->view()->addObject(axis);
|
||||
objectsTreeChanged();
|
||||
}
|
||||
|
||||
@@ -269,11 +254,11 @@ void QGLViewWindow::on_actionSave_triggered() {
|
||||
if (f.right(4).toLower() != ".qgl")
|
||||
f += ".qgl";
|
||||
prev_path = f;
|
||||
view->removeObject(axis);
|
||||
view->view()->removeObject(axis);
|
||||
QApplication::setOverrideCursor(Qt::WaitCursor);
|
||||
saveToQGLFile(f, &(view->rootObject()));
|
||||
saveToQGLFile(f, &(view->view()->rootObject()));
|
||||
QApplication::restoreOverrideCursor();
|
||||
view->addObject(axis);
|
||||
view->view()->addObject(axis);
|
||||
}
|
||||
|
||||
|
||||
@@ -303,16 +288,16 @@ void QGLViewWindow::on_actionOpen_triggered() {
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_view_keyEvent(Qt::Key k, Qt::KeyboardModifiers m) {
|
||||
void QGLViewWindow::view_keyEvent(Qt::Key k, Qt::KeyboardModifiers m) {
|
||||
//qDebug() << k;
|
||||
double spd = 0.2;
|
||||
if (m.testFlag(Qt::ShiftModifier))
|
||||
spd = 0.5;
|
||||
switch (k) {
|
||||
case Qt::Key_W: view->camera().moveForward(spd); break;
|
||||
case Qt::Key_S: view->camera().moveBackward(spd); break;
|
||||
case Qt::Key_A: view->camera().moveLeft(spd); break;
|
||||
case Qt::Key_D: view->camera().moveRight(spd); break;
|
||||
case Qt::Key_W: view->view()->camera().moveForward(spd); break;
|
||||
case Qt::Key_S: view->view()->camera().moveBackward(spd); break;
|
||||
case Qt::Key_A: view->view()->camera().moveLeft(spd); break;
|
||||
case Qt::Key_D: view->view()->camera().moveRight(spd); break;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
@@ -322,28 +307,28 @@ void QGLViewWindow::on_treeObjects_itemClicked(QTreeWidgetItem * ti, int col) {
|
||||
((GLObjectBase*)(ti->data(0, Qt::UserRole).toULongLong()))->select();
|
||||
//qDebug() << ((GLObjectBase*)(ti->data(0, Qt::UserRole).toULongLong()))->type();
|
||||
if (sel_obj->type() == GLObjectBase::glCamera)
|
||||
view->setCamera(*(Camera*)sel_obj);
|
||||
view->view()->setCamera(*(Camera*)sel_obj);
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::objectsTreeChanged() {
|
||||
treeObjects->clear();
|
||||
makeObjetTree(&(view->rootObject()), treeObjects->invisibleRootItem());
|
||||
makeObjetTree(&(view->view()->rootObject()), treeObjects->invisibleRootItem());
|
||||
treeObjects->expandAll();
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_pushButton_clicked() {
|
||||
//view->removeLight(view->lightsCount() - 1);
|
||||
//setWindowTitle(QString::number(view->lightsCount()));
|
||||
QVector3D wp = view->light(0)->worldPos();
|
||||
view->camera().setPos(wp);
|
||||
view->camera().setAim(wp + (view->light(0)->worldTransform() * QVector4D(view->light(0)->direction)).toVector3D()*100);
|
||||
//view->view()->removeLight(view->view()->lightsCount() - 1);
|
||||
//setWindowTitle(QString::number(view->view()->lightsCount()));
|
||||
QVector3D wp = view->view()->light(0)->worldPos();
|
||||
view->view()->camera().setPos(wp);
|
||||
view->view()->camera().setAim(wp + (view->view()->light(0)->worldTransform() * QVector4D(view->view()->light(0)->direction)).toVector3D()*100);
|
||||
}
|
||||
|
||||
|
||||
void QGLViewWindow::on_pushButton_3_clicked() {
|
||||
QList<GLObjectBase * > ol = view->objects(true);
|
||||
QList<GLObjectBase * > ol = view->view()->objects(true);
|
||||
qDebug() << ol.size();
|
||||
foreach (GLObjectBase * i, ol) {
|
||||
i->VBO().rebuffer();
|
||||
|
||||
@@ -38,6 +38,8 @@
|
||||
#include "session_manager.h"
|
||||
//#include "renderer_rt.h"
|
||||
#include "glparticles_system.h"
|
||||
#include "qglview.h"
|
||||
#include "ui_qglview_window.h"
|
||||
|
||||
|
||||
class QGLViewWindow: public QMainWindow, public Ui::QGLViewWindow
|
||||
@@ -70,45 +72,45 @@ private:
|
||||
GLParticlesSystem partsys;
|
||||
|
||||
private slots:
|
||||
void on_spinFOV_valueChanged(double val) {view->setFOV(val);}
|
||||
void on_spinDepthStart_valueChanged(double val) {view->setDepthStart(val);}
|
||||
void on_spinDepthEnd_valueChanged(double val) {view->setDepthEnd(val);}
|
||||
void on_spinFOV_valueChanged(double val) {view->view()->setFOV(val);}
|
||||
void on_spinDepthStart_valueChanged(double val) {view->view()->setDepthStart(val);}
|
||||
void on_spinDepthEnd_valueChanged(double val) {view->view()->setDepthEnd(val);}
|
||||
void on_comboRenderer_currentIndexChanged(int val);
|
||||
void on_comboViewRenderMode_currentIndexChanged(int val) {static int modes[] = {GL_POINT, GL_LINE, GL_FILL}; view->setRenderMode((GLObjectBase::RenderMode)modes[val]);}
|
||||
void on_groupHoverHalo_clicked(bool val) {view->setHoverHaloEnabled(val);}
|
||||
void on_groupSelectionHalo_clicked(bool val) {view->setSelectionHaloEnabled(val);}
|
||||
void on_spinHoverHaloFill_valueChanged(double val) {view->setHoverHaloFillAlpha(val);}
|
||||
void on_spinSelectionHaloFill_valueChanged(double val) {view->setSelectionHaloFillAlpha(val);}
|
||||
void on_colorHoverHalo_colorChanged(QColor color) {view->setHoverHaloColor(color);}
|
||||
void on_colorSelectionHalo_colorChanged(QColor color) {view->setSelectionHaloColor(color);}
|
||||
void on_checkFXAA_clicked(bool val) {view->setFeature(QGLView::qglFXAA, val);}
|
||||
void on_checkMSAA_clicked(bool val) {view->setFeature(QGLView::qglMSAA, val);}
|
||||
void on_colorBack_colorChanged(QColor color) {view->setBackColor(color);}
|
||||
void on_colorAmbient_colorChanged(QColor color) {view->setAmbientColor(color);}
|
||||
void on_checkCameraOrbit_clicked(bool val) {view->setCameraOrbit(val);}
|
||||
void on_comboViewRenderMode_currentIndexChanged(int val) {static int modes[] = {GL_POINT, GL_LINE, GL_FILL}; view->view()->setRenderMode((GLObjectBase::RenderMode)modes[val]);}
|
||||
void on_groupHoverHalo_clicked(bool val) {view->view()->setHoverHaloEnabled(val);}
|
||||
void on_groupSelectionHalo_clicked(bool val) {view->view()->setSelectionHaloEnabled(val);}
|
||||
void on_spinHoverHaloFill_valueChanged(double val) {view->view()->setHoverHaloFillAlpha(val);}
|
||||
void on_spinSelectionHaloFill_valueChanged(double val) {view->view()->setSelectionHaloFillAlpha(val);}
|
||||
void on_colorHoverHalo_colorChanged(QColor color) {view->view()->setHoverHaloColor(color);}
|
||||
void on_colorSelectionHalo_colorChanged(QColor color) {view->view()->setSelectionHaloColor(color);}
|
||||
void on_checkFXAA_clicked(bool val) {view->view()->setFeature(QGLView::qglFXAA, val);}
|
||||
void on_checkMSAA_clicked(bool val) {view->view()->setFeature(QGLView::qglMSAA, val);}
|
||||
void on_colorBack_colorChanged(QColor color) {view->view()->setBackColor(color);}
|
||||
void on_colorAmbient_colorChanged(QColor color) {view->view()->setAmbientColor(color);}
|
||||
void on_checkCameraOrbit_clicked(bool val) {view->view()->setCameraOrbit(val);}
|
||||
|
||||
void on_groupShadows_clicked(bool val) {view->setFeature(QGLView::qglShadowsEnabled, val);}
|
||||
void on_groupEyeAccomodation_clicked(bool val) {view->setFeature(QGLView::qglEyeAccomodationEnabled, val);}
|
||||
void on_groupBloom_clicked(bool val) {view->setFeature(QGLView::qglBloomEnabled, val);}
|
||||
void on_groupMotionBlur_clicked(bool val) {view->setFeature(QGLView::qglMotionBlurEnabled, val);}
|
||||
void on_groupReflections_clicked(bool val) {view->setFeature(QGLView::qglReflectionsEnabled, val);}
|
||||
void on_checkSoftShadows_clicked(bool val) {view->setFeature(QGLView::qglShadowsSoftEnabled, val);}
|
||||
void on_groupSSAO_clicked(bool val) {view->setFeature(QGLView::qglSSAOEnabled, val);}
|
||||
void on_groupDOF_clicked(bool val) {view->setFeature(QGLView::qglDepthOfFieldEnabled, val);}
|
||||
void on_checkDOFAutoFocus_clicked(bool val) {view->setFeature(QGLView::qglDepthOfFieldAutoFocusEnabled, val);}
|
||||
void on_spinDOFFocus_valueChanged(double val) {view->setFeature(QGLView::qglDepthOfFieldFocus, val);}
|
||||
void on_spinDOFDiaphragm_valueChanged(double val) {view->setFeature(QGLView::qglDepthOfFieldDiaphragm, val);}
|
||||
void on_spinDOFSpeed_valueChanged(double val) {view->setFeature(QGLView::qglDepthOfFieldAutoFocusSpeed, val);}
|
||||
void on_spinAccom_valueChanged(double val) {view->setFeature(QGLView::qglEyeAccomodationTime, val);}
|
||||
void on_spinAccomMS_valueChanged(double val) {view->setFeature(QGLView::qglEyeAccomodationMaxSpeed, val);}
|
||||
void on_checkReflectionsBlur_clicked(bool val) {view->setFeature(QGLView::qglReflectionsBlur, val);}
|
||||
void on_spinShadowmapSize_valueChanged(double val) {view->setFeature(QGLView::qglShadowsMapSize, val);}
|
||||
void on_spinMotionBlurFactor_valueChanged(double val) {view->setFeature(QGLView::qglMotionBlurFactor, val);}
|
||||
void on_spinMotionBlurSteps_valueChanged(int val) {view->setFeature(QGLView::qglMotionBlurSteps, val);}
|
||||
void on_spinBloomFactor_valueChanged(double val) {view->setFeature(QGLView::qglBloomFactor, val);}
|
||||
void on_spinBloomRadius_valueChanged(int val) {view->setFeature(QGLView::qglBloomRadius, val);}
|
||||
void on_spinBloomThreshold_valueChanged(double val) {view->setFeature(QGLView::qglBloomThreshold, val);}
|
||||
void on_spinSSAORadius_valueChanged(int val) {view->setFeature(QGLView::qglSSAORadius, val);}
|
||||
void on_groupShadows_clicked(bool val) {view->view()->setFeature(QGLView::qglShadowsEnabled, val);}
|
||||
void on_groupEyeAccomodation_clicked(bool val) {view->view()->setFeature(QGLView::qglEyeAccomodationEnabled, val);}
|
||||
void on_groupBloom_clicked(bool val) {view->view()->setFeature(QGLView::qglBloomEnabled, val);}
|
||||
void on_groupMotionBlur_clicked(bool val) {view->view()->setFeature(QGLView::qglMotionBlurEnabled, val);}
|
||||
void on_groupReflections_clicked(bool val) {view->view()->setFeature(QGLView::qglReflectionsEnabled, val);}
|
||||
void on_checkSoftShadows_clicked(bool val) {view->view()->setFeature(QGLView::qglShadowsSoftEnabled, val);}
|
||||
void on_groupSSAO_clicked(bool val) {view->view()->setFeature(QGLView::qglSSAOEnabled, val);}
|
||||
void on_groupDOF_clicked(bool val) {view->view()->setFeature(QGLView::qglDepthOfFieldEnabled, val);}
|
||||
void on_checkDOFAutoFocus_clicked(bool val) {view->view()->setFeature(QGLView::qglDepthOfFieldAutoFocusEnabled, val);}
|
||||
void on_spinDOFFocus_valueChanged(double val) {view->view()->setFeature(QGLView::qglDepthOfFieldFocus, val);}
|
||||
void on_spinDOFDiaphragm_valueChanged(double val) {view->view()->setFeature(QGLView::qglDepthOfFieldDiaphragm, val);}
|
||||
void on_spinDOFSpeed_valueChanged(double val) {view->view()->setFeature(QGLView::qglDepthOfFieldAutoFocusSpeed, val);}
|
||||
void on_spinAccom_valueChanged(double val) {view->view()->setFeature(QGLView::qglEyeAccomodationTime, val);}
|
||||
void on_spinAccomMS_valueChanged(double val) {view->view()->setFeature(QGLView::qglEyeAccomodationMaxSpeed, val);}
|
||||
void on_checkReflectionsBlur_clicked(bool val) {view->view()->setFeature(QGLView::qglReflectionsBlur, val);}
|
||||
void on_spinShadowmapSize_valueChanged(double val) {view->view()->setFeature(QGLView::qglShadowsMapSize, val);}
|
||||
void on_spinMotionBlurFactor_valueChanged(double val) {view->view()->setFeature(QGLView::qglMotionBlurFactor, val);}
|
||||
void on_spinMotionBlurSteps_valueChanged(int val) {view->view()->setFeature(QGLView::qglMotionBlurSteps, val);}
|
||||
void on_spinBloomFactor_valueChanged(double val) {view->view()->setFeature(QGLView::qglBloomFactor, val);}
|
||||
void on_spinBloomRadius_valueChanged(int val) {view->view()->setFeature(QGLView::qglBloomRadius, val);}
|
||||
void on_spinBloomThreshold_valueChanged(double val) {view->view()->setFeature(QGLView::qglBloomThreshold, val);}
|
||||
void on_spinSSAORadius_valueChanged(int val) {view->view()->setFeature(QGLView::qglSSAORadius, val);}
|
||||
|
||||
void on_actionExit_triggered() {close();}
|
||||
void on_actionReset_triggered();
|
||||
@@ -117,9 +119,7 @@ private slots:
|
||||
void on_actionSaveSelected_triggered();
|
||||
void on_actionOpen_triggered();
|
||||
|
||||
void on_view_glKeyPressEvent(QKeyEvent * e);
|
||||
void on_view_glInitializeDone();
|
||||
void on_view_keyEvent(Qt::Key k, Qt::KeyboardModifiers m);
|
||||
void view_keyEvent(Qt::Key k, Qt::KeyboardModifiers m);
|
||||
|
||||
void on_treeObjects_itemClicked(QTreeWidgetItem * ti, int col);
|
||||
|
||||
@@ -128,7 +128,7 @@ private slots:
|
||||
void selectionChanged(GLObjectBase * cur, GLObjectBase * prev);
|
||||
|
||||
void on_pushButton_clicked();
|
||||
void on_pushButton_2_clicked() {view->reloadShaders();}
|
||||
void on_pushButton_2_clicked() {view->view()->reloadShaders();}
|
||||
void on_pushButton_3_clicked();
|
||||
|
||||
public slots:
|
||||
|
||||
@@ -1015,7 +1015,7 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGLView" name="view" native="true">
|
||||
<widget class="GLWidget" name="view" native="true">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
@@ -1075,7 +1075,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1125</width>
|
||||
<height>24</height>
|
||||
<height>21</height>
|
||||
</rect>
|
||||
</property>
|
||||
<widget class="QMenu" name="menuFile">
|
||||
@@ -1096,7 +1096,7 @@
|
||||
<widget class="QStatusBar" name="statusBar_"/>
|
||||
<action name="actionExit">
|
||||
<property name="icon">
|
||||
<iconset>
|
||||
<iconset resource="../../qad/application/qad_application.qrc">
|
||||
<normaloff>:/icons/application-exit.png</normaloff>:/icons/application-exit.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1105,7 +1105,7 @@
|
||||
</action>
|
||||
<action name="actionImport">
|
||||
<property name="icon">
|
||||
<iconset>
|
||||
<iconset resource="../qglview.qrc">
|
||||
<normaloff>:/icons/document-import.png</normaloff>:/icons/document-import.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1117,7 +1117,7 @@
|
||||
</action>
|
||||
<action name="actionOpen">
|
||||
<property name="icon">
|
||||
<iconset resource="../../../SM/src/SignalModelling/signalmodelling.qrc">
|
||||
<iconset resource="../../qad/application/qad_application.qrc">
|
||||
<normaloff>:/icons/document-open.png</normaloff>:/icons/document-open.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1129,7 +1129,7 @@
|
||||
</action>
|
||||
<action name="actionSave">
|
||||
<property name="icon">
|
||||
<iconset resource="../../../SM/src/SignalModelling/signalmodelling.qrc">
|
||||
<iconset resource="../../qad/application/qad_application.qrc">
|
||||
<normaloff>:/icons/document-save-all.png</normaloff>:/icons/document-save-all.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1141,7 +1141,7 @@
|
||||
</action>
|
||||
<action name="actionReset">
|
||||
<property name="icon">
|
||||
<iconset resource="../../../SM/src/SMBricks/SM_plugins/signal_process/icons.qrc">
|
||||
<iconset resource="../../qad/application/qad_application.qrc">
|
||||
<normaloff>:/icons/document-new.png</normaloff>:/icons/document-new.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1153,7 +1153,7 @@
|
||||
</action>
|
||||
<action name="actionSaveSelected">
|
||||
<property name="icon">
|
||||
<iconset resource="../../../SM/src/SMBricks/SM_plugins/signal_process/icons.qrc">
|
||||
<iconset resource="../../piqt_utils/piconnedit/piconnedit.qrc">
|
||||
<normaloff>:/icons/document-save-.png</normaloff>:/icons/document-save-.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
@@ -1179,9 +1179,9 @@
|
||||
<header>colorbutton.h</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>QGLView</class>
|
||||
<class>GLWidget</class>
|
||||
<extends>QWidget</extends>
|
||||
<header location="global">qglview.h</header>
|
||||
<header location="global">glwidget.h</header>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
@@ -1202,6 +1202,10 @@
|
||||
<header>propertyeditor.h</header>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<resources/>
|
||||
<resources>
|
||||
<include location="../../qad/application/qad_application.qrc"/>
|
||||
<include location="../../piqt_utils/piconnedit/piconnedit.qrc"/>
|
||||
<include location="../qglview.qrc"/>
|
||||
</resources>
|
||||
<connections/>
|
||||
</ui>
|
||||
|
||||
Reference in New Issue
Block a user