New Geometry View, with new frame and new settings.

This commit is contained in:
brunoherbelin
2020-04-29 00:20:38 +02:00
parent 091eceefe5
commit 79e9b70fa2
19 changed files with 788 additions and 82 deletions

View File

@@ -4,20 +4,27 @@
#include "defines.h"
#include <string>
#include <list>
#include <vector>
namespace Settings {
struct Window
struct WindowConfig
{
std::string name;
int x,y,w,h;
bool fullscreen;
Window() : name(APP_TITLE), x(15), y(15), w(1280), h(720), fullscreen(false) { }
WindowConfig(std::string n) : name(n), x(15), y(15), w(1280), h(720), fullscreen(false) { }
};
struct ViewConfig
{
std::string name;
ViewConfig(std::string n) : name(n) { }
};
struct Application
{
@@ -31,8 +38,12 @@ struct Application
bool media_player;
bool shader_editor;
// Settings of Views
int current_view;
std::vector<ViewConfig> views;
// multiple windows handling
std::list<Window> windows;
std::vector<WindowConfig> windows;
Application() : name(APP_NAME){
scale = 1.f;
@@ -40,11 +51,13 @@ struct Application
preview = true;
media_player = false;
shader_editor = false;
windows.push_back(Window());
current_view = 1;
windows.push_back(WindowConfig(APP_TITLE));
}
};
// minimal implementation of settings
// Can be accessed r&w anywhere
extern Application application;