multimaterial support, "preset"

each preset contains visibility, flags and material
This commit is contained in:
2023-05-16 18:18:26 +03:00
parent c275d006d5
commit 484a7f972f
11 changed files with 523 additions and 259 deletions

View File

@@ -46,6 +46,8 @@ void ViewEditor::assignQGLView(QGLView * v) {
view = v;
if (!view) return;
active = false;
connect(view->scene(), &Scene::presetChanged, this, [this](int p) { ui->labelPreset->setNum(p); });
ui->labelPreset->setNum(view->scene()->preset());
ui->spinFOV->setValue(view->FOV());
ui->spinDepthStart->setValue(view->depthStart());
ui->checkHoverHalo->setChecked(view->isHoverHaloEnabled());
@@ -213,6 +215,11 @@ void ViewEditor::on_buttonHDRSelect_clicked() {
}
void ViewEditor::on_buttonPresetSet_clicked() {
view->scene()->setPreset(ui->spinPreset->value());
}
void ViewEditor::on_colorFogBack_colorChanged(const QColor & color) {
if (!view || !active) return;
view->setFogColor(color);