MCPcopy Create free account
hub / github.com/baldurk/renderdoc / OnCaptureLoaded

Method OnCaptureLoaded

qrenderdoc/Windows/TextureViewer.cpp:2923–2965  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2921}
2922
2923void TextureViewer::OnCaptureLoaded()
2924{
2925 Reset();
2926
2927 WindowingData renderData = ui->render->GetWidgetWindowingData();
2928 WindowingData contextData = ui->pixelContext->GetWidgetWindowingData();
2929
2930 ui->saveTex->setEnabled(true);
2931 ui->locationGoto->setEnabled(true);
2932 ui->viewTexBuffer->setEnabled(true);
2933
2934 ui->pixelHistory->setEnabled(false);
2935 ui->pixelHistory->setToolTip(QString());
2936
2937 ui->debugPixelContext->setEnabled(false);
2938 ui->pixelHistory->setToolTip(QString());
2939
2940 m_TexDisplay.backgroundColor =
2941 backCol.isValid() ? FloatVector(backCol.redF(), backCol.greenF(), backCol.blueF(), 1.0f)
2942 : FloatVector();
2943
2944 m_Ctx.Replay().BlockInvoke([renderData, contextData, this](IReplayController *r) {
2945 m_Output = r->CreateOutput(renderData, ReplayOutputType::Texture);
2946
2947 m_Output->SetPixelContext(contextData);
2948
2949 ui->render->SetOutput(m_Output);
2950 ui->pixelContext->SetOutput(m_Output);
2951
2952 RT_UpdateAndDisplay(r);
2953
2954 GUIInvoke::call(this, [this]() { OnEventChanged(m_Ctx.CurEvent()); });
2955 });
2956
2957 m_Watcher = new QFileSystemWatcher({ConfigFilePath(QString())}, this);
2958
2959 QObject::connect(m_Watcher, &QFileSystemWatcher::fileChanged, this,
2960 &TextureViewer::customShaderModified);
2961 QObject::connect(m_Watcher, &QFileSystemWatcher::directoryChanged, this,
2962 &TextureViewer::customShaderModified);
2963
2964 m_NeedCustomReload = true;
2965}
2966
2967void TextureViewer::Reset()
2968{

Callers

nothing calls this directly

Calls 13

connectFunction · 0.85
BlockInvokeMethod · 0.80
CreateOutputMethod · 0.80
SetPixelContextMethod · 0.80
ResetFunction · 0.50
QStringFunction · 0.50
FloatVectorClass · 0.50
ConfigFilePathFunction · 0.50
setToolTipMethod · 0.45
isValidMethod · 0.45
SetOutputMethod · 0.45

Tested by

no test coverage detected