PDA

View Full Version : Bitmap Analyzer



Markus
10-25-2007, 05:40 PM
Well I was bored, angry at my computer and after way too much lag of scar, I decided to port this (http://villavu.com/forum/showthread.php?t=8700) thing by Boreas to Delphi. You enter a few bitmaps, and this outputs colors/tolerances to use with them to ALWAYS find the MS object, from any angle and from any world.

GUI is pretty basic and straightforward, you can paste from clipboard or open from file, then press do it :)
NOTE: You can't remove bitmaps once loaded, you have to restart the program.

CREDITS
Boreas for the original source
Benland100 for telling how CTS 1 works :)

R0b0t1
10-25-2007, 06:51 PM
ooooh.... Ahhhh.


Cool.

Smartzkid
10-25-2007, 07:07 PM
Good work, Markus.

Any idea how much faster it is?

mastaraymond
10-25-2007, 07:35 PM
Good work, Markus.

Any idea how much faster it is?
Leme guess : 3 times or even faster?

Markus
10-26-2007, 03:28 PM
Leme guess : 3 times or even faster?

Na, even better.
Comp Specs: P4 2.1 GHZ 256MB ram.
Two bitmaps
Scar: around 5 minutes?
Delphi: 2 seconds :f:

Mine is 150 times as fast :p

Lalaji
12-13-2007, 09:41 PM
Just ran it...

What does this mean?

1648941 100

Color : 1648941
Tolerance : 100
??

Boreas
12-14-2007, 05:58 AM
Yes. And if thats the lowest tolerance, then you probably want to try it again with different bitmaps (in a lot of situations, any tol over 50 would probably get too many false positives). Crop the bitmaps as small as possible around the target, and make all background pixels black(0) in paint (also any part of target you know is similar to surroundings, or is subject to change, or you just want to ignore).

Markus
12-14-2007, 01:51 PM
Oh, be aware that this version is actually CTS 0, not CTS 1. I forgot somehow to save the CTS 1 one :duh:
I was testing it a minute ago, and I saw different results between mine and the scar one.
ColorToleranceSpeed(0); in the scar one fixed it.

Naum
12-14-2007, 04:55 PM
so instead of making a huge laggy bmp i could use this and just use find color. Thx markus you are amazing :)

A G E N T
12-14-2007, 11:09 PM
I ran it with three piccys of the shopkeeper, and it returned -1 and 3 tolerance. :/

chitin
12-27-2007, 08:46 AM
i think i could use this, but im not enirly sure what it does, or how to use it...how do these colors help?

edit:wait...so i should make it search for all the colors (in x1,y1,x2,y2) it gives me instead of searching for the same bitmap (in x1,y1,x2,y2) --because its faster?!?!?