Coating by casting molten material on the substrate