Reputation: 11
I have a lot of .dst
files. I have to convert all files into .jpg
. I tried with pyembroidery
module in python, but I don't know how to save the conversion file. Can anyone please help me.
Upvotes: 1
Views: 561
Reputation: 11
Using below method you can convert .dst into png format files. You can also read .dst/.jpg/.pes files by using their commands. Recently, I developed simple application that can convert multiple embroidery files into images and save in particular folder.
import pyembroidery
filepath=r'C://Users//Desktop//file.DST'
pattern=pyembroidery.read_dst(filepath)
var=pyembroidery.write_png(pattern, 'C://Users//Desktop//filename.jpg')
print(pattern)
print(var)
Upvotes: 1
Reputation: 3
Image
module from PIL the os
module.Image.open()
method.os.path.getsize()
method.Image.convert()
method. Pass "RGB" as the parameter.Image.save()
method.os.path.getsize()
method.Upvotes: 0