Description

Crash at runtime when Retainerbox scale is set to 0.

The call stack indicates that the size of RenderTarget2D is set to 0. Attached repro project sets the scale of the RetainerBox that wraps the Image to 0 in the constructor.

A workaround is to change the following log verbosity.

UE_LOG(LogUMG, Error, TEXT("The requested size for SRetainerWidget is 0. W:%i H:%i"), RenderTargetWidth, RenderTargetHeight);

This will cause crashes even with relative changes, such as changing the scale of the panel that wraps the Retainerbox. It did not occur crash in 4.25. 

Steps to Reproduce
  1. Open attached project in editor.
  2. Play in editor, then occur crash.
Callstack
Assertion failed: InSizeX > 0 && InSizeY > 0 [File:/Engine/Source/Runtime/Engine/Private/TextureRenderTarget2D.cpp] [Line: 87]UE4Editor_Core!AssertFailedImplV() [/Engine/Source/Runtime/Core/Private/Misc/AssertionMacros.cpp:102] UE4Editor_Core!FDebug::CheckVerifyFailedImpl() [/Engine/Source/Runtime/Core/Private/Misc/AssertionMacros.cpp:458] UE4Editor_Engine!UTextureRenderTarget2D::InitCustomFormat() [/Engine/Source/Runtime/Engine/Private/TextureRenderTarget2D.cpp:87] UE4Editor_UMG!SRetainerWidget::PaintRetainedContentImpl() [/Engine/Source/Runtime/UMG/Private/Slate/SRetainerWidget.cpp:456] UE4Editor_UMG!SRetainerWidget::OnPaint() [/Engine/Source/Runtime/UMG/Private/Slate/SRetainerWidget.cpp:519] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_Slate!SConstraintCanvas::OnPaint() [/Engine/Source/Runtime/Slate/Private/Widgets/Layout/SConstraintCanvas.cpp:226] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SCompoundWidget::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SCompoundWidget.cpp:35] UE4Editor_UMG!SObjectWidget::OnPaint() [/Engine/Source/Runtime/UMG/Private/Slate/SObjectWidget.cpp:123] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_Slate!SConstraintCanvas::OnPaint() [/Engine/Source/Runtime/Slate/Private/Widgets/Layout/SConstraintCanvas.cpp:226] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SOverlay::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SOverlay.cpp:95] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SOverlay::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SOverlay.cpp:95] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SPanel::PaintArrangedChildren() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:31] UE4Editor_SlateCore!SPanel::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:12] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SPanel::PaintArrangedChildren() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:31] UE4Editor_SlateCore!SPanel::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:12] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SCompoundWidget::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SCompoundWidget.cpp:35] UE4Editor_Engine!SGameLayerManager::OnPaint() [/Engine/Source/Runtime/Engine/Private/Slate/SGameLayerManager.cpp:292] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SCompoundWidget::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SCompoundWidget.cpp:35] UE4Editor_Slate!SViewport::OnPaint() [/Engine/Source/Runtime/Slate/Private/Widgets/SViewport.cpp:145] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SCompoundWidget::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SCompoundWidget.cpp:35] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SPanel::PaintArrangedChildren() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:31] UE4Editor_SlateCore!SPanel::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:12] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SPanel::PaintArrangedChildren() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:31] UE4Editor_SlateCore!SPanel::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SPanel.cpp:12] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SOverlay::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SOverlay.cpp:95] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SCompoundWidget::OnPaint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SCompoundWidget.cpp:35] UE4Editor_SlateCore!SWidget::Paint() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWidget.cpp:1390] UE4Editor_SlateCore!SWindow::PaintSlowPath() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWindow.cpp:2058] UE4Editor_SlateCore!FSlateInvalidationRoot::PaintInvalidationRoot() [/Engine/Source/Runtime/SlateCore/Private/FastUpdate/SlateInvalidationRoot.cpp:240] UE4Editor_SlateCore!SWindow::PaintWindow() [/Engine/Source/Runtime/SlateCore/Private/Widgets/SWindow.cpp:2090] UE4Editor_Slate!FSlateApplication::DrawWindowAndChildren() [/Engine/Source/Runtime/Slate/Private/Framework/Application/SlateApplication.cpp:1056] UE4Editor_Slate!FSlateApplication::PrivateDrawWindows() [/Engine/Source/Runtime/Slate/Private/Framework/Application/SlateApplication.cpp:1279] UE4Editor_Slate!FSlateApplication::DrawWindows() [/Engine/Source/Runtime/Slate/Private/Framework/Application/SlateApplication.cpp:1017] UE4Editor_Slate!FSlateApplication::TickAndDrawWidgets() [/Engine/Source/Runtime/Slate/Private/Framework/Application/SlateApplication.cpp:1569] UE4Editor_Slate!FSlateApplication::Tick() [/Engine/Source/Runtime/Slate/Private/Framework/Application/SlateApplication.cpp:1423] UE4Editor!FEngineLoop::Tick() [/Engine/Source/Runtime/Launch/Private/LaunchEngineLoop.cpp:4946] UE4Editor!GuardedMain() [/Engine/Source/Runtime/Launch/Private/Launch.cpp:169] UE4Editor!GuardedMainWrapper() [/Engine/Source/Runtime/Launch/Private/Windows/LaunchWindows.cpp:137] UE4Editor!WinMain() [/Engine/Source/Runtime/Launch/Private/Windows/LaunchWindows.cpp:268] UE4Editor!__scrt_common_main_seh() [d:/agent/_work/5/s/src/vctools/crt/vcstartup/src/startup/exe_common.inl:288] kernel32 ntdll

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-106980 in the post.

0
Login to Vote

Fixed
ComponentUE - Editor - UI Systems
Affects Versions4.26
Target Fix4.26.1
Fix Commit14935948
Release Commit14935948
CreatedJan 22, 2021
ResolvedJan 25, 2021
UpdatedApr 27, 2021
View Jira Issue