Skip to content

Commit

Permalink
Release v0.13.0
Browse files Browse the repository at this point in the history
  • Loading branch information
AchimStremplat committed Mar 7, 2022
1 parent fd8cb9d commit 3bc24c7
Show file tree
Hide file tree
Showing 241 changed files with 5,178 additions and 1,630 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@
[submodule "third_party/tinygltf"]
path = third_party/tinygltf
url = https://github.com/syoyo/tinygltf.git
[submodule "third_party/zip"]
path = third_party/zip
url = https://github.com/kuba--/zip
31 changes: 30 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,34 @@ If a copy of the MPL was not distributed with this file, You can obtain one at h
### Known Issues
-->

## [0.13.0] Compressed project files, cubemap extensions, log view
* **File version number has changed. Files saved with RaCo 0.13.0 cannot be opened by previous versions.**

### Added
* Added custom CubeMap mipmap support.
* Added optional automatic zipping of project files.
* With automatic zipping enabled, projects will be saved as ZIP archives that still use the .rca file extension and contain the project JSON file.
* This option can be enabled/disabled in the Project Settings (disabled by default).
* Added command line argument "--outlogfile" to headless Ramses Composer for changing the log file path.
* New log view allows observing Ramses Composer log output within the application.
* The ramses logic datatype INT64 is now supported.
* Added object duplication feature via context menu or shortcut.

### Changes
* Removed upper limit for glTF mesh TEXCOORD and COLOR attributes.
* Export dialog now displays Ramses Composer scene errors if any are present.
* Ramses Logic log output now appears in Ramses Composer log files.
* Ramses Composer now begins a new log file every time the application is launched.
* The "Field of View" property in the perspective camera has been renamed to "Vert. Field of View".

### Fixes
* Fixed dropping of links from external reference to project local objects when loading a project.
* Fixed crash when dragging around "Scene Id" property value.
* Fixed problem with saving preferences if the entered directory does not exist.
* Improved support for High DPI screens.
* Fixed losing the property values of PrefabInstance interface scripts when pasting PrefabInstances.


## [0.12.0] Bug Fixes and Usability Improvements
* **File version number has changed. Files saved with RaCo 0.12.0 cannot be opened by previous versions.**

