|
From: Ioannis V. <iv...@em...> - 2003-06-26 23:50:43
|
A correction:
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf
> Of Inge Jonckheere
> Sent: Thursday, June 26, 2003 5:56 PM
> To: dev...@li...
> Subject: [Dev-C++] Help!!
>
>
> Dear all,
>
> As a beginner, I really would appreciate your help! I am
> trying to work with
> Xite for image processing, actually I try to threshold
> images. I have the
> code in C++ for unsigned byte images, but mine are unsigned
> short (16 bits),
> so I have a problem..
No intention to offend you but the term unsigned byte sounds a bit stupid.
Perhaps you mean unsigned char?
> I really need to keep the 16-bits, so I
> need to change
> the code..
I do not understand, you want to use 16-bit bytes? In a 8-bit byte system
you can create a type which includes 16 continuous bits in the style:
struct f16
{
==> unsigned char bits[2];
};
To add checking how many bits unsigned char has, and act accordingly:
#include <limits.h>
/* ... */
struct f16
{
unsigned char bits[CHAR_BIT/8];
};
> Does anybody knows what IBAND as a variable is??
I don't. Probably it is some typedef defined in one of those header files
used.
Ioannis Vranos
* Programming pages: http://www.noicys.freeurl.com
* Alternative URL 1: http://run.to/noicys
* Alternative URL 2: http://www.noicys.cjb.net
|