- echo "\t";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",";
- echo hd($fp),",",hd($fp),",\n";
+ $gOutput .= "Uint32 {$prefix}_{$i}_data[] = {\n";
+ for( $j = 0; $j + 16 < $size; $j += 16 )
+ {
+ $gOutput .= "\t";
+ $gOutput .= hd($fp).",".hd($fp).",";
+ $gOutput .= hd($fp).",".hd($fp).",\n";
+ }
+ $gOutput .= "\t";
+ for( ; $j+3 < $size; $j += 4 )
+ {
+ if( $j & 15 ) $gOutput .= ",";
+ $gOutput .= hd($fp);
+ }
+ if($j < $size) {
+ $tmp = "";
+ while($j ++ < $size)
+ $tmp .= fgetc($fp);
+ $tmp .= "\0\0\0";
+ $tmp = unpack("I", $tmp);
+ $gOutput .= "0x".dechex($tmp[1]);
+ }