Expand All @@ -35,8 +63,9 @@ If a copy of the MPL was not distributed with this file, You can obtain one at h
* A new filtering options menu for the ramses preview widget now allows changing from nearest neighbor sampling to linear sampling.
* Added a ramses-logic-viewer build to RaCo binary folder.
* It is now possible to do simple calculations (like "1920/1080" as aspect ratio) directly in the number inputs of the property browser.
* Currently allowed operations: addition (+), substraction (-), multiplication (*), division (/), integer division (//), modulo (%), exponentiation (^) and changing precedence using parentheses.
* Currently allowed operations: addition (+), substraction (-), multiplication (*), division (/), modulo (%), exponentiation (^) and changing precedence using parentheses.
* Results are calculated immediately and the mathematical expression is not stored.
* The property browser now indicates lua datatypes with tooltips on property labels and with a label in the link editor popup.

### Changes
* Update from ramses-logic 0.13.0 to ramses-logic 0.14.2
Expand Down
17 changes: 12 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ cmake_minimum_required(VERSION 3.19)

SET(CMAKE_CONFIGURATION_TYPES "Debug;RelWithDebInfo")

project(RaCoOS VERSION 0.12.0)
project(RaCoOS VERSION 0.13.0)

SET(RACO_RELEASE_DIRECTORY ${CMAKE_BINARY_DIR}/release)

Expand Down Expand Up @@ -87,10 +87,17 @@ macro(deploy_qt tgt)
# Also add the Qt licensing file and our licensing file.
# We are making use of the add_custom_command feature for build event commands that "COMMAND" statements with an empty COMMAND string are completely ignored.
add_custom_command(TARGET ${tgt} POST_BUILD
COMMAND "$<$<CONFIG:Debug>:${RACO_QT_WINDEPLOY_PATH}/windeployqt.exe>" --debug --no-libraries --no-opengl-sw --no-system-d3d-compiler --no-svg --no-translations --no-compiler-runtime "$<TARGET_FILE:${tgt}>"
COMMAND "${RACO_QT_WINDEPLOY_PATH}/windeployqt.exe" "$<$<CONFIG:Debug>:--no-plugins>" --no-opengl-sw --no-system-d3d-compiler --no-svg --no-translations --no-compiler-runtime "$<TARGET_FILE:${tgt}>"
# Qt deploys the folder imageformats which we do not need - createReadHandlerHelper in C:\Qt\5.15.2\Src\qtbase\src\gui\image\qimagereader.cpp contains hardcoded support for the extensions png, bmp, dib, xpm, xbm, pbm, pbmraw, pgm, pgmraw, ppm and ppmraw (which is more than we need).
COMMAND ${CMAKE_COMMAND} -E rm -fr "$<TARGET_FILE_DIR:${tgt}>/imageformats"
COMMAND "$<$<CONFIG:Debug>:${RACO_QT_WINDEPLOY_PATH}/windeployqt.exe>" --debug --no-libraries --no-opengl-sw --no-system-d3d-compiler --svg --no-translations --no-compiler-runtime "$<TARGET_FILE:${tgt}>"
COMMAND "${RACO_QT_WINDEPLOY_PATH}/windeployqt.exe" "$<$<CONFIG:Debug>:>" --no-opengl-sw --no-system-d3d-compiler --svg --no-translations --no-compiler-runtime "$<TARGET_FILE:${tgt}>"
# Qt deploys the folder imageformats which we do not need except for svg support - createReadHandlerHelper in C:\Qt\5.15.2\Src\qtbase\src\gui\image\qimagereader.cpp contains hardcoded support for the extensions png, bmp, dib, xpm, xbm, pbm, pbmraw, pgm, pgmraw, ppm and ppmraw (which is more than we need).
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qgifd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qgif.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qicnsd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qicns.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qicod.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qico.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qjpegd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qjpeg.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qtiffd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qtiff.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qtgad.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qtga.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qwbmpd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qwbmp.dll"
COMMAND ${CMAKE_COMMAND} -E rm -f "$<TARGET_FILE_DIR:${tgt}>/imageformats/qwebpd.dll" "$<TARGET_FILE_DIR:${tgt}>/imageformats/qwebp.dll"
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_SOURCE_DIR}/third_party/qtsharedlibs_license.txt" "$<TARGET_FILE_DIR:${tgt}>/qtsharedlibs_license.txt"
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_SOURCE_DIR}/LICENSE.txt" "$<TARGET_FILE_DIR:${tgt}>/LICENSE.txt"
)
Expand Down
13 changes: 9 additions & 4 deletions EditorApp/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,13 @@ int main(int argc, char *argv[]) {
QCoreApplication::setApplicationName("Ramses Composer");
QCoreApplication::setApplicationVersion(RACO_OSS_VERSION);

// Enable Qt's virtualized coordinate system, which makes qt pixel size different from physical pixel size depending on the scale factor set in the operating system.
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
// By default, Qt will round the scale factor to the closest integer in some contexts. Disable rounding, since it produces invalid font sizes for Windows 125%, 150%, 175% etc. scaling mode.
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
// Also, we need support for high resolution icons on scale factors greater than one.
QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);

// QDialogs will show a "?"-Button by default. While it is possible to disable this for every single dialog, we never need this and thus, disabling it globally is easier.
QApplication::setAttribute(Qt::AA_DisableWindowContextHelpButton);

