How to do things AI Noob vs. Pro
List biggest files Free Open Source: Swiss File Knifea command line
Depeche View
command line
free external tools,
cpp sources
articles |
sfk bin-to-src [...] infile outfile namePrefix create sourcefile containing a binary data block. the outfile will contain variable definitions beginning with namePrefix. options -java create java source code output, default is C. -class java: create a fully compilable class with a short demo source code how to write the data to a file. -pack C source: compress data with a simple RLE scheme. -hex C source: produce hex numbers instead of decimal. -append do not overwrite output, but append to it. -recsize=n java: define number of bytes per record used within the raw data. default is 500. higher values produce less records, which may help if you get a "code too large" error during java compile. further commands sfk clipsrc convert clipboard text to C style source code sfk clipphp convert clipboard text to PHP style source code sfk clipjava convert clipboard text to Java style source code ... add +toclip to copy converted result back to clipboard. examples sfk bin-to-src myimg.dat imgsrc.cpp img01 create C source code containing content from myimg.dat. sfk bin-to-src -java -class myimg.dat imgdata.java imgdata create a Java class "imgdata" with myimg.dat content. C++ example output: (reduced at "...") #define pic01_BLOCK_SIZE 1105 static unsigned char pic01_abRawBlock[1105] = { 255,216,255,224,0,16,74,70,73,70,0,1,1,1,0,96,0,96,0,0, 255,219,0,67,0,4,3,3,4,3,3,4,4,4,4,5,5,4,5,7,11,7,7,6,6, 7,14,10,10,8,11,16,14,17,17,16,14,16,15,18,20,26,22,18, ... 15,84,235,10,161,46,224,39,191,140,210,163,56,135,203, 255,217, }; Java example output: (reduced at "...") public static int pic01_BlockSize = 1105; static String pic01_RawBlock[] = { "\uffd8\uffe0\u0010\u4a46\u4946\u0001\u0101 ...", "\u3f02\ue4a9\ud54a\u2a65\u84b4\u8dde\ud7d4 ...", "\u581b\u06e2\ua9f2\u64e7\u56ac\u840d\u8419 ...", }; public static byte[] pic01_getBlock() { int iout=0, nblen=pic01_BlockSize; char atmp[] = new char[500]; byte aout[] = new byte[nblen]; for (int i=0; i sfk bin-to-src [...] infile outfile namePrefix create sourcefile containing a binary data block. the outfile will contain variable definitions beginning with namePrefix. options -java create java source code output, default is C. -class java: create a fully compilable class with a short demo source code how to write the data to a file. -pack C source: compress data with a simple RLE scheme. -hex C source: produce hex numbers instead of decimal. -append do not overwrite output, but append to it. -recsize=n java: define number of bytes per record used within the raw data. default is 500. higher values produce less records, which may help if you get a "code too large" error during java compile. further commands sfk clipsrc convert clipboard text to C style source code sfk clipphp convert clipboard text to PHP style source code sfk clipjava convert clipboard text to Java style source code ... add +toclip to copy converted result back to clipboard. examples sfk bin-to-src myimg.dat imgsrc.cpp img01 create C source code containing content from myimg.dat. sfk bin-to-src -java -class myimg.dat imgdata.java imgdata create a Java class "imgdata" with myimg.dat content. C++ example output: (reduced at "...") #define pic01_BLOCK_SIZE 1105 static unsigned char pic01_abRawBlock[1105] = { 255,216,255, 224,0,16,74,70,73,70,0,1,1,1,0,96,0,96,0, 0, 255,219,0,67,0,4,3,3,4,3,3,4,4,4,4,5, 5,4,5,7,11,7,7,6,6, 7,14,10,10,8,11,16, 14,17,17,16,14,16,15,18,20,26,22,18, ... 15,84,235,10,161,46,224,39,191,140,210, 163,56,135,203, 255,217, }; Java example output: (reduced at "...") public static int pic01_BlockSize = 1105; static String pic01_RawBlock[] = { "\uffd8\uffe0\u0010\u4a46\u4946\u0001\ u0101 ...", "\u3f02\ue4a9\ud54a\u2a65\ u84b4\u8dde\ud7d4 ...", "\u581b\u06e2\ ua9f2\u64e7\u56ac\u840d\u8419 ...", }; public static byte[] pic01_getBlock() { int iout=0, nblen=pic01_BlockSize; char atmp[] = new char[500]; byte aout[] = new byte[nblen]; for (int i=0; i you are viewing this page in mobile portrait mode with a limited layout. turn your device right, use a desktop browser or buy the sfk e-book for improved reading. sfk is a free open-source tool, running instantly without installation efforts. no DLL's, no registry changes - just get sfk.exe from the zip package and use it (binaries for windows, linux and mac are included).
the Daily Landscape image
|