How can I programmatically access the contents of a Render Target?

This is very similar to a previous question, but they are not the same.

I am looking for assistance in finding the documentation for the TextureRenderTarget2D class so that I can access its buffer (i.e pixels) programatically. So far I have been unable to find a reference to the class on either the GitHub or the API documentation and would greatly appreciate a push in the right direction.

Bingo, thanks for the heads up!

You can call GameThread_GetRenderTargetResource() to get the underlying FTextureRenderTargetResource object. Then you can use the RHILockTexture2D to get a pointer to the data. There are plenty of examples of that pattern in the source.

btw, the class in question is UTextureRenderTarget2D and is in TextureRenderTarget2D.h

I know this thread si failry old, but do you have any code on how to access the pixels of a specified Render Target?