Navigation
API > API/Editor > API/Editor/UnrealEd
Utility class for keeping track of, rendering, and recycling thumbnails rendered in Slate
| Name | FAssetThumbnailPool |
| Type | class |
| Header File | /Engine/Source/Editor/UnrealEd/Public/AssetThumbnail.h |
| Include Path | #include "AssetThumbnail.h" |
Syntax
class FAssetThumbnailPool : public FTickableEditorObject
Inheritance Hierarchy
- FTickableObjectBase → FTickableEditorObject → FAssetThumbnailPool
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FAssetThumbnailPool
(
uint32 InNumInPool, |
Constructor | AssetThumbnail.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
~FAssetThumbnailPool() |
Destructor to free all remaining resources | AssetThumbnail.h |
Classes
| Name | Remarks |
|---|---|
| FThumbnailRendered | Register/Unregister a callback for when thumbnails are rendered |
| FThumbnailRenderFailed | Register/Unregister a callback for when thumbnails fail to render |
Structs
| Name | Remarks |
|---|---|
| FThumbId | Key for looking up thumbnails in a map |
| FThumbnailInfo | Information about a thumbnail |
| FThumbnailInfo_RenderThread |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| CustomThumbnailTagName | FName | AssetThumbnail.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AreRealTimeThumbnailsAllowed | TAttribute< bool > | Attribute that determines if real-time thumbnails are allowed. Called every frame. | AssetThumbnail.h | |
| bWereShadersCompilingLastFrame | bool | Shaders are still building | AssetThumbnail.h | |
| FreeThumbnails | TArray< TSharedRef< FThumbnailInfo > > | List of free thumbnails that can be reused | AssetThumbnail.h | |
| MaxFrameTimeAllowance | double | Max number of seconds per tick to spend rendering thumbnails | AssetThumbnail.h | |
| MaxRealTimeThumbnailsPerFrame | uint32 | Max number of dynamic thumbnails to update per frame | AssetThumbnail.h | |
| NumInPool | uint32 | Max number of thumbnails in the pool | AssetThumbnail.h | |
| RealTimeThumbnails | TArray< TSharedRef< FThumbnailInfo > > | List of thumbnails that can be rendered in real-time | AssetThumbnail.h | |
| RealTimeThumbnailsToRender | TArray< TSharedRef< FThumbnailInfo > > | List of real-time thumbnails that are queued to be rendered | AssetThumbnail.h | |
| RecentlyLoadedAssets | TArray< FSoftObjectPath > | A list of object paths for recently loaded assets whose thumbnails need to be refreshed. | AssetThumbnail.h | |
| RefCountMap | TMap< FThumbId, int32 > | A mapping of objects to the number of referencers | AssetThumbnail.h | |
| ThumbnailRenderedEvent | FThumbnailRendered | The delegate to execute when a thumbnail is rendered | AssetThumbnail.h | |
| ThumbnailRenderFailedEvent | FThumbnailRenderFailed | The delegate to execute when a thumbnail failed to render | AssetThumbnail.h | |
| ThumbnailsToRenderStack | TArray< TSharedRef< FThumbnailInfo > > | List of thumbnails to render when possible | AssetThumbnail.h | |
| ThumbnailToTextureMap | TMap< FThumbId, TSharedRef< FThumbnailInfo > > | A mapping of objects to their thumbnails | AssetThumbnail.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FSlateTexture2DRHIRef * AccessTexture
(
const FAssetData& AssetData, |
Accesses the texture for an object. | AssetThumbnail.h | |
void AddReferencer
(
const FAssetThumbnail& AssetThumbnail |
Adds a referencer to keep textures around as long as they are needed | AssetThumbnail.h | |
bool IsInRenderStack
(
const TSharedPtr< FAssetThumbnail >& Thumbnail |
Returns true if the thumbnail for the specified asset in the specified size is in the stack of thumbnails to render | AssetThumbnail.h | |
bool IsRendered
(
const TSharedPtr< FAssetThumbnail >& Thumbnail |
Returns true if the thumbnail for the specified asset in the specified size has been rendered | AssetThumbnail.h | |
FThumbnailRendered & OnThumbnailRendered() |
AssetThumbnail.h | ||
FThumbnailRenderFailed & OnThumbnailRenderFailed() |
AssetThumbnail.h | ||
void PrioritizeThumbnails
(
const TArray< TSharedPtr< FAssetThumbnail > >& ThumbnailsToPrioritize, |
Brings all items in ThumbnailsToPrioritize to the front of the render stack if they are actually in the stack | AssetThumbnail.h | |
void RefreshThumbnail
(
const TSharedPtr< FAssetThumbnail >& ThumbnailToRefresh |
Re-renders the specified thumbnail | AssetThumbnail.h | |
void RemoveReferencer
(
const FAssetThumbnail& AssetThumbnail |
Removes a referencer to clean up textures that are no longer needed | AssetThumbnail.h | |
void SetRealTimeThumbnail
(
const TSharedPtr< FAssetThumbnail >& Thumbnail, |
Enables/disables realtime thumbnail behavior | AssetThumbnail.h |
Overridden from FTickableObjectBase
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual TStatId GetStatId() |
AssetThumbnail.h | ||
virtual bool IsTickable() |
Checks if any new thumbnails are queued | AssetThumbnail.h | |
virtual void Tick
(
float DeltaTime |
Ticks the pool, rendering new thumbnails as needed | AssetThumbnail.h |