Setting the blur radius of a box shadow to a very high number causes crash

Describe the bug: Crayta crashes when setting the blur radius of a box shadow in the css of a widget, to a very high number.

I found this bug when creating a new, large widget that takes up most of the screen. I copied the box shadow code from a working, smaller widget where the blur radius of the box shadow is set to ‘2rem’, and then I added this code to the larger widget. Setting blur radius to ‘2rem’ works on the smaller widget but crashes Crayta when applied to my larger widget.

  • Small widget (width: 25vw, height: 75vh)
  • Large widget (width: 75vw, height: 75vh)

How do you cause this bug?

  • Create a widget and copy and paste the below code into the widget script
  • Then view the widget in game
  • The example below is a bit extreme but I just wanted to make sure others can experience the crash.
<html>
<head>
	<script type="text/javascript" src="coui://uiresources/js/crayta.js"></script>
	<default-asset-properties>
		<default-asset-property name="type" value="Screen"></default-asset-property>
		<default-asset-property name="visible" value="true"></default-asset-property>
	</default-asset-properties>
	<style type="text/css">
		#menu-container {
			position: absolute;
			width: 1px;
  		    height: 1px;
			background-color: rgba(255, 255, 255, .85); 
            /* offset-x | offset-y | blur-radius | color */
			box-shadow: 0 0rem 2000rem rgba(64, 64, 64, 0.75);
		}
	</style>
</head>
<body>
	<div id="menu-container"></div>
</body>
</html>

Screenshots / video of bug: The game crashes and the ‘Crayta Crash Reporter’ appears.

Last lines of the Crayta.log file:

LogCoherentRendering: Warning: Maximum blur size exceeded! Clamping to maximum radius: 94px. Requested: 16000 radius (approx. std dev 4915.14)
LogWindows: Windows GetLastError: The operation completed successfully. (0)
LogWindows: Error: Error: Assertion failed: MaxX <= (uint32)( 32767 ) [File:D:/open/jen/0/livehotfix/UE4/Engine/Source/Runtime/D3D12RHI/Private/D3D12Commands.cpp] [Line: 523] 

Which platform: PC
Which input: keyboard + mouse
Game seen in Editor
Version number: 0.g3.9.128732

Thank you for your help.

Hi @JakeMatthews96,

Thanks very much for the detailed report. I’ve passed this on to development to look into.

1 Like

Thank you :v: