It is best to generate pictures in eps format, which is a vector diagram, and it is still very clear to enlarge at will. If you can't directly generate eps, you can use photoshop to process it and convert it into an eps format picture, and the effect will be better:
PS: PDF itself is a vector graphics format, and eps is very suitable for it: jok: