473,379 Members | 1,337 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

Compare Bytes

I need to compare to byte values, but one of them may differ from the
other by let's say 5%, and they still should count as same.
I need a fast method, because i am going to compare a set of about 1
000 000 with other set of 1 000 000 bytes. This should go in below 1
sec.

Can't figure the algorithm

What I try to achive is to compare two bitmaps, which may have some of
theit pixles in different RGB values. I need to check if those values
are in specified range, if so i want to condsider the two images as
indentical.
I iterate through all pixels of the each image and then compare it's
color value by getting separate values for R, G and B components, which
are represented as bytes.
A lot of calculations :-(

Maybe their is a faster method.

Nov 21 '05 #1
0 1249

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: sjoshi | last post by:
I need to compare and update a Binary(8) coln with values from an Int(4) coln. Could someone please explain how to do this..?? thanks Sunit
122
by: Einar | last post by:
Hi, I wonder if there is a nice bit twiddling hack to compare a large number of variables? If you first store them in an array, you can do: for (i = 0; i < n; i++) { if (array != value) {...
1
by: Sunit Joshi | last post by:
Hello I have a situation like this, I have 2 colns in an SQLServer table which are set to following SQLServer data types sTime->Binary (length=8), and tTime -> Int (length=4) I need to compare...
3
by: NathanV | last post by:
I'm trying to compare two byte's. I think I have to use binary operators. How can I tell if two bytes have the same value? Also, I have a function that is returning a byte value. Is there a...
2
by: SP | last post by:
Hi All, I need to compare two files line by line and copy the differing lines to a new files. I.e. Compare file1 and file2 line by line. Copy only differing lines to file3. I tried a couple...
5
by: sjoshi | last post by:
I have an SQLBinary (8) field(mts) with data like 0x01F4000000000000, 0x0400000000000000, etc. Now I need to compare just the first 4 bytes to an Int32 field (cts) and update the SQLBinary field if...
5
by: | last post by:
What is the simplest way to determine if two files are identical (that is, all bytes the same). I want to check to see it the current version of a .jpg file is identical to the original. I wish...
5
by: Oleg Subachev | last post by:
Is there other way of comparing two byte arrays than iterating through the two and compare individual bytes ? Oleg Subachev
3
by: grey | last post by:
does anyone suggest me how to write a windows application for comparing two pdf content. The requirement is very easy... i only need to inform user two pdf are differnet, no need to spot where the...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.