Expand Down Expand Up @@ -83,10 +90,7 @@ int main(int argc, char *argv[]) {
// force use of style palette, required on Linux
a.setPalette(a.style()->standardPalette());

QStringList argList{};
for (int i{0}; i < argc; i++)
argList << argv[i];
parser.process(argList);
parser.process(QCoreApplication::arguments());

bool noDumpFiles = parser.isSet(noDumpFileCheckOption);
raco::utils::crashdump::installCrashDumpHandler(noDumpFiles);
Expand Down Expand Up @@ -140,5 +144,6 @@ int main(int argc, char *argv[]) {

MainWindow w{&app, &rendererBackend};
w.show();

return a.exec();
}
36 changes: 26 additions & 10 deletions EditorApp/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include "SavedLayoutsDialog.h"
#include "common_widgets/ErrorView.h"
#include "common_widgets/ExportDialog.h"
#include "common_widgets/LogView.h"
#include "common_widgets/MeshAssetImportDialog.h"
#include "common_widgets/PreferencesView.h"
#include "common_widgets/UndoView.h"
Expand All @@ -25,7 +26,7 @@
#include "core/PathManager.h"
#include "core/Project.h"
#include "core/Queries.h"
#include "data_storage/BasicTypes.h"
#include "core/BasicTypes.h"
#include "data_storage/Value.h"
#include "log_system/log.h"
#include "object_tree_view/ObjectTreeDock.h"
Expand Down Expand Up @@ -129,7 +130,7 @@ ads::CDockWidget* createDockWidget(const QString& title, QWidget* parent) {

ads::CDockAreaWidget* createAndAddPreview(MainWindow* mainWindow, const char* dockObjName, RaCoDockManager* dockManager, raco::ramses_widgets::RendererBackend& rendererBackend, raco::application::RaCoApplication* application) {
const auto& viewport = application->activeRaCoProject().project()->settings()->viewport_;
const auto& backgroundColor = application->activeRaCoProject().project()->settings()->backgroundColor_.asVec4f();
const auto& backgroundColor = *application->activeRaCoProject().project()->settings()->backgroundColor_;
auto* previewWidget = new raco::ramses_widgets::PreviewMainWindow{rendererBackend, application->sceneBackendImpl(), {*viewport->i1_, *viewport->i2_}, application->activeRaCoProject().project(), application->dataChangeDispatcher()};
QObject::connect(mainWindow, &MainWindow::viewportChanged, previewWidget, &raco::ramses_widgets::PreviewMainWindow::setViewport);
previewWidget->displayScene(application->sceneBackendImpl()->currentSceneId(), backgroundColor);
Expand Down Expand Up @@ -258,15 +259,23 @@ ads::CDockAreaWidget* createAndAddUndoView(raco::application::RaCoApplication* a
return dockManager->addDockWidget(ads::BottomDockWidgetArea, dock, dockArea);
}

ads::CDockAreaWidget* createAndAddErrorView(MainWindow* mainWindow, raco::application::RaCoApplication* application, const char* dockObjName, RaCoDockManager* dockManager, raco::object_tree::view::ObjectTreeDockManager& treeDockManager, ads::CDockAreaWidget* dockArea = nullptr) {
auto* errorView = new raco::common_widgets::ErrorView(application->activeRaCoProject().commandInterface(), application->dataChangeDispatcher());
ads::CDockAreaWidget* createAndAddErrorView(MainWindow* mainWindow, raco::application::RaCoApplication* application, const char* dockObjName, RaCoDockManager* dockManager, raco::object_tree::view::ObjectTreeDockManager& treeDockManager, raco::common_widgets::LogViewModel* logViewModel, ads::CDockAreaWidget* dockArea = nullptr) {
auto* errorView = new raco::common_widgets::ErrorView(application->activeRaCoProject().commandInterface(), application->dataChangeDispatcher(), true, logViewModel);
QObject::connect(errorView, &raco::common_widgets::ErrorView::objectSelectionRequested, &treeDockManager, &raco::object_tree::view::ObjectTreeDockManager::selectObjectAcrossAllTreeDocks);
auto* dock = createDockWidget(MainWindow::DockWidgetTypes::ERROR_VIEW, mainWindow);
dock->setWidget(errorView);
dock->setObjectName(dockObjName);
return dockManager->addDockWidget(ads::BottomDockWidgetArea, dock, dockArea);
}

ads::CDockAreaWidget* createAndAddLogView(MainWindow* mainWindow, raco::application::RaCoApplication* application, const char* dockObjName, RaCoDockManager* dockManager, raco::object_tree::view::ObjectTreeDockManager& treeDockManager, raco::common_widgets::LogViewModel* logViewModel, ads::CDockAreaWidget* dockArea = nullptr) {
auto* logView = new raco::common_widgets::LogView(logViewModel);
auto* dock = createDockWidget(MainWindow::DockWidgetTypes::LOG_VIEW, mainWindow);
dock->setWidget(logView);
dock->setObjectName(dockObjName);
return dockManager->addDockWidget(ads::BottomDockWidgetArea, dock, dockArea);
}

void createInitialWidgets(MainWindow* mainWindow, raco::ramses_widgets::RendererBackend& rendererBackend, raco::application::RaCoApplication* application, RaCoDockManager* dockManager, raco::object_tree::view::ObjectTreeDockManager& treeDockManager) {
createAndAddPreview(mainWindow, "defaultPreview", dockManager, rendererBackend, application);

Expand All @@ -283,8 +292,8 @@ void createInitialWidgets(MainWindow* mainWindow, raco::ramses_widgets::Renderer

MainWindow::MainWindow(raco::application::RaCoApplication* racoApplication, raco::ramses_widgets::RendererBackend* rendererBackend, QWidget* parent)
: QMainWindow(parent),
rendererBackend_{rendererBackend},
racoApplication_{racoApplication} {
rendererBackend_(rendererBackend),
racoApplication_(racoApplication) {
// Setup the UI from the QtCreator file mainwindow.ui
ui = new Ui::MainWindow();
ui->setupUi(this);
Expand All @@ -295,6 +304,8 @@ MainWindow::MainWindow(raco::application::RaCoApplication* racoApplication, raco
setWindowIcon(QIcon(":applicationLogo"));
resize(QGuiApplication::screenAt(this->pos())->size() * 0.85);

logViewModel_ = new raco::common_widgets::LogViewModel(this);

// Shortcuts
{

Expand Down Expand Up @@ -336,7 +347,7 @@ MainWindow::MainWindow(raco::application::RaCoApplication* racoApplication, raco
openProject();
});
QObject::connect(ui->actionExport, &QAction::triggered, this, [this]() {
auto dialog = new raco::common_widgets::ExportDialog(racoApplication_, this);
auto dialog = new raco::common_widgets::ExportDialog(racoApplication_, logViewModel_, this);
dialog->exec();
});
QObject::connect(ui->actionQuit, &QAction::triggered, this, &MainWindow::close);
Expand All @@ -357,7 +368,8 @@ MainWindow::MainWindow(raco::application::RaCoApplication* racoApplication, raco
QObject::connect(ui->actionNewResourcesTree, &QAction::triggered, [this]() { createAndAddResourceTree(this, EditorObject::normalizedObjectID("").c_str(), dockManager_, treeDockManager_, racoApplication_, nullptr); });
QObject::connect(ui->actionNewPrefabTree, &QAction::triggered, [this]() { createAndAddPrefabTree(this, EditorObject::normalizedObjectID("").c_str(), dockManager_, treeDockManager_, racoApplication_, nullptr); });
QObject::connect(ui->actionNewUndoView, &QAction::triggered, [this]() { createAndAddUndoView(racoApplication_, EditorObject::normalizedObjectID("").c_str(), &racoApplication_->activeRaCoProject(), this, dockManager_); });
QObject::connect(ui->actionNewErrorView, &QAction::triggered, [this]() { createAndAddErrorView(this, racoApplication_, EditorObject::normalizedObjectID("").c_str(), dockManager_, treeDockManager_); });
QObject::connect(ui->actionNewErrorView, &QAction::triggered, [this]() { createAndAddErrorView(this, racoApplication_, EditorObject::normalizedObjectID("").c_str(), dockManager_, treeDockManager_, logViewModel_); });
QObject::connect(ui->actionNewLogView, &QAction::triggered, [this]() { createAndAddLogView(this, racoApplication_, EditorObject::normalizedObjectID("").c_str(), dockManager_, treeDockManager_, logViewModel_); });
QObject::connect(ui->actionRestoreDefaultLayout, &QAction::triggered, [this](){
resetDockManager();
createInitialWidgets(this, *rendererBackend_, racoApplication_, dockManager_, treeDockManager_);
Expand Down Expand Up @@ -428,7 +440,7 @@ void MainWindow::timerEvent(QTimerEvent* event) {
racoApplication_->doOneLoop();

const auto& viewport = racoApplication_->activeRaCoProject().project()->settings()->viewport_;
const auto& backgroundColor = racoApplication_->activeRaCoProject().project()->settings()->backgroundColor_.asVec4f();
const auto& backgroundColor = *racoApplication_->activeRaCoProject().project()->settings()->backgroundColor_;

Q_EMIT viewportChanged({*viewport->i1_, *viewport->i2_});

Expand Down Expand Up @@ -498,6 +510,7 @@ void MainWindow::openProject(const QString& file) {
// Don't create a new DockManager right away - making QMessageBoxes pop up messes up state restoring
// (see https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System/issues/315)
delete dockManager_;
logViewModel_->clear();

try {
racoApplication_->switchActiveRaCoProject(file);
Expand Down Expand Up @@ -570,6 +583,7 @@ bool MainWindow::saveAsActiveProject() {
if (newPath.isEmpty()) {
return false;
}
if (!newPath.endsWith(".rca")) newPath += ".rca";
if (racoApplication_->activeRaCoProject().saveAs(newPath, setProjectName)) {
recentFileMenu_->addRecentFile(racoApplication_->activeProjectPath().c_str());

Expand Down Expand Up @@ -684,7 +698,9 @@ void MainWindow::regenerateLayoutDocks(const RaCoDockManager::LayoutDocks& docks
} else if (savedDockType == DockWidgetTypes::UNDO_STACK) {
createAndAddUndoView(racoApplication_, dockNameCString, &racoApplication_->activeRaCoProject(), this, dockManager_);
} else if (savedDockType == DockWidgetTypes::ERROR_VIEW) {
createAndAddErrorView(this, racoApplication_, dockNameCString, dockManager_, treeDockManager_);
createAndAddErrorView(this, racoApplication_, dockNameCString, dockManager_, treeDockManager_, logViewModel_);
} else if (savedDockType == DockWidgetTypes::LOG_VIEW) {
createAndAddLogView(this, racoApplication_, dockNameCString, dockManager_, treeDockManager_, logViewModel_);
} else {
assert(false && "Unknown Dock Type detected");
}
Expand Down
3 changes: 3 additions & 0 deletions EditorApp/mainwindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "common_widgets/TimingsWidget.h"
#include "object_tree_view/ObjectTreeDockManager.h"
#include "ramses_widgets/RendererBackend.h"
#include "common_widgets/log_model/LogViewModel.h"

#include <QListWidget>
#include <QMainWindow>
Expand Down Expand Up @@ -47,6 +48,7 @@ class MainWindow : public QMainWindow {
static inline const char* SCENE_GRAPH{"Scene Graph"};
static inline const char* UNDO_STACK{"Undo Stack"};
static inline const char* ERROR_VIEW{"Error View"};
static inline const char* LOG_VIEW{"Log View"};
};

explicit MainWindow(
Expand Down Expand Up @@ -95,6 +97,7 @@ protected Q_SLOTS:
raco::object_tree::view::ObjectTreeDockManager treeDockManager_;
raco::common_widgets::TimingsModel timingsModel_{this};
QMetaObject::Connection activeProjectFileConnection_;
raco::common_widgets::LogViewModel* logViewModel_;

int renderTimerId_ = 0;
};
6 changes: 6 additions & 0 deletions EditorApp/mainwindow.ui
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
<addaction name="actionNewProjectBrowser"/>
<addaction name="actionNewUndoView"/>
<addaction name="actionNewErrorView"/>
<addaction name="actionNewLogView"/>
<addaction name="separator"/>
<addaction name="menuLayouts"/>
<addaction name="separator"/>
Expand Down Expand Up @@ -227,6 +228,11 @@
<string>Save Current Layout...</string>
</property>
</action>
<action name="actionNewLogView">
<property name="text">
<string>New Log View</string>
</property>
</action>
</widget>
<layoutdefault spacing="6" margin="11"/>
<resources/>
Expand Down
Loading

0 comments on commit 3bc24c7

Please sign in to comment.