60002154 Control the quality of the JPG exported images

Article 60002154
Type Wish
Product Engine
Version 6027
Date Added 2/21/2014 12:00:00 AM
Fixed (2/21/2014 12:00:00 AM)
Submitted by Chandana Kaza


Is there a way to control the Quality of the JPEG export images ?


In version 6028 a new property of vdDocument object named ImageSaveJPGQuality is exported. Its default value is 75 and the valid value range is 0 to 100.
     0     means lower quality (and the smaller file size)
     100 means hightest quality (and the bigger file size).

This property is used when a JPG is beeing export using SaveAs, ExportToFile and also when using the vdPrint object to export the drawing to JPG format (see article 60000271)

This property is also available in the VDF Wrapper (Activex vdraw.ocx) control, like :

Private Sub Export_Image()
Dim doc As VectorDraw_Professional.vdDocument

   VDraw1.ActiveDocument.Open "c:\test\test.vdcl"
   Set doc = VDraw1.ActiveDocument.WrapperObject
   doc.ImageSaveJPGQuality = 80 ' Default is 75, valid values 0 to 100 as byte
   doc.ImageSaveSize = 1200 'Height in pixels. Width of the JPG is calculated keeping the aspect ration of the drawing extends

   VDraw1.ActiveDocument.SaveAs "c:\test\test.jpg"
End Sub

Send comments on this topic.