Download

Sampled tex inside custom node not working with tesselation

So when I sample a texture inside the custom node:
image = Texture2DSample(Tex, TexSampler, UV);

And when I return it:
return float(image.r);

And try to plug it into my tessalation for my heightmap, I get these errors:
[SM5] /Engine/Private/FlatTessellation.ush(133,2-33): warning X3554: unknown attribute partitioning, or attribute invalid for this statement, valid attributes are: domain
[SM5] /Engine/Private/FlatTessellation.ush(133,34-64): warning X3554: unknown attribute outputtopology, or attribute invalid for this statement, valid attributes are: domain
[SM5] /Engine/Private/FlatTessellation.ush(144,3): warning X3578: Output value ‘MainDomain’ is not completely initialized
[SM5] /Engine/Private/Common.ush(84,9-31): error X4532: cannot map expression to ds_5_0 instruction set

Does any of you know why this problem occurs and how to fix it?