mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-08 07:41:12 +00:00
Add a viewer of the diagnostic log in the UI itself
This commit is contained in:
@@ -46,6 +46,7 @@
|
||||
#include "Windows/Dialogs/LiveCapture.h"
|
||||
#include "Windows/Dialogs/SettingsDialog.h"
|
||||
#include "Windows/EventBrowser.h"
|
||||
#include "Windows/LogView.h"
|
||||
#include "Windows/MainWindow.h"
|
||||
#include "Windows/PerformanceCounterViewer.h"
|
||||
#include "Windows/PipelineState/PipelineStateViewer.h"
|
||||
@@ -1896,6 +1897,18 @@ IDebugMessageView *CaptureContext::GetDebugMessageView()
|
||||
return m_DebugMessageView;
|
||||
}
|
||||
|
||||
IDiagnosticLogView *CaptureContext::GetDiagnosticLogView()
|
||||
{
|
||||
if(m_DiagnosticLogView)
|
||||
return m_DiagnosticLogView;
|
||||
|
||||
m_DiagnosticLogView = new LogView(*this, m_MainWindow);
|
||||
m_DiagnosticLogView->setObjectName(lit("diagnosticLogView"));
|
||||
setupDockWindow(m_DiagnosticLogView);
|
||||
|
||||
return m_DiagnosticLogView;
|
||||
}
|
||||
|
||||
ICommentView *CaptureContext::GetCommentView()
|
||||
{
|
||||
if(m_CommentView)
|
||||
@@ -2003,6 +2016,11 @@ void CaptureContext::ShowDebugMessageView()
|
||||
m_MainWindow->showDebugMessageView();
|
||||
}
|
||||
|
||||
void CaptureContext::ShowDiagnosticLogView()
|
||||
{
|
||||
m_MainWindow->showDiagnosticLogView();
|
||||
}
|
||||
|
||||
void CaptureContext::ShowCommentView()
|
||||
{
|
||||
m_MainWindow->showCommentView();
|
||||
@@ -2122,6 +2140,10 @@ QWidget *CaptureContext::CreateBuiltinWindow(const rdcstr &objectName)
|
||||
{
|
||||
return GetDebugMessageView()->Widget();
|
||||
}
|
||||
else if(objectName == "diagnosticLogView")
|
||||
{
|
||||
return GetDiagnosticLogView()->Widget();
|
||||
}
|
||||
else if(objectName == "commentView")
|
||||
{
|
||||
return GetCommentView()->Widget();
|
||||
@@ -2166,6 +2188,8 @@ void CaptureContext::BuiltinWindowClosed(QWidget *window)
|
||||
m_MeshPreview = NULL;
|
||||
else if(m_DebugMessageView && m_DebugMessageView->Widget() == window)
|
||||
m_DebugMessageView = NULL;
|
||||
else if(m_DiagnosticLogView && m_DiagnosticLogView->Widget() == window)
|
||||
m_DiagnosticLogView = NULL;
|
||||
else if(m_CommentView && m_CommentView->Widget() == window)
|
||||
m_CommentView = NULL;
|
||||
else if(m_StatisticsViewer && m_StatisticsViewer->Widget() == window)
|
||||
|
||||
Reference in New Issue
Block a user