mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-04-24 04:58:59 -05:00
Merged master into NewAtmosphere.
This commit is contained in:
@@ -33,6 +33,7 @@
|
||||
#include <openspace/interaction/navigationhandler.h>
|
||||
#include <openspace/interaction/luaconsole.h>
|
||||
#include <openspace/network/parallelconnection.h>
|
||||
#include <openspace/rendering/dashboard.h>
|
||||
#include <openspace/rendering/renderengine.h>
|
||||
#include <openspace/rendering/screenspacerenderable.h>
|
||||
#include <openspace/scene/scene.h>
|
||||
@@ -68,7 +69,8 @@ ImGUIModule::ImGUIModule() : OpenSpaceModule(Name) {
|
||||
&(OsEng.navigationHandler()),
|
||||
&(OsEng.renderEngine()),
|
||||
&(OsEng.parallelConnection()),
|
||||
&(OsEng.console())
|
||||
&(OsEng.console()),
|
||||
&(OsEng.dashboard())
|
||||
};
|
||||
return res;
|
||||
}
|
||||
|
||||
@@ -529,8 +529,8 @@ void GUI::deinitialize() {
|
||||
void GUI::initializeGL() {
|
||||
_program = ghoul::opengl::ProgramObject::Build(
|
||||
"GUI",
|
||||
"${MODULE_IMGUI}/shaders/gui_vs.glsl",
|
||||
"${MODULE_IMGUI}/shaders/gui_fs.glsl"
|
||||
absPath("${MODULE_IMGUI}/shaders/gui_vs.glsl"),
|
||||
absPath("${MODULE_IMGUI}/shaders/gui_fs.glsl")
|
||||
);
|
||||
if (!_program) {
|
||||
return;
|
||||
@@ -812,7 +812,7 @@ void GUI::render() {
|
||||
ImGui::SetNextWindowCollapsed(_isCollapsed);
|
||||
|
||||
ImGui::Begin("OpenSpace GUI", nullptr);
|
||||
|
||||
|
||||
_isCollapsed = ImGui::IsWindowCollapsed();
|
||||
|
||||
bool property = _property.isEnabled();
|
||||
@@ -893,7 +893,7 @@ void GUI::render() {
|
||||
addScreenSpaceRenderableOnline(std::string(addImageOnlineBuffer));
|
||||
}
|
||||
|
||||
bool addDashboard = ImGui::Button("Add Dashboard");
|
||||
bool addDashboard = ImGui::Button("Add New Dashboard");
|
||||
if (addDashboard) {
|
||||
OsEng.scriptEngine().queueScript(
|
||||
"openspace.addScreenSpaceRenderable({ Type = 'ScreenSpaceDashboard' });",
|
||||
@@ -901,6 +901,16 @@ void GUI::render() {
|
||||
);
|
||||
}
|
||||
|
||||
bool addDashboardCopy = ImGui::Button("Add Copy of Main Dashboard");
|
||||
if (addDashboardCopy) {
|
||||
OsEng.scriptEngine().queueScript(
|
||||
"openspace.addScreenSpaceRenderable({ "
|
||||
"Type = 'ScreenSpaceDashboard', UseMainDashboard = true "
|
||||
"});",
|
||||
openspace::scripting::ScriptEngine::RemoteScripting::Yes
|
||||
);
|
||||
}
|
||||
|
||||
ImGui::Checkbox("ImGUI Internals", &_showInternals);
|
||||
if (_showInternals) {
|
||||
ImGui::Begin("Style Editor");
|
||||
|
||||
@@ -36,7 +36,7 @@ GuiFilePathComponent::GuiFilePathComponent()
|
||||
|
||||
void GuiFilePathComponent::render() {
|
||||
ImGui::SetNextWindowCollapsed(_isCollapsed);
|
||||
|
||||
|
||||
bool v = _isEnabled;
|
||||
ImGui::Begin("File Path", &v);
|
||||
_isCollapsed = ImGui::IsWindowCollapsed();
|
||||
|
||||
@@ -55,7 +55,7 @@ void GuiIswaComponent::render() {
|
||||
bool oldIonDataValue = _ionData;
|
||||
|
||||
ImGui::SetNextWindowCollapsed(_isCollapsed);
|
||||
|
||||
|
||||
bool e = _isEnabled;
|
||||
ImGui::Begin("ISWA", &e, WindowSize, 0.5f);
|
||||
_isEnabled = e;
|
||||
|
||||
@@ -102,7 +102,7 @@ void GuiMissionComponent::render() {
|
||||
bool v = _isEnabled;
|
||||
ImGui::Begin(name().c_str(), &v, Size, 0.75f);
|
||||
_isEnabled = v;
|
||||
|
||||
|
||||
_isCollapsed = ImGui::IsWindowCollapsed();
|
||||
|
||||
ghoul_assert(
|
||||
|
||||
@@ -297,7 +297,7 @@ void renderStringListProperty(Property* prop, const std::string& ownerName,
|
||||
}
|
||||
}
|
||||
script += "}";
|
||||
|
||||
|
||||
executeScript(
|
||||
p->fullyQualifiedIdentifier(),
|
||||
std::move(script),
|
||||
|
||||
Reference in New Issue
Block a user