J2KTargetFileSize Example for Delphi
var
RasterIO: LEADRasterIO;
begin
RasterIO.J2KSetDefaults ();
RasterIO.J2KCompressionControl:= J2K_COMP_TARGETSIZE;
RasterIO.J2KTargetFileSize:= 30 * 1024;
RasterIO.Save (LEADRasterView1.Raster, 'WideString (c:\temp\30k.j2k', FILE_J2K, 0, 0, SAVE_OVERWRITE);
end;