mirror of
https://github.com/moparisthebest/Simba
synced 2025-02-22 22:12:55 -05:00
Cleanu
git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@47 3f818213-9676-44b0-a9b4-5e4c4e03d09d
This commit is contained in:
parent
150ad9fcf1
commit
5ca4ac75e1
@ -7,7 +7,7 @@
|
|||||||
<TargetFileExt Value=""/>
|
<TargetFileExt Value=""/>
|
||||||
<Title Value="Mufasa Stand Alone"/>
|
<Title Value="Mufasa Stand Alone"/>
|
||||||
<UseXPManifest Value="True"/>
|
<UseXPManifest Value="True"/>
|
||||||
<ActiveEditorIndexAtStart Value="5"/>
|
<ActiveEditorIndexAtStart Value="4"/>
|
||||||
</General>
|
</General>
|
||||||
<VersionInfo>
|
<VersionInfo>
|
||||||
<ProjectVersion Value=""/>
|
<ProjectVersion Value=""/>
|
||||||
@ -172,7 +172,7 @@
|
|||||||
<UnitName Value="TestUnit"/>
|
<UnitName Value="TestUnit"/>
|
||||||
<CursorPos X="24" Y="264"/>
|
<CursorPos X="24" Y="264"/>
|
||||||
<TopLine Value="250"/>
|
<TopLine Value="250"/>
|
||||||
<EditorIndex Value="6"/>
|
<EditorIndex Value="5"/>
|
||||||
<UsageCount Value="56"/>
|
<UsageCount Value="56"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit18>
|
</Unit18>
|
||||||
@ -302,9 +302,9 @@
|
|||||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<UnitName Value="Client"/>
|
<UnitName Value="Client"/>
|
||||||
<CursorPos X="73" Y="23"/>
|
<CursorPos X="29" Y="12"/>
|
||||||
<TopLine Value="1"/>
|
<TopLine Value="1"/>
|
||||||
<EditorIndex Value="5"/>
|
<EditorIndex Value="4"/>
|
||||||
<UsageCount Value="55"/>
|
<UsageCount Value="55"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit37>
|
</Unit37>
|
||||||
@ -330,8 +330,8 @@
|
|||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<UnitName Value="files"/>
|
<UnitName Value="files"/>
|
||||||
<CursorPos X="25" Y="64"/>
|
<CursorPos X="25" Y="64"/>
|
||||||
<TopLine Value="30"/>
|
<TopLine Value="34"/>
|
||||||
<EditorIndex Value="10"/>
|
<EditorIndex Value="9"/>
|
||||||
<UsageCount Value="56"/>
|
<UsageCount Value="56"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit40>
|
</Unit40>
|
||||||
@ -341,7 +341,7 @@
|
|||||||
<UnitName Value="Window"/>
|
<UnitName Value="Window"/>
|
||||||
<CursorPos X="40" Y="263"/>
|
<CursorPos X="40" Y="263"/>
|
||||||
<TopLine Value="263"/>
|
<TopLine Value="263"/>
|
||||||
<EditorIndex Value="11"/>
|
<EditorIndex Value="10"/>
|
||||||
<UsageCount Value="55"/>
|
<UsageCount Value="55"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit41>
|
</Unit41>
|
||||||
@ -364,7 +364,7 @@
|
|||||||
<UnitName Value="windowutil"/>
|
<UnitName Value="windowutil"/>
|
||||||
<CursorPos X="96" Y="86"/>
|
<CursorPos X="96" Y="86"/>
|
||||||
<TopLine Value="75"/>
|
<TopLine Value="75"/>
|
||||||
<EditorIndex Value="12"/>
|
<EditorIndex Value="11"/>
|
||||||
<UsageCount Value="18"/>
|
<UsageCount Value="18"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit44>
|
</Unit44>
|
||||||
@ -390,9 +390,7 @@
|
|||||||
<UnitName Value="Graphics"/>
|
<UnitName Value="Graphics"/>
|
||||||
<CursorPos X="17" Y="1353"/>
|
<CursorPos X="17" Y="1353"/>
|
||||||
<TopLine Value="1341"/>
|
<TopLine Value="1341"/>
|
||||||
<EditorIndex Value="21"/>
|
|
||||||
<UsageCount Value="15"/>
|
<UsageCount Value="15"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit47>
|
</Unit47>
|
||||||
<Unit48>
|
<Unit48>
|
||||||
<Filename Value="../../Units/MMLAddon/mmlthread.pas"/>
|
<Filename Value="../../Units/MMLAddon/mmlthread.pas"/>
|
||||||
@ -414,7 +412,7 @@
|
|||||||
<UnitName Value="mmlpsthread"/>
|
<UnitName Value="mmlpsthread"/>
|
||||||
<CursorPos X="31" Y="132"/>
|
<CursorPos X="31" Y="132"/>
|
||||||
<TopLine Value="107"/>
|
<TopLine Value="107"/>
|
||||||
<EditorIndex Value="7"/>
|
<EditorIndex Value="6"/>
|
||||||
<UsageCount Value="44"/>
|
<UsageCount Value="44"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit50>
|
</Unit50>
|
||||||
@ -429,9 +427,7 @@
|
|||||||
<Filename Value="../../../FPC/FPCCheckout/rtl/objpas/classes/classesh.inc"/>
|
<Filename Value="../../../FPC/FPCCheckout/rtl/objpas/classes/classesh.inc"/>
|
||||||
<CursorPos X="30" Y="260"/>
|
<CursorPos X="30" Y="260"/>
|
||||||
<TopLine Value="244"/>
|
<TopLine Value="244"/>
|
||||||
<EditorIndex Value="4"/>
|
|
||||||
<UsageCount Value="15"/>
|
<UsageCount Value="15"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit52>
|
</Unit52>
|
||||||
<Unit53>
|
<Unit53>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/rtl/objpas/types.pp"/>
|
<Filename Value="../../../FPC/FPCCheckout/rtl/objpas/types.pp"/>
|
||||||
@ -457,7 +453,7 @@
|
|||||||
<Unit56>
|
<Unit56>
|
||||||
<Filename Value="project1.lrs"/>
|
<Filename Value="project1.lrs"/>
|
||||||
<CursorPos X="70" Y="41"/>
|
<CursorPos X="70" Y="41"/>
|
||||||
<TopLine Value="7"/>
|
<TopLine Value="11"/>
|
||||||
<EditorIndex Value="1"/>
|
<EditorIndex Value="1"/>
|
||||||
<UsageCount Value="22"/>
|
<UsageCount Value="22"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
@ -529,7 +525,7 @@
|
|||||||
<Filename Value="../../Units/MMLAddon/PSInc/pscompile.inc"/>
|
<Filename Value="../../Units/MMLAddon/PSInc/pscompile.inc"/>
|
||||||
<CursorPos X="31" Y="10"/>
|
<CursorPos X="31" Y="10"/>
|
||||||
<TopLine Value="1"/>
|
<TopLine Value="1"/>
|
||||||
<EditorIndex Value="8"/>
|
<EditorIndex Value="7"/>
|
||||||
<UsageCount Value="16"/>
|
<UsageCount Value="16"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit66>
|
</Unit66>
|
||||||
@ -551,7 +547,7 @@
|
|||||||
<UnitName Value="bitmaps"/>
|
<UnitName Value="bitmaps"/>
|
||||||
<CursorPos X="33" Y="84"/>
|
<CursorPos X="33" Y="84"/>
|
||||||
<TopLine Value="74"/>
|
<TopLine Value="74"/>
|
||||||
<EditorIndex Value="14"/>
|
<EditorIndex Value="12"/>
|
||||||
<UsageCount Value="34"/>
|
<UsageCount Value="34"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit69>
|
</Unit69>
|
||||||
@ -572,8 +568,8 @@
|
|||||||
<Filename Value="../../Units/MMLAddon/PSInc/Wrappers/bitmap.inc"/>
|
<Filename Value="../../Units/MMLAddon/PSInc/Wrappers/bitmap.inc"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<CursorPos X="13" Y="43"/>
|
<CursorPos X="13" Y="43"/>
|
||||||
<TopLine Value="9"/>
|
<TopLine Value="13"/>
|
||||||
<EditorIndex Value="9"/>
|
<EditorIndex Value="8"/>
|
||||||
<UsageCount Value="33"/>
|
<UsageCount Value="33"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit72>
|
</Unit72>
|
||||||
@ -609,17 +605,13 @@
|
|||||||
<UnitName Value="FPimage"/>
|
<UnitName Value="FPimage"/>
|
||||||
<CursorPos X="17" Y="129"/>
|
<CursorPos X="17" Y="129"/>
|
||||||
<TopLine Value="112"/>
|
<TopLine Value="112"/>
|
||||||
<EditorIndex Value="15"/>
|
|
||||||
<UsageCount Value="14"/>
|
<UsageCount Value="14"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit77>
|
</Unit77>
|
||||||
<Unit78>
|
<Unit78>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/packages/fcl-image/src/fpimage.inc"/>
|
<Filename Value="../../../FPC/FPCCheckout/packages/fcl-image/src/fpimage.inc"/>
|
||||||
<CursorPos X="3" Y="44"/>
|
<CursorPos X="3" Y="44"/>
|
||||||
<TopLine Value="40"/>
|
<TopLine Value="40"/>
|
||||||
<EditorIndex Value="16"/>
|
|
||||||
<UsageCount Value="14"/>
|
<UsageCount Value="14"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit78>
|
</Unit78>
|
||||||
<Unit79>
|
<Unit79>
|
||||||
<Filename Value="../../../lazarus/lcl/lclintf.pas"/>
|
<Filename Value="../../../lazarus/lcl/lclintf.pas"/>
|
||||||
@ -633,18 +625,14 @@
|
|||||||
<UnitName Value="IntfGraphics"/>
|
<UnitName Value="IntfGraphics"/>
|
||||||
<CursorPos X="84" Y="1334"/>
|
<CursorPos X="84" Y="1334"/>
|
||||||
<TopLine Value="1334"/>
|
<TopLine Value="1334"/>
|
||||||
<EditorIndex Value="19"/>
|
|
||||||
<UsageCount Value="14"/>
|
<UsageCount Value="14"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit80>
|
</Unit80>
|
||||||
<Unit81>
|
<Unit81>
|
||||||
<Filename Value="../../../lazarus/lcl/graphtype.pp"/>
|
<Filename Value="../../../lazarus/lcl/graphtype.pp"/>
|
||||||
<UnitName Value="GraphType"/>
|
<UnitName Value="GraphType"/>
|
||||||
<CursorPos X="19" Y="634"/>
|
<CursorPos X="19" Y="634"/>
|
||||||
<TopLine Value="630"/>
|
<TopLine Value="630"/>
|
||||||
<EditorIndex Value="13"/>
|
|
||||||
<UsageCount Value="15"/>
|
<UsageCount Value="15"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit81>
|
</Unit81>
|
||||||
<Unit82>
|
<Unit82>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/packages/fcl-image/src/fpcolors.inc"/>
|
<Filename Value="../../../FPC/FPCCheckout/packages/fcl-image/src/fpcolors.inc"/>
|
||||||
@ -681,9 +669,7 @@
|
|||||||
<Filename Value="../../../lazarus/lcl/include/custombitmap.inc"/>
|
<Filename Value="../../../lazarus/lcl/include/custombitmap.inc"/>
|
||||||
<CursorPos X="3" Y="98"/>
|
<CursorPos X="3" Y="98"/>
|
||||||
<TopLine Value="96"/>
|
<TopLine Value="96"/>
|
||||||
<EditorIndex Value="22"/>
|
|
||||||
<UsageCount Value="13"/>
|
<UsageCount Value="13"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit87>
|
</Unit87>
|
||||||
<Unit88>
|
<Unit88>
|
||||||
<Filename Value="../../../Compilertje/Units/CogatUnits/compmaths.pas"/>
|
<Filename Value="../../../Compilertje/Units/CogatUnits/compmaths.pas"/>
|
||||||
@ -697,28 +683,22 @@
|
|||||||
<UnitName Value="math"/>
|
<UnitName Value="math"/>
|
||||||
<CursorPos X="1" Y="1"/>
|
<CursorPos X="1" Y="1"/>
|
||||||
<TopLine Value="1"/>
|
<TopLine Value="1"/>
|
||||||
<EditorIndex Value="20"/>
|
|
||||||
<UsageCount Value="13"/>
|
<UsageCount Value="13"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit89>
|
</Unit89>
|
||||||
<Unit90>
|
<Unit90>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/rtl/inc/systemh.inc"/>
|
<Filename Value="../../../FPC/FPCCheckout/rtl/inc/systemh.inc"/>
|
||||||
<CursorPos X="11" Y="513"/>
|
<CursorPos X="11" Y="513"/>
|
||||||
<TopLine Value="496"/>
|
<TopLine Value="496"/>
|
||||||
<EditorIndex Value="17"/>
|
|
||||||
<UsageCount Value="11"/>
|
<UsageCount Value="11"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit90>
|
</Unit90>
|
||||||
<Unit91>
|
<Unit91>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/rtl/i386/fastmove.inc"/>
|
<Filename Value="../../../FPC/FPCCheckout/rtl/i386/fastmove.inc"/>
|
||||||
<CursorPos X="44" Y="836"/>
|
<CursorPos X="44" Y="836"/>
|
||||||
<TopLine Value="817"/>
|
<TopLine Value="817"/>
|
||||||
<EditorIndex Value="18"/>
|
|
||||||
<UsageCount Value="11"/>
|
<UsageCount Value="11"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit91>
|
</Unit91>
|
||||||
</Units>
|
</Units>
|
||||||
<JumpHistory Count="30" HistoryIndex="29">
|
<JumpHistory Count="26" HistoryIndex="25">
|
||||||
<Position1>
|
<Position1>
|
||||||
<Filename Value="../../Units/MMLAddon/mmlpsthread.pas"/>
|
<Filename Value="../../Units/MMLAddon/mmlpsthread.pas"/>
|
||||||
<Caret Line="132" Column="31" TopLine="106"/>
|
<Caret Line="132" Column="31" TopLine="106"/>
|
||||||
@ -728,117 +708,101 @@
|
|||||||
<Caret Line="107" Column="21" TopLine="100"/>
|
<Caret Line="107" Column="21" TopLine="100"/>
|
||||||
</Position2>
|
</Position2>
|
||||||
<Position3>
|
<Position3>
|
||||||
<Filename Value="../../../lazarus/lcl/intfgraphics.pas"/>
|
|
||||||
<Caret Line="274" Column="64" TopLine="251"/>
|
|
||||||
</Position3>
|
|
||||||
<Position4>
|
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="30" Column="43" TopLine="28"/>
|
<Caret Line="30" Column="43" TopLine="28"/>
|
||||||
</Position4>
|
</Position3>
|
||||||
<Position5>
|
<Position4>
|
||||||
<Filename Value="../../Units/MMLCore/mufasatypes.pas"/>
|
<Filename Value="../../Units/MMLCore/mufasatypes.pas"/>
|
||||||
<Caret Line="20" Column="12" TopLine="1"/>
|
<Caret Line="20" Column="12" TopLine="1"/>
|
||||||
|
</Position4>
|
||||||
|
<Position5>
|
||||||
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
|
<Caret Line="37" Column="54" TopLine="19"/>
|
||||||
</Position5>
|
</Position5>
|
||||||
<Position6>
|
<Position6>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="37" Column="54" TopLine="19"/>
|
<Caret Line="85" Column="5" TopLine="51"/>
|
||||||
</Position6>
|
</Position6>
|
||||||
<Position7>
|
<Position7>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="85" Column="5" TopLine="51"/>
|
<Caret Line="80" Column="26" TopLine="63"/>
|
||||||
</Position7>
|
</Position7>
|
||||||
<Position8>
|
<Position8>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
|
||||||
<Caret Line="80" Column="26" TopLine="63"/>
|
|
||||||
</Position8>
|
|
||||||
<Position9>
|
|
||||||
<Filename Value="../../Units/MMLAddon/mmlpsthread.pas"/>
|
<Filename Value="../../Units/MMLAddon/mmlpsthread.pas"/>
|
||||||
<Caret Line="145" Column="17" TopLine="123"/>
|
<Caret Line="145" Column="17" TopLine="123"/>
|
||||||
</Position9>
|
</Position8>
|
||||||
<Position10>
|
<Position9>
|
||||||
<Filename Value="../../Units/MMLAddon/PSInc/pscompile.inc"/>
|
<Filename Value="../../Units/MMLAddon/PSInc/pscompile.inc"/>
|
||||||
<Caret Line="8" Column="30" TopLine="1"/>
|
<Caret Line="8" Column="30" TopLine="1"/>
|
||||||
|
</Position9>
|
||||||
|
<Position10>
|
||||||
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
|
<Caret Line="36" Column="60" TopLine="22"/>
|
||||||
</Position10>
|
</Position10>
|
||||||
<Position11>
|
<Position11>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="36" Column="60" TopLine="22"/>
|
<Caret Line="94" Column="67" TopLine="76"/>
|
||||||
</Position11>
|
</Position11>
|
||||||
<Position12>
|
<Position12>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="94" Column="67" TopLine="76"/>
|
<Caret Line="230" Column="5" TopLine="196"/>
|
||||||
</Position12>
|
</Position12>
|
||||||
<Position13>
|
<Position13>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="230" Column="5" TopLine="196"/>
|
<Caret Line="234" Column="22" TopLine="212"/>
|
||||||
</Position13>
|
</Position13>
|
||||||
<Position14>
|
<Position14>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="234" Column="22" TopLine="212"/>
|
<Caret Line="234" Column="9" TopLine="209"/>
|
||||||
</Position14>
|
</Position14>
|
||||||
<Position15>
|
<Position15>
|
||||||
<Filename Value="../../../lazarus/lcl/intfgraphics.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="3242" Column="48" TopLine="3238"/>
|
<Caret Line="229" Column="19" TopLine="212"/>
|
||||||
</Position15>
|
</Position15>
|
||||||
<Position16>
|
<Position16>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="234" Column="9" TopLine="209"/>
|
<Caret Line="109" Column="39" TopLine="106"/>
|
||||||
</Position16>
|
</Position16>
|
||||||
<Position17>
|
<Position17>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="229" Column="19" TopLine="212"/>
|
<Caret Line="247" Column="36" TopLine="230"/>
|
||||||
</Position17>
|
</Position17>
|
||||||
<Position18>
|
<Position18>
|
||||||
<Filename Value="../../../lazarus/lcl/intfgraphics.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="274" Column="64" TopLine="245"/>
|
<Caret Line="223" Column="68" TopLine="201"/>
|
||||||
</Position18>
|
</Position18>
|
||||||
<Position19>
|
<Position19>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="109" Column="39" TopLine="106"/>
|
<Caret Line="225" Column="21" TopLine="202"/>
|
||||||
</Position19>
|
</Position19>
|
||||||
<Position20>
|
<Position20>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="247" Column="36" TopLine="230"/>
|
<Caret Line="219" Column="23" TopLine="196"/>
|
||||||
</Position20>
|
</Position20>
|
||||||
<Position21>
|
<Position21>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="223" Column="68" TopLine="201"/>
|
<Caret Line="211" Column="60" TopLine="196"/>
|
||||||
</Position21>
|
</Position21>
|
||||||
<Position22>
|
<Position22>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="225" Column="21" TopLine="202"/>
|
<Caret Line="230" Column="3" TopLine="206"/>
|
||||||
</Position22>
|
</Position22>
|
||||||
<Position23>
|
<Position23>
|
||||||
<Filename Value="../../../FPC/FPCCheckout/packages/fcl-image/src/fpimage.inc"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="194" Column="23" TopLine="168"/>
|
<Caret Line="233" Column="3" TopLine="206"/>
|
||||||
</Position23>
|
</Position23>
|
||||||
<Position24>
|
<Position24>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="219" Column="23" TopLine="196"/>
|
<Caret Line="224" Column="60" TopLine="209"/>
|
||||||
</Position24>
|
</Position24>
|
||||||
<Position25>
|
<Position25>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
||||||
<Caret Line="211" Column="60" TopLine="196"/>
|
<Caret Line="86" Column="5" TopLine="31"/>
|
||||||
</Position25>
|
</Position25>
|
||||||
<Position26>
|
<Position26>
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
|
||||||
<Caret Line="230" Column="3" TopLine="206"/>
|
|
||||||
</Position26>
|
|
||||||
<Position27>
|
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
|
||||||
<Caret Line="233" Column="3" TopLine="206"/>
|
|
||||||
</Position27>
|
|
||||||
<Position28>
|
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
|
||||||
<Caret Line="224" Column="60" TopLine="209"/>
|
|
||||||
</Position28>
|
|
||||||
<Position29>
|
|
||||||
<Filename Value="../../Units/MMLCore/bitmaps.pas"/>
|
|
||||||
<Caret Line="86" Column="5" TopLine="31"/>
|
|
||||||
</Position29>
|
|
||||||
<Position30>
|
|
||||||
<Filename Value="../../Units/MMLCore/client.pas"/>
|
<Filename Value="../../Units/MMLCore/client.pas"/>
|
||||||
<Caret Line="1" Column="38" TopLine="1"/>
|
<Caret Line="1" Column="38" TopLine="1"/>
|
||||||
</Position30>
|
</Position26>
|
||||||
</JumpHistory>
|
</JumpHistory>
|
||||||
</ProjectOptions>
|
</ProjectOptions>
|
||||||
<CompilerOptions>
|
<CompilerOptions>
|
||||||
|
@ -134,9 +134,9 @@ begin
|
|||||||
GetBitmapSize(bmpz,w,h);
|
GetBitmapSize(bmpz,w,h);
|
||||||
Writeln(inttostr(w) + '-' + inttostr(h));
|
Writeln(inttostr(w) + '-' + inttostr(h));
|
||||||
SetBitmapSize(Bmpz,w div 2, h div 2);
|
SetBitmapSize(Bmpz,w div 2, h div 2);
|
||||||
SaveBitmap(Bmpz,'c:\Test.bmp');
|
SaveBitmap(Bmpz,'/tmp/test.bmp');
|
||||||
FreeBitmap(Bmpz);
|
//FreeBitmap(Bmpz);
|
||||||
Bmpz := LoadBitmap('c:\Test.bmp');
|
Bmpz := LoadBitmap('/tmp/test.bmp');
|
||||||
SetBitmapSize(bmpz,w,h);
|
SetBitmapSize(bmpz,w,h);
|
||||||
SaveBitmap(Bmpz,'c:\Test2.bmp');
|
SaveBitmap(Bmpz,'/tmp/test2.bmp');
|
||||||
end.
|
end.
|
||||||
|
@ -1,322 +1,322 @@
|
|||||||
unit bitmaps;
|
unit bitmaps;
|
||||||
|
|
||||||
{$mode objfpc}{$H+}
|
{$mode objfpc}{$H+}
|
||||||
|
|
||||||
interface
|
interface
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, FPImgCanv,FPImage,IntfGraphics,graphtype,MufasaTypes ,graphics;
|
Classes, SysUtils, FPImgCanv,FPImage,IntfGraphics,graphtype,MufasaTypes ,graphics;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
{ TMufasaBitmap }
|
{ TMufasaBitmap }
|
||||||
|
|
||||||
TMufasaBitmap = class(TObject)
|
TMufasaBitmap = class(TObject)
|
||||||
private
|
private
|
||||||
w,h : integer;
|
w,h : integer;
|
||||||
public
|
public
|
||||||
FData : PRGB32;
|
FData : PRGB32;
|
||||||
procedure SetSize(AWidth,AHeight : integer);
|
procedure SetSize(AWidth,AHeight : integer);
|
||||||
property Width : Integer read w;
|
property Width : Integer read w;
|
||||||
property Height : Integer read h;
|
property Height : Integer read h;
|
||||||
function SaveToFile(const FileName : string) :boolean;
|
function SaveToFile(const FileName : string) :boolean;
|
||||||
procedure LoadFromFile(const FileName : string);
|
procedure LoadFromFile(const FileName : string);
|
||||||
constructor Create;
|
constructor Create;
|
||||||
destructor Destroy;override;
|
destructor Destroy;override;
|
||||||
|
end;
|
||||||
end;
|
|
||||||
TMufasaBmpArray = Array of TMufasaBitmap;
|
TMufasaBmpArray = Array of TMufasaBitmap;
|
||||||
{ TMBitmaps }
|
{ TMBitmaps }
|
||||||
TMBitmaps = class(TObject)
|
TMBitmaps = class(TObject)
|
||||||
protected
|
protected
|
||||||
Client : TObject;
|
Client : TObject;
|
||||||
FreeSpots : Array of integer;
|
FreeSpots : Array of integer;
|
||||||
BmpArray : TMufasaBmpArray;
|
BmpArray : TMufasaBmpArray;
|
||||||
BmpsCurr,BmpsHigh,FreeSpotsHigh,FreeSpotsLen : integer;
|
BmpsCurr,BmpsHigh,FreeSpotsHigh,FreeSpotsLen : integer;
|
||||||
public
|
public
|
||||||
function GetBMP(Index : integer) : TMufasaBitmap;
|
function GetBMP(Index : integer) : TMufasaBitmap;
|
||||||
property Bmp[Index : integer]: TMufasaBitmap read GetBMP;
|
property Bmp[Index : integer]: TMufasaBitmap read GetBMP;
|
||||||
function CreateBMP(w, h: integer): Integer;
|
function CreateBMP(w, h: integer): Integer;
|
||||||
function CreateMirroredBitmap(bitmap: Integer): Integer;
|
function CreateMirroredBitmap(bitmap: Integer): Integer;
|
||||||
function CreateBMPFromFile(const Path : string) : integer;
|
function CreateBMPFromFile(const Path : string) : integer;
|
||||||
function CreateBMPFromString(width,height : integer; Data : string) : integer;
|
function CreateBMPFromString(width,height : integer; Data : string) : integer;
|
||||||
procedure FreeBMP( Number : integer);
|
procedure FreeBMP( Number : integer);
|
||||||
constructor Create(Owner : TObject);
|
constructor Create(Owner : TObject);
|
||||||
destructor Destroy;override;
|
destructor Destroy;override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
uses
|
uses
|
||||||
Windowutil,paszlib,DCPbase64;
|
Windowutil,paszlib,DCPbase64;
|
||||||
{ TMBitmaps }
|
{ TMBitmaps }
|
||||||
|
|
||||||
|
|
||||||
function TMBitmaps.GetBMP(Index: integer): TMufasaBitmap;
|
function TMBitmaps.GetBMP(Index: integer): TMufasaBitmap;
|
||||||
begin
|
begin
|
||||||
if (Index >= 0) and (Index <= BmpsCurr) then
|
if (Index >= 0) and (Index <= BmpsCurr) then
|
||||||
if BmpArray[Index] <> nil then
|
if BmpArray[Index] <> nil then
|
||||||
Result := BmpArray[Index];
|
Result := BmpArray[Index];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TMBitmaps.CreateBMP(w,h : integer): Integer;
|
function TMBitmaps.CreateBMP(w,h : integer): Integer;
|
||||||
begin;
|
begin
|
||||||
if BmpsCurr < BmpsHigh then
|
if BmpsCurr < BmpsHigh then
|
||||||
begin;
|
begin;
|
||||||
inc(BmpsCurr);
|
inc(BmpsCurr);
|
||||||
Result := BmpsCurr;
|
Result := BmpsCurr;
|
||||||
end else if (FreeSpotsHigh > -1) then
|
end else if (FreeSpotsHigh > -1) then
|
||||||
begin;
|
begin;
|
||||||
Result := FreeSpots[FreeSpotsHigh];
|
Result := FreeSpots[FreeSpotsHigh];
|
||||||
dec(FreeSpotsHigh);
|
dec(FreeSpotsHigh);
|
||||||
end else
|
end else
|
||||||
begin;
|
begin;
|
||||||
SetLength(BmpArray, BmpsHigh + 6);
|
SetLength(BmpArray, BmpsHigh + 6);
|
||||||
BmpsHigh := BmpsHigh + 5;
|
BmpsHigh := BmpsHigh + 5;
|
||||||
inc(BmpsCurr);
|
inc(BmpsCurr);
|
||||||
Result := BmpsCurr;
|
Result := BmpsCurr;
|
||||||
end;
|
end;
|
||||||
BmpArray[Result] := TMufasaBitmap.Create;
|
BmpArray[Result] := TMufasaBitmap.Create;
|
||||||
BmpArray[Result].SetSize(w,h);
|
BmpArray[Result].SetSize(w,h);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TMBitmaps.CreateMirroredBitmap(bitmap: Integer): Integer;
|
function TMBitmaps.CreateMirroredBitmap(bitmap: Integer): Integer;
|
||||||
var
|
var
|
||||||
w,h : integer;
|
w,h : integer;
|
||||||
y,x : integer;
|
y,x : integer;
|
||||||
Source,Dest : PRGB32;
|
Source,Dest : PRGB32;
|
||||||
begin;
|
begin
|
||||||
Source := Bmp[Bitmap].FData;
|
Source := Bmp[Bitmap].FData;
|
||||||
w := BmpArray[Bitmap].Width;
|
w := BmpArray[Bitmap].Width;
|
||||||
h := BmpArray[Bitmap].Height;
|
h := BmpArray[Bitmap].Height;
|
||||||
Result := CreateBMP(w,h);
|
Result := CreateBMP(w,h);
|
||||||
Dest := BmpArray[Result].FData;
|
Dest := BmpArray[Result].FData;
|
||||||
for y := (h-1) downto 0 do
|
for y := (h-1) downto 0 do
|
||||||
for x := (w-1) downto 0 do
|
for x := (w-1) downto 0 do
|
||||||
Dest[y*w+x] := Source[y*w+w-1-x];
|
Dest[y*w+x] := Source[y*w+w-1-x];
|
||||||
//Can be optmized, this is just proof of concept
|
//Can be optmized, this is just proof of concept
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TMBitmaps.CreateBMPFromFile(const Path: string): integer;
|
function TMBitmaps.CreateBMPFromFile(const Path: string): integer;
|
||||||
begin
|
begin
|
||||||
Result := CreateBMP(0,0);
|
Result := CreateBMP(0,0);
|
||||||
BmpArray[result].LoadFromFile(Path);
|
BmpArray[result].LoadFromFile(Path);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function HexToInt(HexNum: string): LongInt;inline;
|
function HexToInt(HexNum: string): LongInt;inline;
|
||||||
begin
|
begin
|
||||||
Result:=StrToInt('$' + HexNum);
|
Result:=StrToInt('$' + HexNum);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TMBitmaps.CreateBMPFromString(width, height: integer; Data: string): integer;
|
function TMBitmaps.CreateBMPFromString(width, height: integer; Data: string): integer;
|
||||||
var
|
var
|
||||||
I,II,x,y: LongWord;
|
I,II,x,y: LongWord;
|
||||||
DestLen : LongWord;
|
DestLen : LongWord;
|
||||||
Dest,Source : string;
|
Dest,Source : string;
|
||||||
DestPoint, Point : PByte;
|
DestPoint, Point : PByte;
|
||||||
LazIntf : TLazIntfImage;
|
LazIntf : TLazIntfImage;
|
||||||
|
|
||||||
begin;
|
begin
|
||||||
Result := CreateBMP(width,height);
|
Result := CreateBMP(width,height);
|
||||||
if (Data <> '') and (Length(Data) <> 6) then
|
if (Data <> '') and (Length(Data) <> 6) then
|
||||||
begin;
|
begin;
|
||||||
Point := Pointer(BmpArray[Result].FData);
|
Point := Pointer(BmpArray[Result].FData);
|
||||||
if Data[1] = 'b' then
|
if Data[1] = 'b' then
|
||||||
begin;
|
begin;
|
||||||
Source := Base64DecodeStr(Copy(Data,2,Length(Data) - 1));
|
Source := Base64DecodeStr(Copy(Data,2,Length(Data) - 1));
|
||||||
Destlen := Width * Height * 3;
|
Destlen := Width * Height * 3;
|
||||||
Setlength(Dest,DestLen);
|
Setlength(Dest,DestLen);
|
||||||
if uncompress(PChar(Dest),Destlen,pchar(Source), Length(Source)) = Z_OK then
|
if uncompress(PChar(Dest),Destlen,pchar(Source), Length(Source)) = Z_OK then
|
||||||
begin;
|
begin;
|
||||||
DestPoint := @Dest[1];
|
DestPoint := @Dest[1];
|
||||||
i := 0;
|
i := 0;
|
||||||
ii := 2;
|
ii := 2;
|
||||||
Dec(DestLen);
|
Dec(DestLen);
|
||||||
if DestLen > 2 then
|
if DestLen > 2 then
|
||||||
begin;
|
begin;
|
||||||
while (ii < DestLen) do
|
while (ii < DestLen) do
|
||||||
Begin;
|
Begin;
|
||||||
Point[i]:= DestPoint[ii+2];
|
Point[i]:= DestPoint[ii+2];
|
||||||
Point[i+1]:= DestPoint[ii+1];
|
Point[i+1]:= DestPoint[ii+1];
|
||||||
Point[i+2]:= DestPoint[ii];
|
Point[i+2]:= DestPoint[ii];
|
||||||
ii := ii + 3;
|
ii := ii + 3;
|
||||||
i := i + 4;
|
i := i + 4;
|
||||||
end;
|
end;
|
||||||
Point[i] := DestPoint[1];
|
Point[i] := DestPoint[1];
|
||||||
Point[i+1] := DestPoint[0];
|
Point[i+1] := DestPoint[0];
|
||||||
Point[i+2] := DestPoint[ii];
|
Point[i+2] := DestPoint[ii];
|
||||||
end else if (Width = 1) and (Height =1 ) then
|
end else if (Width = 1) and (Height =1 ) then
|
||||||
begin;
|
begin;
|
||||||
Point[0] := DestPoint[1];
|
Point[0] := DestPoint[1];
|
||||||
Point[1] := DestPoint[0];
|
Point[1] := DestPoint[0];
|
||||||
Point[2] := DestPoint[2];
|
Point[2] := DestPoint[2];
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end else if Data[1] = 'z' then
|
end else if Data[1] = 'z' then
|
||||||
begin;
|
begin;
|
||||||
Destlen := Width * Height * 3 *2;
|
Destlen := Width * Height * 3 *2;
|
||||||
Setlength(Dest,DestLen);
|
Setlength(Dest,DestLen);
|
||||||
ii := (Length(Data) - 1) div 2;
|
ii := (Length(Data) - 1) div 2;
|
||||||
SetLength(Source,ii);
|
SetLength(Source,ii);
|
||||||
for i := 1 to ii do
|
for i := 1 to ii do
|
||||||
Source[i] := Chr(HexToInt(Data[i * 2] + Data[i * 2+1]));
|
Source[i] := Chr(HexToInt(Data[i * 2] + Data[i * 2+1]));
|
||||||
if uncompress(PChar(Dest),Destlen,pchar(Source), ii) = Z_OK then
|
if uncompress(PChar(Dest),Destlen,pchar(Source), ii) = Z_OK then
|
||||||
begin;
|
begin;
|
||||||
ii := 1;
|
ii := 1;
|
||||||
i := 0;
|
i := 0;
|
||||||
while (II < DestLen) do
|
while (II < DestLen) do
|
||||||
begin;
|
begin;
|
||||||
Point[i+2]:= HexToInt(Dest[ii] + Dest[ii + 1]);
|
Point[i+2]:= HexToInt(Dest[ii] + Dest[ii + 1]);
|
||||||
Point[i+1]:= HexToInt(Dest[ii+2] + Dest[ii + 3]);
|
Point[i+1]:= HexToInt(Dest[ii+2] + Dest[ii + 3]);
|
||||||
Point[i]:= HexToInt(Dest[ii+4] + Dest[ii + 5]);
|
Point[i]:= HexToInt(Dest[ii+4] + Dest[ii + 5]);
|
||||||
ii := ii + 6;
|
ii := ii + 6;
|
||||||
i := i + 4;
|
i := i + 4;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end else if LongWord(Length(Data)) = (Width * Height * 3 * 2) then
|
end else if LongWord(Length(Data)) = (Width * Height * 3 * 2) then
|
||||||
begin;
|
begin;
|
||||||
ii := 1;
|
ii := 1;
|
||||||
i := 0;
|
i := 0;
|
||||||
Destlen := Width * Height * 3 * 2;
|
Destlen := Width * Height * 3 * 2;
|
||||||
while (II < DestLen) do
|
while (II < DestLen) do
|
||||||
begin;
|
begin;
|
||||||
Point[i+2]:= HexToInt(Data[ii] + Data[ii + 1]);
|
Point[i+2]:= HexToInt(Data[ii] + Data[ii + 1]);
|
||||||
Point[i+1]:= HexToInt(Data[ii+2] + Data[ii + 3]);
|
Point[i+1]:= HexToInt(Data[ii+2] + Data[ii + 3]);
|
||||||
Point[i]:= HexToInt(Data[ii+4] + Data[ii + 5]);
|
Point[i]:= HexToInt(Data[ii+4] + Data[ii + 5]);
|
||||||
ii := ii + 6;
|
ii := ii + 6;
|
||||||
i := i + 4;
|
i := i + 4;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end else
|
end else
|
||||||
begin;
|
begin;
|
||||||
{ if Length(data) = 6 then
|
{ if Length(data) = 6 then
|
||||||
FastDrawClear(Result,HexToInt(Data))
|
FastDrawClear(Result,HexToInt(Data))
|
||||||
else
|
else
|
||||||
Bmps[Result].Canvas.Rectangle(0,0,Width-1,Height-1);}
|
Bmps[Result].Canvas.Rectangle(0,0,Width-1,Height-1);}
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMBitmaps.FreeBMP(Number: integer);
|
procedure TMBitmaps.FreeBMP(Number: integer);
|
||||||
begin;
|
begin
|
||||||
if Number = BmpsCurr then
|
if Number = BmpsCurr then
|
||||||
Dec(BmpsCurr)
|
Dec(BmpsCurr)
|
||||||
else
|
else
|
||||||
begin;
|
begin;
|
||||||
inc(FreeSpotsHigh);
|
inc(FreeSpotsHigh);
|
||||||
if FreeSpotsHigh = FreeSpotsLen then
|
if FreeSpotsHigh = FreeSpotsLen then
|
||||||
begin;
|
begin;
|
||||||
inc(FreeSpotsLen);
|
inc(FreeSpotsLen);
|
||||||
SetLength(FreeSpots, FreeSpotsLen);
|
SetLength(FreeSpots, FreeSpotsLen);
|
||||||
end;
|
end;
|
||||||
FreeSpots[FreeSpotsHigh] := Number;
|
FreeSpots[FreeSpotsHigh] := Number;
|
||||||
end;
|
end;
|
||||||
BmpArray[Number].Free;
|
BmpArray[Number].Free;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TMufasaBitmap.SaveToFile(const FileName: string): boolean;
|
function TMufasaBitmap.SaveToFile(const FileName: string): boolean;
|
||||||
var
|
var
|
||||||
rawImage : TRawImage;
|
rawImage : TRawImage;
|
||||||
Bmp : TLazIntfImage;
|
Bmp : TLazIntfImage;
|
||||||
begin
|
begin
|
||||||
ArrDataToRawImage(FData,Point(w,h),RawImage);
|
ArrDataToRawImage(FData,Point(w,h),RawImage);
|
||||||
// Bmp := Graphics.TBitmap.Create;
|
// Bmp := Graphics.TBitmap.Create;
|
||||||
Bmp := TLazIntfImage.Create(RawImage,true);
|
Bmp := TLazIntfImage.Create(RawImage,true);
|
||||||
Bmp.SaveToFile(FileName);
|
Bmp.SaveToFile(FileName);
|
||||||
Bmp.Free;
|
Bmp.Free;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMufasaBitmap.LoadFromFile(const FileName: string);
|
procedure TMufasaBitmap.LoadFromFile(const FileName: string);
|
||||||
var
|
var
|
||||||
LazIntf : TLazIntfImage;
|
LazIntf : TLazIntfImage;
|
||||||
RawImageDesc : TRawImageDescription;
|
RawImageDesc : TRawImageDescription;
|
||||||
begin
|
begin
|
||||||
if FileExists(FileName) then
|
if FileExists(FileName) then
|
||||||
begin;
|
begin;
|
||||||
LazIntf := TLazIntfImage.Create(0,0);
|
LazIntf := TLazIntfImage.Create(0,0);
|
||||||
RawImageDesc.Init_BPP32_B8G8R8_BIO_TTB(LazIntf.Width,LazIntf.Height);
|
RawImageDesc.Init_BPP32_B8G8R8_BIO_TTB(LazIntf.Width,LazIntf.Height);
|
||||||
LazIntf.DataDescription := RawImageDesc;
|
LazIntf.DataDescription := RawImageDesc;
|
||||||
LazIntf.LoadFromFile(FileName);
|
LazIntf.LoadFromFile(FileName);
|
||||||
if Assigned(FData) then
|
if Assigned(FData) then
|
||||||
Freemem(FData);
|
Freemem(FData);
|
||||||
Self.W := LazIntf.Width;
|
Self.W := LazIntf.Width;
|
||||||
Self.H := LazIntf.Height;
|
Self.H := LazIntf.Height;
|
||||||
FData := GetMem(Self.W*Self.H*SizeOf(TRGB32));
|
FData := GetMem(Self.W*Self.H*SizeOf(TRGB32));
|
||||||
Move(LazIntf.PixelData[0],FData[0],w*h*sizeOf(TRGB32));
|
Move(LazIntf.PixelData[0],FData[0],w*h*sizeOf(TRGB32));
|
||||||
LazIntf.Free;
|
LazIntf.Free;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
constructor TMBitmaps.Create(Owner: TObject);
|
constructor TMBitmaps.Create(Owner: TObject);
|
||||||
begin
|
begin
|
||||||
inherited Create;
|
inherited Create;
|
||||||
SetLength(BmpArray,50);
|
SetLength(BmpArray,50);
|
||||||
SetLength(FreeSpots, 50);
|
SetLength(FreeSpots, 50);
|
||||||
FreeSpotsLen := 50;
|
FreeSpotsLen := 50;
|
||||||
BmpsHigh := 49;
|
BmpsHigh := 49;
|
||||||
BmpsCurr := -1;
|
BmpsCurr := -1;
|
||||||
FreeSpotsHigh := -1;
|
FreeSpotsHigh := -1;
|
||||||
Self.Client := Owner;
|
Self.Client := Owner;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
destructor TMBitmaps.Destroy;
|
destructor TMBitmaps.Destroy;
|
||||||
begin
|
begin
|
||||||
|
|
||||||
inherited Destroy;
|
inherited Destroy;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
{ TMufasaBitmap }
|
{ TMufasaBitmap }
|
||||||
function Min(a,b:integer) : integer;
|
function Min(a,b:integer) : integer;
|
||||||
begin;
|
begin
|
||||||
if a < b then
|
if a < b then
|
||||||
result := a
|
result := a
|
||||||
else
|
else
|
||||||
result := b;
|
result := b;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMufasaBitmap.SetSize(Awidth, Aheight: integer);
|
procedure TMufasaBitmap.SetSize(Awidth, Aheight: integer);
|
||||||
var
|
var
|
||||||
NewData : PRGB32;
|
NewData : PRGB32;
|
||||||
i,minw,minh : integer;
|
i,minw,minh : integer;
|
||||||
begin
|
begin
|
||||||
if (AWidth <> w) or (AHeight <> h) then
|
if (AWidth <> w) or (AHeight <> h) then
|
||||||
begin;
|
begin;
|
||||||
if AWidth*AHeight <> 0 then
|
if AWidth*AHeight <> 0 then
|
||||||
begin;
|
begin;
|
||||||
NewData := GetMem(AWidth * AHeight * SizeOf(TRGB32));
|
NewData := GetMem(AWidth * AHeight * SizeOf(TRGB32));
|
||||||
FillDWord(NewData[0],AWidth*AHeight,0);
|
FillDWord(NewData[0],AWidth*AHeight,0);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
NewData := nil;
|
NewData := nil;
|
||||||
if Assigned(FData) and Assigned(NewData) and (w*H <> 0) then
|
if Assigned(FData) and Assigned(NewData) and (w*H <> 0) then
|
||||||
begin;
|
begin;
|
||||||
minw := Min(AWidth,w);
|
minw := Min(AWidth,w);
|
||||||
minh := Min(AHeight,h);
|
minh := Min(AHeight,h);
|
||||||
for i := 0 to minh - 1 do
|
for i := 0 to minh - 1 do
|
||||||
Move(FData[i*w],Newdata[i*AWidth],minw * SizeOf(TRGB32));
|
Move(FData[i*w],Newdata[i*AWidth],minw * SizeOf(TRGB32));
|
||||||
end;
|
end;
|
||||||
if Assigned(FData) then
|
if Assigned(FData) then
|
||||||
FreeMem(FData);
|
FreeMem(FData);
|
||||||
FData := NewData;
|
FData := NewData;
|
||||||
w := AWidth;
|
w := AWidth;
|
||||||
h := AHeight;
|
h := AHeight;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
constructor TMufasaBitmap.Create;
|
constructor TMufasaBitmap.Create;
|
||||||
begin
|
begin
|
||||||
inherited Create;
|
inherited Create;
|
||||||
FData:= nil;
|
FData:= nil;
|
||||||
w := 0;
|
w := 0;
|
||||||
h := 0;
|
h := 0;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
destructor TMufasaBitmap.Destroy;
|
destructor TMufasaBitmap.Destroy;
|
||||||
begin
|
begin
|
||||||
if Assigned(FData) then
|
if Assigned(FData) then
|
||||||
Freemem(FData,w*h*SizeOf(TRGB32));
|
Freemem(FData,w*h*SizeOf(TRGB32));
|
||||||
inherited Destroy;
|
inherited Destroy;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user