/**
* Convert an int into its little-endian byte string representation.
*
* @param array the array in which to store the byte string.
* @param offset the offset in the array where the string will start.
* @param value the value to convert.
*/
public static void bytesFromInt(byte[] array, int offset, int value) {
array[offset+0] = (byte) ((value>>0) &0xFF);
array[offset+1] = (byte) ((value>>8) &0xFF);
array[offset+2] = (byte) ((value>>16)&0xFF);
array[offset+3] = (byte) ((value>>24)&0xFF);
}
Subscribe to:
Post Comments (Atom)
Carlo Cipolla's Laws of Stupidity
"By creating a graph of Cipolla's two factors, we obtain four groups of people. Helpless people contribute to society but are...
-
To install pngwrite we need to install to helper library before we install pngwriter. 1. libpng 2. freetype2 We can use fink or macport to i...
-
"By creating a graph of Cipolla's two factors, we obtain four groups of people. Helpless people contribute to society but are...
-
Use 'Disk Utility' application to format the USB drive in MS-DOS (FAT) format Download the windows ISO file from the Windows websit...
No comments:
Post a Comment