Metafile to SWF
Submitted by GROL on 11 April, 2011 - 17:25

This demo converts Windows metafiles (WMF/EMF) to Flash. Select options and double click the file to view result.
Also, debug version writes log-file for each record of metafile. If you find incorect display, please send the log-file to DelphiFlash team.
Source archive: emfparsing.zip (1.1Mb)
Some sample source:
procedure TForm1.DemoDraw(C: TCanvas); begin if CBOriginal.Checked then begin if C is TFlashCanvas then TFlashCanvas(C).Draw(0, 10, MF.Picture.Metafile) else C.Draw(0, 10, MF.Picture.Metafile); end; if CBStrech.Checked then begin if C is TFlashCanvas then TFlashCanvas(C).StretchDraw(Rect(0, 10, NewSize.cx, 10 + NewSize.cy), MF.Picture.Metafile) else C.StretchDraw(Rect(0, 10, NewSize.cx, 10 + NewSize.cy), MF.Picture.Metafile); end; end;