How does a custom node in a material output a texture?

You can sampling it in custom node.