RE: Re: Optimize this code
"Richard Le Mesurier (Investec Employee Benefits)" <[email protected]> Thu, 21 Aug 2003 12:10:07 +0200
| Newsgroups | gmane.comp.lang.delphi.programming |
|---|---|
| Message-ID | <11D85203E297E144933302AFB4A763B9334A92@iebjhbex2> |
I just looked at this again today, and understanding nothing about graphics
I think I might be able to help.
I remember somewhere that when you use "WITH" it only makes one object
dereference in the code.
I suspect that surrounding the 3rd line with a "WITH" might make it a teeny
bit faster...:
i.e.
BMP.Canvas.Pixels[X, Y] := (BMP.Canvas.Pixels[X, Y] and not (1 shl Pos) or
Value);
becomes
with BMP.Canvas do
Pixels[X, Y] := (Pixels[X, Y] and not (1 shl Pos) or Value);
I'd be interested to hear the results of this change please if you do decide
to test it.
Ric
NOTICE - This message contains privileged and confidential
information intended only for the use of the addressee
named above. Any review, retransmission, dissemination,
copying, disclosure or other use of, or taking of any
action in reliance upon, this information by person or
entities other than the intended recipient is prohibited.
If you have received this message in error, please notify
the sender by return email and delete this message.
This message should not be copied or used for any purpose
other than intended, nor should it be disclosed to any
other person. Any views expressed in this message are those
of the individual sender, except where the sender specifically
states them to be the view of Investec Group, its
subsidiaries or associates. The Investec Group is not
liable for the security of information sent by e-mail at
your request, nor for the proper and complete transmission
of the information contained in the communication nor for
any delay in its receipt. Please note that the recipient
must scan this e-mail and any attached files for viruses
and the like. The Investec Group accepts no liability of
whatever nature for any loss, liability, damage or expense
resulting directly or indirectly from the access of any files
which are attached to this message.
------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for Your HP, Epson, Canon or Lexmark
Printer at Myinks.com. Free s/h on orders $50 or more to the US & Canada. http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/l.m7sD/LIdGAA/qnsNAA/i7folB/TM
---------------------------------------------------------------------~->
Delphi VCL Top Sites!
http://www.sandbrooksoftware.com/TS/TS2/Components.shtml
---------------------------------------------------------------
Unsubscribe:[email protected]
List owner:[email protected]
---------------------------------------------------------------
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/