mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-12 21:10:42 +00:00
Add skeleton qrenderdoc (just a qt template) & include in linux build
* Building qrenderdoc on windows will be supported just because that's likely where I will be developing it mostly, but for the foreseeable future it won't be built by default. If it ever gets good enough to replace the .NET UI, then we can look at it again.
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include "mainwindow.h"
|
||||
#include <QApplication>
|
||||
|
||||
#include "renderdoc_replay.h"
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
RENDERDOC_LogText("QRenderDoc initialising.");
|
||||
|
||||
QApplication a(argc, argv);
|
||||
MainWindow w;
|
||||
w.show();
|
||||
|
||||
return a.exec();
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
#include "mainwindow.h"
|
||||
#include "ui_mainwindow.h"
|
||||
|
||||
MainWindow::MainWindow(QWidget *parent) :
|
||||
QMainWindow(parent),
|
||||
ui(new Ui::MainWindow)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
}
|
||||
|
||||
MainWindow::~MainWindow()
|
||||
{
|
||||
delete ui;
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
#ifndef MAINWINDOW_H
|
||||
#define MAINWINDOW_H
|
||||
|
||||
#include <QMainWindow>
|
||||
|
||||
namespace Ui {
|
||||
class MainWindow;
|
||||
}
|
||||
|
||||
class MainWindow : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit MainWindow(QWidget *parent = 0);
|
||||
~MainWindow();
|
||||
|
||||
private:
|
||||
Ui::MainWindow *ui;
|
||||
};
|
||||
|
||||
#endif // MAINWINDOW_H
|
||||
@@ -0,0 +1,24 @@
|
||||
<ui version="4.0">
|
||||
<class>MainWindow</class>
|
||||
<widget class="QMainWindow" name="MainWindow" >
|
||||
<property name="geometry" >
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>400</width>
|
||||
<height>300</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle" >
|
||||
<string>MainWindow</string>
|
||||
</property>
|
||||
<widget class="QMenuBar" name="menuBar" />
|
||||
<widget class="QToolBar" name="mainToolBar" />
|
||||
<widget class="QWidget" name="centralWidget" />
|
||||
<widget class="QStatusBar" name="statusBar" />
|
||||
</widget>
|
||||
<layoutDefault spacing="6" margin="11" />
|
||||
<pixmapfunction></pixmapfunction>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
||||
@@ -0,0 +1,51 @@
|
||||
#-------------------------------------------------
|
||||
#
|
||||
# Project created by QtCreator 2015-03-18T20:10:50
|
||||
#
|
||||
#-------------------------------------------------
|
||||
|
||||
QT += core gui
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
||||
|
||||
TARGET = qrenderdoc
|
||||
TEMPLATE = app
|
||||
|
||||
# Temp files into .obj
|
||||
MOC_DIR = .obj
|
||||
UI_DIR = .obj
|
||||
OBJECTS_DIR = .obj
|
||||
|
||||
# include path for core renderdoc API
|
||||
INCLUDEPATH += $$_PRO_FILE_PWD_/../renderdoc/api/replay
|
||||
|
||||
# Different output folders per platform
|
||||
win32 {
|
||||
|
||||
!contains(QMAKE_TARGET.arch, x86_64) {
|
||||
Debug:DESTDIR = $$_PRO_FILE_PWD_/../Win32/Profile
|
||||
Release:DESTDIR = $$_PRO_FILE_PWD_/../Win32/Release
|
||||
|
||||
} else {
|
||||
Debug:DESTDIR = $$_PRO_FILE_PWD_/../x64/Profile
|
||||
Release:DESTDIR = $$_PRO_FILE_PWD_/../x64/Release
|
||||
}
|
||||
|
||||
# Link against the core library
|
||||
LIBS += $$DESTDIR/renderdoc.lib
|
||||
|
||||
} else {
|
||||
|
||||
DESTDIR = $$_PRO_FILE_PWD_/../bin
|
||||
|
||||
# Link against the core library
|
||||
LIBS += -L$$_PRO_FILE_PWD_/../renderdoc -lrenderdoc
|
||||
|
||||
}
|
||||
|
||||
SOURCES += main.cpp\
|
||||
mainwindow.cpp
|
||||
|
||||
HEADERS += mainwindow.h
|
||||
|
||||
FORMS += mainwindow.ui
|
||||
Reference in New Issue
Block a user