Minor fixes, tweaks and code cleanups
This commit is contained in:
committed by
François Beaune
parent
b87417b79d
commit
a5c3020f24
+1
-3
@@ -1,6 +1,4 @@
|
||||
.vs/
|
||||
build/
|
||||
sandbox/shaders/
|
||||
__pycache__
|
||||
*.pyc
|
||||
*.pyo
|
||||
__pycache__
|
||||
|
||||
@@ -74,7 +74,7 @@ shader as_matte
|
||||
int as_blender_input_socket = 0,
|
||||
int gafferNoduleLayoutVisible = 0
|
||||
]],
|
||||
color in_matte_opacity_color = color(1,0.5,0)
|
||||
color in_matte_opacity_color = color(1, 0.5, 0)
|
||||
[[
|
||||
string as_maya_attribute_name = "matteOpacityColor",
|
||||
string as_maya_attribute_short_name = "mac",
|
||||
|
||||
@@ -398,6 +398,7 @@ int main(int argc, char* argv[])
|
||||
}
|
||||
}
|
||||
|
||||
// Show the application's main window.
|
||||
window.show();
|
||||
|
||||
return application.exec();
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace appleseed {
|
||||
namespace studio {
|
||||
|
||||
//
|
||||
// Collapsing section implementation.
|
||||
// CollapsibleSectionWidget class implementation.
|
||||
//
|
||||
|
||||
CollapsibleSectionWidget::CollapsibleSectionWidget(const QString& title, QWidget* parent)
|
||||
@@ -60,6 +60,7 @@ CollapsibleSectionWidget::CollapsibleSectionWidget(const QString& title, QWidget
|
||||
m_main_layout.addWidget(&m_content_area, 1, 0, 1, -1);
|
||||
|
||||
setLayout(&m_main_layout);
|
||||
|
||||
connect(&m_toggle_button, SIGNAL(toggled(bool)), SLOT(slot_on_click(const bool)));
|
||||
}
|
||||
|
||||
@@ -77,5 +78,5 @@ void CollapsibleSectionWidget::slot_on_click(const bool checked)
|
||||
m_content_area.setFixedHeight(checked ? m_content_height : 0);
|
||||
}
|
||||
|
||||
} // namespace studio
|
||||
} // namespace appleseed
|
||||
} // namespace studio
|
||||
} // namespace appleseed
|
||||
|
||||
@@ -52,6 +52,7 @@ class CollapsibleSectionWidget
|
||||
explicit CollapsibleSectionWidget(
|
||||
const QString& title = "",
|
||||
QWidget* parent = nullptr);
|
||||
|
||||
void set_content_layout(QLayout* content_layout);
|
||||
|
||||
private:
|
||||
@@ -65,5 +66,5 @@ class CollapsibleSectionWidget
|
||||
void slot_on_click(const bool);
|
||||
};
|
||||
|
||||
} // namespace studio
|
||||
} // namespace appleseed
|
||||
} // namespace studio
|
||||
} // namespace appleseed
|
||||
|
||||
@@ -41,7 +41,6 @@
|
||||
#include "mainwindow/project/projectexplorer.h"
|
||||
#include "mainwindow/pythonconsole/pythonconsolewidget.h"
|
||||
#include "mainwindow/rendering/lightpathstab.h"
|
||||
#include "mainwindow/rendering/materialdrophandler.h"
|
||||
#include "mainwindow/rendering/renderwidget.h"
|
||||
#include "utility/interop.h"
|
||||
#include "utility/miscellaneous.h"
|
||||
@@ -385,9 +384,10 @@ void MainWindow::build_menus()
|
||||
m_ui->menu_view->addAction(m_ui->attribute_editor->toggleViewAction());
|
||||
m_ui->menu_view->addAction(m_ui->log->toggleViewAction());
|
||||
m_ui->menu_view->addAction(m_ui->python_console->toggleViewAction());
|
||||
|
||||
m_ui->menu_view->addSeparator();
|
||||
|
||||
m_action_fullscreen = m_ui->menu_view->addAction("Fullscreen");
|
||||
m_action_fullscreen = m_ui->menu_view->addAction("&Full Screen");
|
||||
m_action_fullscreen->setCheckable(true);
|
||||
m_action_fullscreen->setShortcut(Qt::Key_F11);
|
||||
|
||||
@@ -863,10 +863,6 @@ void MainWindow::set_rendering_widgets_enabled(const bool is_enabled, const Rend
|
||||
const bool allow_start = is_enabled && is_project_open && rendering_mode == NotRendering;
|
||||
const bool allow_stop = is_enabled && is_project_open && rendering_mode != NotRendering;
|
||||
|
||||
// Rendering -> Rendering Settings.
|
||||
m_ui->action_rendering_rendering_settings->setEnabled(allow_start);
|
||||
m_action_rendering_settings->setEnabled(allow_start);
|
||||
|
||||
// Rendering -> Start Interactive Rendering.
|
||||
m_ui->action_rendering_start_interactive_rendering->setEnabled(allow_start);
|
||||
m_action_start_interactive_rendering->setEnabled(allow_start);
|
||||
@@ -883,8 +879,9 @@ void MainWindow::set_rendering_widgets_enabled(const bool is_enabled, const Rend
|
||||
m_ui->action_rendering_stop_rendering->setEnabled(allow_stop);
|
||||
m_action_stop_rendering->setEnabled(allow_stop);
|
||||
|
||||
// Rendering -> Render Settings.
|
||||
// Rendering -> Rendering Settings.
|
||||
m_ui->action_rendering_rendering_settings->setEnabled(allow_start);
|
||||
m_action_rendering_settings->setEnabled(allow_start);
|
||||
|
||||
// Render tab buttons.
|
||||
const int current_tab_index = m_ui->tab_render_channels->currentIndex();
|
||||
|
||||
@@ -24,7 +24,16 @@
|
||||
</property>
|
||||
<widget class="QWidget" name="main_window_contents">
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item row="0" column="0">
|
||||
@@ -369,21 +378,6 @@
|
||||
<string>Ctrl+Shift+0</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_navigation_inspect">
|
||||
<property name="text">
|
||||
<string>&Inspect</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_navigation_fly">
|
||||
<property name="text">
|
||||
<string>&Fly</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_navigation_freeze">
|
||||
<property name="text">
|
||||
<string>Free&ze</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_rendering_start_final_rendering">
|
||||
<property name="text">
|
||||
<string>Start &Final Rendering</string>
|
||||
@@ -451,19 +445,6 @@
|
||||
<string>Ctrl+Shift+S</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_clear_open_recent_menu">
|
||||
<property name="text">
|
||||
<string>Clear Menu</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_tools_watch_file_changes">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Watch File Changes</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="action_file_monitor_project">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
|
||||
@@ -43,6 +43,8 @@ namespace studio {
|
||||
class ICapturableWidget
|
||||
{
|
||||
public:
|
||||
virtual ~ICapturableWidget() = default;
|
||||
|
||||
virtual QImage capture() = 0;
|
||||
};
|
||||
|
||||
|
||||
@@ -483,26 +483,19 @@ void RenderTab::recreate_handlers()
|
||||
// Clipboard handler.
|
||||
m_clipboard_handler.reset(new RenderClipboardHandler(m_render_widget, m_render_widget));
|
||||
|
||||
// Set initial state.
|
||||
m_pixel_inspector_handler->set_enabled(false);
|
||||
m_camera_controller->set_enabled(false);
|
||||
m_scene_picking_handler->set_enabled(true); // todo: should be true by default
|
||||
|
||||
// Material drop handler.
|
||||
m_material_drop_handler.reset(
|
||||
new MaterialDropHandler(
|
||||
m_project,
|
||||
m_rendering_manager));
|
||||
|
||||
connect(
|
||||
m_render_widget,
|
||||
SIGNAL(signal_material_dropped(
|
||||
const foundation::Vector2d&,
|
||||
const QString&)),
|
||||
m_material_drop_handler.get(),
|
||||
SLOT(slot_material_dropped(
|
||||
const foundation::Vector2d&,
|
||||
const QString&)));
|
||||
m_render_widget, SIGNAL(signal_material_dropped(const foundation::Vector2d&, const QString&)),
|
||||
m_material_drop_handler.get(), SLOT(slot_material_dropped(const foundation::Vector2d&, const QString&)));
|
||||
|
||||
// Set initial state.
|
||||
m_pixel_inspector_handler->set_enabled(false);
|
||||
m_camera_controller->set_enabled(false);
|
||||
m_scene_picking_handler->set_enabled(true); // todo: should be true by default
|
||||
}
|
||||
|
||||
} // namespace studio
|
||||
|
||||
@@ -54,10 +54,9 @@ namespace OCIO = OCIO_NAMESPACE;
|
||||
|
||||
// Forward declarations.
|
||||
namespace appleseed { namespace studio { class ProjectExplorer; } }
|
||||
namespace appleseed { namespace studio { class RenderingManager; } }
|
||||
namespace appleseed { namespace studio { class RenderWidget; } }
|
||||
namespace renderer { class Entity; }
|
||||
namespace renderer { class Project; }
|
||||
namespace renderer { class RenderingManager; }
|
||||
class QComboBox;
|
||||
class QLabel;
|
||||
class QPoint;
|
||||
|
||||
@@ -45,6 +45,7 @@
|
||||
#include "renderer/kernel/rendering/nulltilecallback.h"
|
||||
#include "renderer/kernel/rendering/progressive/progressiveframerenderer.h"
|
||||
#include "renderer/kernel/rendering/renderercontrollercollection.h"
|
||||
#include "renderer/kernel/rendering/scenepicker.h"
|
||||
#include "renderer/kernel/rendering/tilecallbackbase.h"
|
||||
#include "renderer/kernel/rendering/tilecallbackcollection.h"
|
||||
#include "renderer/kernel/rendering/timedrenderercontroller.h"
|
||||
|
||||
Reference in New Issue
Block a user