FHannes Posted November 17, 2012 Share Posted November 17, 2012 (edited) I bet you didn't see this coming? Regular: http://svn.scar-divi.com/scar/ Portable: http://svn.scar-divi.com/scar_portable/ Setup instructions: http://forums.scar-divi.com/showthread.php?505-Downloading-SCAR-Divi-Prerelease Changelog: New: - procedure ReplaceColors(const Bmp: TSCARBitmap; const Colors: TIntArray; const NewColor: Integer); - procedure ReplaceColorsTol(const Bmp: TSCARBitmap; const Colors: TIntArray; const NewColor, Tol: Integer); - function RandomTIA(const Count, Range: Integer): TIntArray; - function RandomTIAEx(const Count, Range: Integer; const AllowDuplicates: Boolean): TIntArray; - procedure OffsetTEA(var TEA: TExtArray; const Offset: Extended); - function TEAInsert(var TEA: TExtArray; const Index: Integer; const Ext: Extended): Integer; - function InvertColor(const Color: Integer): Integer; - TSCARBitmap.Invert - function SpiralPoint(const Pos: Cardinal): TPoint; - function SpiralPointEx(const Pos: Cardinal; const Origin: TPoint): TPoint; - function SpiralPos(const Pt: TPoint): Cardinal; - function SpiralPosEx(const Pt, Origin: TPoint): Cardinal; - procedure SortTPASpiral(var TPA: TPointArray); - procedure SortTPASpiralEx(var TPA: TPointArray; const Point: TPoint); - function CopyTIA(const TIA: TIntArray): TIntArray; - function CopyTIAEx(const TIA: TIntArray; const Index, Count: Integer): TIntArray; - function ATPADelete(var ATPA: T2DPointArray; const Index: Integer): TPointArray; - function ATIADelete(var ATIA: T2DIntArray; const Index: Integer): TIntArray; - function ATPAContains(const ATPA: T2DPointArray; const TPA: TPointArray): Boolean; - function ATIAContains(const ATIA: T2DIntArray; const TIA: TIntArray): Boolean; - function PermuteTPA(const TPA: TPointArray): T2DPointArray; - function PermuteTIA(const TIA: TIntArray): T2DIntArray; - procedure TIAFreq(const TIA: TIntArray; out Values, Frequencies: TIntArray); - procedure TIARelFreq(const TIA: TIntArray; out Values: TIntArray; out Frequencies: TExtArray); - procedure TPAFreq(const TPA: TPointArray; out Values: TPointArray; out Frequencies: TIntArray); - procedure TPARelFreq(const TPA: TPointArray; out Values: TPointArray; out Frequencies: TExtArray); Tweaks: - TPAMiddle => TPAMean - SortATPAByMiddle => SortATPAByMean - SortATPAByMiddleEx => SortATPAByMeanEx Removed: - procedure TPASort(var TPA: TPointArray); (alias: SortTPA) - procedure TPASortEx(var TPA: TPointArray; const Point: TPoint); (alias: SortTPAEx) - function AMax(const TIA: TIntArray): Integer; (alias: TIAMax) - function AMin(const TIA: TIntArray): Integer; (alias: TIAMin) - function TPAMiddleEx(const TPA: TPointArray; out x, y: Integer): Boolean; Enjoy ~Freddy Edited December 8, 2012 by Freddy Quote Link to comment Share on other sites More sharing options...
Janilabo Posted November 17, 2012 Share Posted November 17, 2012 LOL yeap, I was surprised an Alpha for this version would be out so quickly - not complaining at all, though! Quote Link to comment Share on other sites More sharing options...
FHannes Posted December 8, 2012 Author Share Posted December 8, 2012 I've uploaded a new build with some new functions that have been accumulating. Quote Link to comment Share on other sites More sharing options...
Janilabo Posted December 8, 2012 Share Posted December 8, 2012 Thanks! Great additions. Quote Link to comment Share on other sites More sharing options...
LordJashin Posted December 8, 2012 Share Posted December 8, 2012 What's Permute, and SpiralPoint do exactly? I feel so dumb DX Quote Link to comment Share on other sites More sharing options...
Janilabo Posted December 8, 2012 Share Posted December 8, 2012 LJ, check out example of PermuteTPA in samples folder. That will give you idea how it works. It's very useful with integers (using PermuteTIA())! Quote Link to comment Share on other sites More sharing options...
FHannes Posted December 8, 2012 Author Share Posted December 8, 2012 (edited) What's Permute, and SpiralPoint do exactly? I feel so dumb DX SpiralPoint returns the position of a point on a spiral, with 0 being the center point. http://en.wikipedia.org/wiki/Permutation EDIT: Once I have some time they'll all be documented. Edited December 8, 2012 by Freddy Quote Link to comment Share on other sites More sharing options...