[Bug-Report] Bink Media Broken in 5.6

For anyone who’s building the Engine from source, this appears to be fixable for the time being by specifying ETextureCreateFlags::UAV where the RHI Texture Creation Description is setup – which can be found under Engine\Plugins\BinkMedia\Source\BinkMediaPlayer\Private\Assets\BinkMediaTextureResource.cpp in FBinkMediaTextureResource::InitRHI on L44.

Currently:

const FRHITextureCreateDesc Desc =
		FRHITextureCreateDesc::Create2D(DebugName)
		.SetExtent(w, h)
		.SetFormat(PixelFormat)
		.SetFlags(TexCreateFlags | ETextureCreateFlags::RenderTargetable | ETextureCreateFlags::ShaderResource)
		.SetInitialState(ERHIAccess::SRVMask);

You can either set the UAV mask for TexCreateFlags prior to the construction of the FRHITextureCreateDesc or add it onto the SetFlags call after it’s been constructed along with the other flags being included there.

E.g.,:

const FRHITextureCreateDesc Desc =
		FRHITextureCreateDesc::Create2D(DebugName)
		.SetExtent(w, h)
		.SetFormat(PixelFormat)
		.SetFlags(TexCreateFlags | ETextureCreateFlags::RenderTargetable | ETextureCreateFlags::ShaderResource | ETextureCreateFlags::UAV)
		.SetInitialState(ERHIAccess::SRVMask);

There’s another thread with the same thing here:

Fix BinkMediaTextureResource command list crash on UE 5.6 - Development / Rendering - Epic Developer Community Forums

I’ve tested this on UE5.6 in the Editor and have also confirmed that the Bink Media Texture is working as expected when used for a material assigned to a cube in a packaged build after applying this Engine change. NOTE: I’ve only tested this with DX12.