Re: using libjpeg
- From: Spoon <root@localhost>
- Date: Wed, 30 Jan 2008 23:33:00 +0100
Syren Baran wrote:
Spoon wrote:
Syren Baran wrote:
Pretty sure you'll want to use int's and not long's. The typically
used ARGB consists of 32 bits.
What size do you expect an int to be?
32 bits, though I know that's not guaranteed by C.
Right.
<quote>
A "plain" int object has the natural size suggested by the architecture of the execution environment (large enough to contain any value in the range INT_MIN to INT_MAX).
</quote>
* minimum value for an object of type int INT_MIN -32767
* maximum value for an object of type int INT_MAX +32767
(There are platforms where an int is only 16 bits wide. AFAIU, there
are also platforms where an int is 64 bits wide.)
BTW, which language are you talking about, I might be able to give
you a definite answer.
I was thinking of ISO/IEC 9899:1990.
What size do you expect a long int to be?
In C, at least as long as int.
Right.
<quote>
There are four signed integer types, designated as signed char, short int, int, and long int. In the list of signed integer types above, the range of values of each type is a subrange of the values of the next type in the list.
</quote>
* minimum value for an object of type long int LONG_MIN -2147483647
* maximum value for an object of type long int LONG_MAX +2147483647
(A long int is never less than 32 bits wide. There are platforms
where a long int is 64 bits wide.)
Given the above, I do not understand your comment that the OP should
use ints instead of long ints. Could you clarify?
Regards.
.
- Follow-Ups:
- Re: using libjpeg
- From: Syren Baran
- Re: using libjpeg
- References:
- using libjpeg
- From: oswald . harry
- Re: using libjpeg
- From: Syren Baran
- Re: using libjpeg
- From: Spoon
- Re: using libjpeg
- From: Syren Baran
- using libjpeg
- Prev by Date: Re: using libjpeg
- Next by Date: Re: Array bound read : pthread_exit
- Previous by thread: Re: using libjpeg
- Next by thread: Re: using libjpeg
- Index(es):
Relevant Pages
|