WMFResolution example for Delphi
//This example displays the default resolution stored in a WMF,
//changes the resolution to 150 dpi, and then loads the image
//Display resolution stored in WMF
//Note that InfoXRes and InfoYRes will return the same value
var
RasterIO: LEADRasterIO;
begin
RasterIO:= CreateComObject (CLASS_LEADRasterIO) as LEADRasterIO;
RasterIO.GetFileInfo (LEADRasterView1.Raster,
'v:\Images\Test.wmf', 0, 0 ) ;
ShowMessage ('InfoXRes: ' + IntToStr (RasterIO.InfoXRes) + ' InfoYRes: ' +
IntToStr (RasterIO.InfoYRes)) ;
//Set resolution so WMF is loaded at 150 dpi
RasterIO.WMFResolution:= 150;
RasterIO.Load (LEADRasterView1.Raster,
'v:\Images\Test.wmf',
0, 0, 1);
end;