DiagramComponent::exportImage() method always exports image files with PNG's hex signature

Hello Syncfusion team,


I noticed that the DiagramComponent::exportImage() and DiagramComponent::exportDiagram() methods alway "stamps" the exported image file with hex signature of PNG (irrespective of the IExportOptions::format flag specified).


If you observe the exported image file in a hex editor, it'll always have the

89 50 4E 47 0D 0A 1A 0A at the beginning of the file. This is the hex signature for PNG files.



Even if you export to a JPEG file (by specifying IExportOptions::format = 'JPG'), it'll still have the same PNG's hex signature (and not JPEG's hex signature FF D8 FF).


Can you please take a look?

PS: You can use the Hex editor extension to VSCode to view the file content.


Thanks,

-Mithun



4 Replies

MI Mithun July 20, 2021 01:59 PM UTC

I have attached a repro. From Syncfusion's diagram demo, I export a JPG file. However, it has the PNG hex signature.



Attachment: GIF_7202021_72058_PM_bef1de5.zip


GG Gowtham Gunashekar Syncfusion Team July 21, 2021 11:48 AM UTC

Hi Mithun,  
   
We can be able to replicate the reported issue at our end, we are validating the issue and update you with more details on 23rd July 2021.  
   
Regards,  
Gowtham  



GG Gowtham Gunashekar Syncfusion Team July 23, 2021 01:57 PM UTC

 
Hi Mithun,   
    
Reported Issue : While decode the exported JPG image it has the signature of PNG Image 
 
We can reproduce the issue and confirmed this as a defect. We have logged a defect report for this issue. We will fix this issue and provide the patch on 10th August ,2021 weekly patch release.    
        
 
Regards,   
Gowtham 
 
 
 
 
 



GG Gowtham Gunashekar Syncfusion Team August 10, 2021 02:34 PM UTC

Hi Mithun, 
 
We have fixed the reported issue and included it in our patch release (v 19.2.51)  which is rolled out successfully.                              
     
Please upgrade to the latest version packages to resolve this issue.                   
     
     
 
Regards   
Gowtham  


Loader.
Up arrow icon