a

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers splitData.h Source File

splitData.h

00001 /*intの数をchar型の欲しいbyte数に変換*/
00002 
00003 #ifndef __INCLEDED_SPRITDATA_H
00004 #define __INCLEDED_SPRITDATA_H
00005 
00006 void Intobyte(int wannaChange,int byte,char *chardata,int firstElement);
00007 //指定されたbyte数のchar型に分解.最初の配列に下八桁が入る。一番左に符号(正だと0,負だと1)。
00008 
00009 //例 wantChangeという変数の下23桁(3バイト)を、charnum[5]から順に入れたい。
00010 //    →Intobyte(wantChange,3,charnum,5);
00011 //これでcharnum[5]にwantChangeの下八桁,でcharnum[6]に下16桁、charnum[7]に下23桁が入り、charnum[7]の一番左に符号が入る。
00012 
00013 
00014 #endif