3D printing of composite materials