In order to create an embroidery design (such as the .pec file for Brother stitching machines), you need to use a special embroidery software with a digitizing function, i.e. a function that allows users to create vector based designs from bitmap pictures, for example BuzzWord.
Usually requires manual tweaking and also experience with embroidery design, because the digitizing function alone is not perfect.