Description

This is a common crash occurring in the 4.16 release. It seems to be related to applying a material to a mesh that is being used in Foliage.

Crash Reports are spread out among many different CrashGroups. Here are a few:

  • [Link Removed]
  • [Link Removed]
  • [Link Removed]
  • [Link Removed]

User Descriptions

  • Too many foilage objects in scene, said objects proceeded to crash the engine when a texture was applied to the base model
    whoops
  • putting texture on a prop

Source Context

  916       void UObject::ConditionalPostLoad()
  917       {
  918       	check(!GEventDrivenLoaderEnabled || !HasAnyFlags(RF_NeedLoad)); //@todoio Added this as "nicks rule"
  919       									  // PostLoad only if the object needs it and has already been serialized
  920       	//@todoio note this logic should be unchanged compared to main
  921 ***** 	if (HasAnyFlags(RF_NeedPostLoad))
  922       	{
  923       
  924       		check(IsInGameThread() || HasAnyFlags(RF_ClassDefaultObject|RF_ArchetypeObject) || IsPostLoadThreadSafe() || IsA(UClass::StaticClass()))
Steps to Reproduce

New Repro

  1. Open QAGame in editor
  2. Change to foliage tab and add the Foliage-CullDistance and Shape_QuadPyramid_settings foliage types
  3. Paint in the viewport on the floor mesh
  4. Right click on Foliage-CullDistance in the foliage tab and replace with Shape_QuadPyramid_settings
  5. Open Shape_QuadPyramid in static mesh editor from the details section of the foliage tab
  6. Change material in slot 1

Result: crash

Freq: 4 for 4

Old Repro

  1. Open QAGame in editor
  2. Create a new landscape
  3. Change to foliage tab and add the TallGrass_01 foliage type
  4. Paint on the landscape
  5. Simulate
  6. Exit simulate
  7. Open Foliage_TallGrass in static mesh editor
  8. Change material in slot 1 to aluminum
  9. Repeat steps 4-8 using different materials

Result: crash

Freq: 2 out of 10

Callstack
Access violation - code c0000005 (first/second chance not available)

UE4Editor_CoreUObject!UObject::ConditionalPostLoad() [obj.cpp:922]
UE4Editor_Engine!UHierarchicalInstancedStaticMeshComponent::BuildTreeIfOutdated() [hierarchicalinstancedstaticmesh.cpp:2384]
UE4Editor_Foliage!TBaseRawMethodDelegateInstance<0,FFoliageMeshInfo,void __cdecl() [delegateinstancesimpl.h:648]
UE4Editor_Engine!TBaseMulticastDelegate<void,FBoxSphereBounds const & __ptr64>::Broadcast() [delegatesignatureimpl.inl:937]
UE4Editor_Engine!UStaticMesh::CalculateExtendedBounds() [staticmesh.cpp:2240]
UE4Editor_Engine!UStaticMesh::Build() [staticmeshbuild.cpp:169]
UE4Editor_Engine!UStaticMesh::PostEditChangeProperty() [staticmesh.cpp:1790]
UE4Editor_StaticMeshEditor!FMeshMaterialsLayout::CallPostEditChange() [staticmesheditortools.cpp:2543]
UE4Editor_StaticMeshEditor!FMeshMaterialsLayout::OnMaterialChanged() [staticmesheditortools.cpp:2093]
UE4Editor_StaticMeshEditor!TBaseSPMethodDelegateInstance<0,FMeshMaterialsLayout,0,TTypeWrapper<void> __cdecl() [delegateinstancesimpl.h:327]
UE4Editor_StaticMeshEditor!TBaseSPMethodDelegateInstance<0,FMeshMaterialsLayout,0,void __cdecl() [delegateinstancesimpl.h:434]
UE4Editor_PropertyEditor!TBaseDelegate<void,UMaterialInterface * __ptr64,UMaterialInterface * __ptr64,int,bool>::ExecuteIfBound() [delegatesignatureimpl.inl:624]
UE4Editor_PropertyEditor!FMaterialItemView::ReplaceMaterial() [propertycustomizationhelpers.cpp:829]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,FMaterialItemView,0,TTypeWrapper<void> __cdecl() [delegateinstancesimpl.h:327]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,FMaterialItemView,0,void __cdecl() [delegateinstancesimpl.h:434]
UE4Editor_PropertyEditor!SPropertyEditorAsset::SetValue() [spropertyeditorasset.cpp:610]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,SPropertyEditorAsset,0,TTypeWrapper<void> __cdecl() [delegateinstancesimpl.h:327]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,SPropertyEditorAsset,0,void __cdecl() [delegateinstancesimpl.h:434]
UE4Editor_PropertyEditor!SPropertyMenuAssetPicker::OnAssetSelected() [spropertymenuassetpicker.cpp:249]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,SPropertyMenuAssetPicker,0,TTypeWrapper<void> __cdecl() [delegateinstancesimpl.h:327]
UE4Editor_PropertyEditor!TBaseSPMethodDelegateInstance<0,SPropertyMenuAssetPicker,0,void __cdecl() [delegateinstancesimpl.h:434]
UE4Editor_ContentBrowser!SAssetView::AssetSelectionChanged() [sassetview.cpp:3620]
UE4Editor_ContentBrowser!TBaseSPMethodDelegateInstance<0,SAssetView,0,TTypeWrapper<void> __cdecl() [delegateinstancesimpl.h:327]
UE4Editor_ContentBrowser!TBaseSPMethodDelegateInstance<0,SAssetView,0,void __cdecl() [delegateinstancesimpl.h:434]
UE4Editor_ContentBrowser!TBaseDelegate<void,TSharedPtr<FAssetViewItem,0>,enum ESelectInfo::Type>::ExecuteIfBound() [delegatesignatureimpl.inl:624]
UE4Editor_ContentBrowser!SListView<TSharedPtr<FAssetViewItem,0> >::Private_SignalSelectionChanged() [slistview.h:735]
UE4Editor_ContentBrowser!STableRow<TSharedPtr<FAssetViewItem,0> >::OnMouseButtonUp() [stablerow.h:476]
UE4Editor_Slate!<lambda_8d0e9a1da76abd0a756a3a9d775f5ed1>::operator() [slateapplication.cpp:5049]
UE4Editor_Slate!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,<lambda_8d0e9a1da76abd0a756a3a9d775f5ed1> >() [slateapplication.cpp:239]
UE4Editor_Slate!FSlateApplication::RoutePointerUpEvent() [slateapplication.cpp:5038]
UE4Editor_Slate!FSlateApplication::ProcessMouseButtonUpEvent() [slateapplication.cpp:5515]
UE4Editor_Slate!FSlateApplication::OnMouseUp() [slateapplication.cpp:5495]
UE4Editor_Core!FWindowsApplication::ProcessDeferredMessage() [windowsapplication.cpp:1704]
UE4Editor_Core!FWindowsApplication::DeferMessage() [windowsapplication.cpp:2127]
UE4Editor_Core!FWindowsApplication::ProcessMessage() [windowsapplication.cpp:867]
UE4Editor_Core!FWindowsApplication::AppWndProc() [windowsapplication.cpp:714]
user32!UserCallWinProcCheckWow()
user32!DispatchMessageWorker()
UE4Editor_Core!FWindowsPlatformMisc::PumpMessages() [windowsplatformmisc.cpp:1009]
UE4Editor!FEngineLoop::Tick() [launchengineloop.cpp:3058]
UE4Editor!GuardedMain() [launch.cpp:166]
UE4Editor!GuardedMainWrapper() [launchwindows.cpp:134]
UE4Editor!WinMain() [launchwindows.cpp:210]
UE4Editor!__scrt_common_main_seh() [exe_common.inl:253]
kernel32!BaseThreadInitThunk()
ntdll!RtlUserThreadStart()

Have Comments or More Details?

There's no existing public thread on this issue, so head over toAnswerHub just mention UE-45854 in the post.

2
Login to Vote

Fixed
ComponentTools - Foliage
Affects Versions4.16
Target Fix4.19
Fix Commit3857933
Main Commit3990065
Release Commit3857933
CreatedJun 8, 2017
ResolvedJan 26, 2018
UpdatedApr 27, 2018