Is it possible to use Texture2DArrays in a material?

I would like to know if there’s any way to use 2d texture arrays in a material and if so how to go about it.

I need to be able to use ~200 separate (small) textures all with the ability to wrap the coordinates which everything I’ve seen makes this either impossible to do with texture atlases or has other negative side effects.

I have not seen anything in the material editor that appears to support what I need but in looking through the engine documentation I did come across the FTexture2DArrayResource
link:(https://docs.unrealengine.com/latest/INT/API/Runtime/Engine/FTexture2DArrayResource/index.html) but I’m not sure if this has anything to do with what I’m looking for.

Any help would be greatly appreciated!

This is not supported natively, you can of course add Texture2DArray support to the material editor. I have done this in my own personal build as I required something similar. Have a look at how UMaterialExpressionTextureBase and UMaterialExpressionTextureSample and other such classes are setup to see how you would go about adding array support.

I had a feeling this was the case… I’m assuming you just added the nodes to the material editor and then bound the actual texture programatically instead of through the editor? I wonder how hard it would be to extend the editor (and whatever else is necessary) to support it all the way through… Thanks for the reply!