CSDN博客

img UglyBean

无组件的生成图形验证码

发表于2004/9/16 15:36:00  1017人阅读

分类: 技术文章

无组件的图形生成--XBM图形生成器(可用于生成图形验证码)

使用方法:
1、将以下内容保存为xbmgen.asp
2、"xbmgen.asp?sourcestr=1233423544353">


<%@?language="Javascript"%>
<%
/*
圪圪编写的XBM图形生成器,仅供参考!
圪圪原创·版权没有·随便转载

喜欢的话告诉我一声:eglic@etang.com?/?QQ:433649
*/
var?SourceStr=""+Request.QueryString("SourceStr")+"";
%>
<%
function?RevertByte(x)?//字节翻转函数
{
var?Out;
var?Tmp,Dst;
Out=0;
for(var?i=0;i<8;i++)
{
Tmp=Math.pow(2,i);
Dst=Math.pow(2,8-i);
if(x?&?Tmp)?Out|=Dst;
}
return?Out;
}
function?ToHexString(i)
{
var?Out;
i=RevertByte(i);?//将点阵翻转
Out=i.toString(16);
if(Out.length==1)
Out="0"+Out;
return?Out;
}

var?FontBits=new?Array();
var?ImagePixelWidth,ImagePixelHeight,ImageCharWidth,ImageCharHeight;
var?ImageInfoStr;
//Ascii字体点阵,用C编程从UCDOS7.0里面提取出来的
FontBits[0]=new?Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
FontBits[1]=new?Array(0,0,126,129,165,129,129,189,153,129,129,126,0,0,0,0);
FontBits[2]=new?Array(0,0,126,255,219,255,255,195,231,255,255,126,0,0,0,0);
FontBits[3]=new?Array(0,0,0,0,108,254,254,254,254,124,56,16,0,0,0,0);
FontBits[4]=new?Array(0,0,0,0,16,56,124,254,124,56,16,0,0,0,0,0);
FontBits[5]=new?Array(0,0,0,24,60,60,231,231,231,24,24,60,0,0,0,0);
FontBits[6]=new?Array(0,0,0,24,60,126,255,255,126,24,24,60,0,0,0,0);
FontBits[7]=new?Array(0,0,0,0,0,0,24,60,60,24,0,0,0,0,0,0);
FontBits[8]=new?Array(255,255,255,255,255,255,231,195,195,231,255,255,255,255,255,255);
FontBits[9]=new?Array(0,0,0,0,0,60,102,66,66,102,60,0,0,0,0,0);
FontBits[10]=new?Array(255,255,255,255,255,195,153,189,189,153,195,255,255,255,255,255);
FontBits[11]=new?Array(0,0,30,14,26,50,120,204,204,204,204,120,0,0,0,0);
FontBits[12]=new?Array(0,0,60,102,102,102,102,60,24,126,24,24,0,0,0,0);
FontBits[13]=new?Array(0,0,63,51,63,48,48,48,48,112,240,224,0,0,0,0);
FontBits[14]=new?Array(0,0,127,99,127,99,99,99,99,103,231,230,192,0,0,0);
FontBits[15]=new?Array(0,0,0,24,24,219,60,231,60,219,24,24,0,0,0,0);
FontBits[16]=new?Array(0,128,192,224,240,248,254,248,240,224,192,128,0,0,0,0);
FontBits[17]=new?Array(0,2,6,14,30,62,254,62,30,14,6,2,0,0,0,0);
FontBits[18]=new?Array(0,0,24,60,126,24,24,24,126,60,24,0,0,0,0,0);
FontBits[19]=new?Array(0,0,102,102,102,102,102,102,102,0,102,102,0,0,0,0);
FontBits[20]=new?Array(0,0,127,219,219,219,123,27,27,27,27,27,0,0,0,0);
FontBits[21]=new?Array(0,124,198,96,56,108,198,198,108,56,12,198,124,0,0,0);
FontBits[22]=new?Array(0,0,0,0,0,0,0,0,254,254,254,254,0,0,0,0);
FontBits[23]=new?Array(0,0,24,60,126,24,24,24,126,60,24,126,0,0,0,0);
FontBits[24]=new?Array(0,0,24,60,126,24,24,24,24,24,24,24,0,0,0,0);
FontBits[25]=new?Array(0,0,24,24,24,24,24,24,24,126,60,24,0,0,0,0);
FontBits[26]=new?Array(0,0,0,0,0,24,12,254,12,24,0,0,0,0,0,0);
FontBits[27]=new?Array(0,0,0,0,0,48,96,254,96,48,0,0,0,0,0,0);
FontBits[28]=new?Array(0,0,0,0,0,0,192,192,192,254,0,0,0,0,0,0);
FontBits[29]=new?Array(0,0,0,0,0,40,108,254,108,40,0,0,0,0,0,0);
FontBits[30]=new?Array(0,0,0,0,16,56,56,124,124,254,254,0,0,0,0,0);
FontBits[31]=new?Array(0,0,0,0,254,254,124,124,56,56,16,0,0,0,0,0);
FontBits[32]=new?Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
FontBits[33]=new?Array(0,0,24,60,60,60,24,24,24,0,24,24,0,0,0,0);
FontBits[34]=new?Array(0,102,102,102,36,0,0,0,0,0,0,0,0,0,0,0);
FontBits[35]=new?Array(0,0,0,108,108,254,108,108,108,254,108,108,0,0,0,0);
FontBits[36]=new?Array(24,24,124,198,194,192,124,6,6,134,198,124,24,24,0,0);
FontBits[37]=new?Array(0,0,0,0,194,198,12,24,48,96,198,134,0,0,0,0);
FontBits[38]=new?Array(0,0,56,108,108,56,118,220,204,204,204,118,0,0,0,0);
FontBits[39]=new?Array(0,48,48,48,96,0,0,0,0,0,0,0,0,0,0,0);
FontBits[40]=new?Array(0,0,12,24,48,48,48,48,48,48,24,12,0,0,0,0);
FontBits[41]=new?Array(0,0,48,24,12,12,12,12,12,12,24,48,0,0,0,0);
FontBits[42]=new?Array(0,0,0,0,0,102,60,255,60,102,0,0,0,0,0,0);
FontBits[43]=new?Array(0,0,0,0,0,24,24,126,24,24,0,0,0,0,0,0);
FontBits[44]=new?Array(0,0,0,0,0,0,0,0,0,24,24,24,48,0,0,0);
FontBits[45]=new?Array(0,0,0,0,0,0,0,254,0,0,0,0,0,0,0,0);
FontBits[46]=new?Array(0,0,0,0,0,0,0,0,0,0,24,24,0,0,0,0);
FontBits[47]=new?Array(0,0,0,0,2,6,12,24,48,96,192,128,0,0,0,0);
FontBits[48]=new?Array(0,0,56,108,198,198,214,214,198,198,108,56,0,0,0,0);
FontBits[49]=new?Array(0,0,24,56,120,24,24,24,24,24,24,126,0,0,0,0);
FontBits[50]=new?Array(0,0,124,198,6,12,24,48,96,192,198,254,0,0,0,0);
FontBits[51]=new?Array(0,0,124,198,6,6,60,6,6,6,198,124,0,0,0,0);
FontBits[52]=new?Array(0,0,12,28,60,108,204,254,12,12,12,30,0,0,0,0);
FontBits[53]=new?Array(0,0,254,192,192,192,252,6,6,6,198,124,0,0,0,0);
FontBits[54]=new?Array(0,0,56,96,192,192,252,198,198,198,198,124,0,0,0,0);
FontBits[55]=new?Array(0,0,254,198,6,6,12,24,48,48,48,48,0,0,0,0);
FontBits[56]=new?Array(0,0,124,198,198,198,124,198,198,198,198,124,0,0,0,0);
FontBits[57]=new?Array(0,0,124,198,198,198,126,6,6,6,12,120,0,0,0,0);
FontBits[58]=new?Array(0,0,0,0,24,24,0,0,0,24,24,0,0,0,0,0);
FontBits[59]=new?Array(0,0,0,0,24,24,0,0,0,24,24,48,0,0,0,0);
FontBits[60]=new?Array(0,0,0,6,12,24,48,96,48,24,12,6,0,0,0,0);
FontBits[61]=new?Array(0,0,0,0,0,126,0,0,126,0,0,0,0,0,0,0);
FontBits[62]=new?Array(0,0,0,96,48,24,12,6,12,24,48,96,0,0,0,0);
FontBits[63]=new?Array(0,0,124,198,198,12,24,24,24,0,24,24,0,0,0,0);
FontBits[64]=new?Array(0,0,0,124,198,198,222,222,222,220,192,124,0,0,0,0);
FontBits[65]=new?Array(0,0,16,56,108,198,198,254,198,198,198,198,0,0,0,0);
FontBits[66]=new?Array(0,0,252,102,102,102,124,102,102,102,102,252,0,0,0,0);
FontBits[67]=new?Array(0,0,60,102,194,192,192,192,192,194,102,60,0,0,0,0);
FontBits[68]=new?Array(0,0,248,108,102,102,102,102,102,102,108,248,0,0,0,0);
FontBits[69]=new?Array(0,0,254,102,98,104,120,104,96,98,102,254,0,0,0,0);
FontBits[70]=new?Array(0,0,254,102,98,104,120,104,96,96,96,240,0,0,0,0);
FontBits[71]=new?Array(0,0,60,102,194,192,192,222,198,198,102,58,0,0,0,0);
FontBits[72]=new?Array(0,0,198,198,198,198,254,198,198,198,198,198,0,0,0,0);
FontBits[73]=new?Array(0,0,60,24,24,24,24,24,24,24,24,60,0,0,0,0);
FontBits[74]=new?Array(0,0,30,12,12,12,12,12,204,204,204,120,0,0,0,0);
FontBits[75]=new?Array(0,0,230,102,102,108,120,120,108,102,102,230,0,0,0,0);
FontBits[76]=new?Array(0,0,240,96,96,96,96,96,96,98,102,254,0,0,0,0);
FontBits[77]=new?Array(0,0,198,238,254,254,214,198,198,198,198,198,0,0,0,0);
FontBits[78]=new?Array(0,0,198,230,246,254,222,206,198,198,198,198,0,0,0,0);
FontBits[79]=new?Array(0,0,124,198,198,198,198,198,198,198,198,124,0,0,0,0);
FontBits[80]=new?Array(0,0,252,102,102,102,124,96,96,96,96,240,0,0,0,0);
FontBits[81]=new?Array(0,0,124,198,198,198,198,198,198,214,222,124,12,14,0,0);
FontBits[82]=new?Array(0,0,252,102,102,102,124,108,102,102,102,230,0,0,0,0);
FontBits[83]=new?Array(0,0,124,198,198,96,56,12,6,198,198,124,0,0,0,0);
FontBits[84]=new?Array(0,0,126,126,90,24,24,24,24,24,24,60,0,0,0,0);
FontBits[85]=new?Array(0,0,198,198,198,198,198,198,198,198,198,124,0,0,0,0);
FontBits[86]=new?Array(0,0,198,198,198,198,198,198,198,108,56,16,0,0,0,0);
FontBits[87]=new?Array(0,0,198,198,198,198,214,214,214,254,238,108,0,0,0,0);
FontBits[88]=new?Array(0,0,198,198,108,124,56,56,124,108,198,198,0,0,0,0);
FontBits[89]=new?Array(0,0,102,102,102,102,60,24,24,24,24,60,0,0,0,0);
FontBits[90]=new?Array(0,0,254,198,134,12,24,48,96,194,198,254,0,0,0,0);
FontBits[91]=new?Array(0,0,60,48,48,48,48,48,48,48,48,60,0,0,0,0);
FontBits[92]=new?Array(0,0,0,128,192,224,112,56,28,14,6,2,0,0,0,0);
FontBits[93]=new?Array(0,0,60,12,12,12,12,12,12,12,12,60,0,0,0,0);
FontBits[94]=new?Array(16,56,108,198,0,0,0,0,0,0,0,0,0,0,0,0);
FontBits[95]=new?Array(0,0,0,0,0,0,0,0,0,0,0,0,0,255,0,0);
FontBits[96]=new?Array(48,48,24,0,0,0,0,0,0,0,0,0,0,0,0,0);
FontBits[97]=new?Array(0,0,0,0,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[98]=new?Array(0,0,224,96,96,120,108,102,102,102,102,124,0,0,0,0);
FontBits[99]=new?Array(0,0,0,0,0,124,198,192,192,192,198,124,0,0,0,0);
FontBits[100]=new?Array(0,0,28,12,12,60,108,204,204,204,204,118,0,0,0,0);
FontBits[101]=new?Array(0,0,0,0,0,124,198,254,192,192,198,124,0,0,0,0);
FontBits[102]=new?Array(0,0,56,108,100,96,240,96,96,96,96,240,0,0,0,0);
FontBits[103]=new?Array(0,0,0,0,0,118,204,204,204,204,204,124,12,204,120,0);
FontBits[104]=new?Array(0,0,224,96,96,108,118,102,102,102,102,230,0,0,0,0);
FontBits[105]=new?Array(0,0,24,24,0,56,24,24,24,24,24,60,0,0,0,0);
FontBits[106]=new?Array(0,0,6,6,0,14,6,6,6,6,6,6,102,102,60,0);
FontBits[107]=new?Array(0,0,224,96,96,102,108,120,120,108,102,230,0,0,0,0);
FontBits[108]=new?Array(0,0,56,24,24,24,24,24,24,24,24,60,0,0,0,0);
FontBits[109]=new?Array(0,0,0,0,0,236,254,214,214,214,214,198,0,0,0,0);
FontBits[110]=new?Array(0,0,0,0,0,220,102,102,102,102,102,102,0,0,0,0);
FontBits[111]=new?Array(0,0,0,0,0,124,198,198,198,198,198,124,0,0,0,0);
FontBits[112]=new?Array(0,0,0,0,0,220,102,102,102,102,102,124,96,96,240,0);
FontBits[113]=new?Array(0,0,0,0,0,118,204,204,204,204,204,124,12,12,30,0);
FontBits[114]=new?Array(0,0,0,0,0,220,118,102,96,96,96,240,0,0,0,0);
FontBits[115]=new?Array(0,0,0,0,0,124,198,96,56,12,198,124,0,0,0,0);
FontBits[116]=new?Array(0,0,16,48,48,252,48,48,48,48,54,28,0,0,0,0);
FontBits[117]=new?Array(0,0,0,0,0,204,204,204,204,204,204,118,0,0,0,0);
FontBits[118]=new?Array(0,0,0,0,0,102,102,102,102,102,60,24,0,0,0,0);
FontBits[119]=new?Array(0,0,0,0,0,198,198,214,214,214,254,108,0,0,0,0);
FontBits[120]=new?Array(0,0,0,0,0,198,108,56,56,56,108,198,0,0,0,0);
FontBits[121]=new?Array(0,0,0,0,0,198,198,198,198,198,198,126,6,12,248,0);
FontBits[122]=new?Array(0,0,0,0,0,254,204,24,48,96,198,254,0,0,0,0);
FontBits[123]=new?Array(0,0,14,24,24,24,112,24,24,24,24,14,0,0,0,0);
FontBits[124]=new?Array(0,0,24,24,24,24,0,24,24,24,24,24,0,0,0,0);
FontBits[125]=new?Array(0,0,112,24,24,24,14,24,24,24,24,112,0,0,0,0);
FontBits[126]=new?Array(0,0,118,220,0,0,0,0,0,0,0,0,0,0,0,0);
FontBits[127]=new?Array(0,0,0,0,16,56,108,198,198,198,254,0,0,0,0,0);
FontBits[128]=new?Array(0,0,60,102,194,192,192,192,194,102,60,12,6,124,0,0);
FontBits[129]=new?Array(0,0,204,0,0,204,204,204,204,204,204,118,0,0,0,0);
FontBits[130]=new?Array(0,12,24,48,0,124,198,254,192,192,198,124,0,0,0,0);
FontBits[131]=new?Array(0,16,56,108,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[132]=new?Array(0,0,204,0,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[133]=new?Array(0,96,48,24,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[134]=new?Array(0,56,108,56,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[135]=new?Array(0,0,0,0,60,102,96,96,102,60,12,6,60,0,0,0);
FontBits[136]=new?Array(0,16,56,108,0,124,198,254,192,192,198,124,0,0,0,0);
FontBits[137]=new?Array(0,0,198,0,0,124,198,254,192,192,198,124,0,0,0,0);
FontBits[138]=new?Array(0,96,48,24,0,124,198,254,192,192,198,124,0,0,0,0);
FontBits[139]=new?Array(0,0,102,0,0,56,24,24,24,24,24,60,0,0,0,0);
FontBits[140]=new?Array(0,24,60,102,0,56,24,24,24,24,24,60,0,0,0,0);
FontBits[141]=new?Array(0,96,48,24,0,56,24,24,24,24,24,60,0,0,0,0);
FontBits[142]=new?Array(0,198,0,16,56,108,198,198,254,198,198,198,0,0,0,0);
FontBits[143]=new?Array(56,108,56,0,56,108,198,198,254,198,198,198,0,0,0,0);
FontBits[144]=new?Array(24,48,96,0,254,102,96,124,96,96,102,254,0,0,0,0);
FontBits[145]=new?Array(0,0,0,0,0,204,118,54,126,216,216,110,0,0,0,0);
FontBits[146]=new?Array(0,0,62,108,204,204,254,204,204,204,204,206,0,0,0,0);
FontBits[147]=new?Array(0,16,56,108,0,124,198,198,198,198,198,124,0,0,0,0);
FontBits[148]=new?Array(0,0,198,0,0,124,198,198,198,198,198,124,0,0,0,0);
FontBits[149]=new?Array(0,96,48,24,0,124,198,198,198,198,198,124,0,0,0,0);
FontBits[150]=new?Array(0,48,120,204,0,204,204,204,204,204,204,118,0,0,0,0);
FontBits[151]=new?Array(0,96,48,24,0,204,204,204,204,204,204,118,0,0,0,0);
FontBits[152]=new?Array(0,0,198,0,0,198,198,198,198,198,198,126,6,12,120,0);
FontBits[153]=new?Array(0,198,0,124,198,198,198,198,198,198,198,124,0,0,0,0);
FontBits[154]=new?Array(0,198,0,198,198,198,198,198,198,198,198,124,0,0,0,0);
FontBits[155]=new?Array(0,24,24,60,102,96,96,96,102,60,24,24,0,0,0,0);
FontBits[156]=new?Array(0,56,108,100,96,240,96,96,96,96,230,252,0,0,0,0);
FontBits[157]=new?Array(0,0,102,102,60,24,126,24,126,24,24,24,0,0,0,0);
FontBits[158]=new?Array(0,248,204,204,248,196,204,222,204,204,204,198,0,0,0,0);
FontBits[159]=new?Array(0,14,27,24,24,24,126,24,24,24,24,24,216,112,0,0);
FontBits[160]=new?Array(0,24,48,96,0,120,12,124,204,204,204,118,0,0,0,0);
FontBits[161]=new?Array(0,12,24,48,0,56,24,24,24,24,24,60,0,0,0,0);
FontBits[162]=new?Array(0,24,48,96,0,124,198,198,198,198,198,124,0,0,0,0);
FontBits[163]=new?Array(0,24,48,96,0,204,204,204,204,204,204,118,0,0,0,0);
FontBits[164]=new?Array(0,0,118,220,0,220,102,102,102,102,102,102,0,0,0,0);
FontBits[165]=new?Array(118,220,0,198,230,246,254,222,206,198,198,198,0,0,0,0);
FontBits[166]=new?Array(0,60,108,108,62,0,126,0,0,0,0,0,0,0,0,0);
FontBits[167]=new?Array(0,56,108,108,56,0,124,0,0,0,0,0,0,0,0,0);
FontBits[168]=new?Array(0,0,48,48,0,48,48,96,192,198,198,124,0,0,0,0);
FontBits[169]=new?Array(0,0,0,0,0,0,254,192,192,192,192,0,0,0,0,0);
FontBits[170]=new?Array(0,0,0,0,0,0,254,6,6,6,6,0,0,0,0,0);
FontBits[171]=new?Array(0,192,192,194,198,204,24,48,96,220,134,12,24,62,0,0);
FontBits[172]=new?Array(0,192,192,194,198,204,24,48,102,206,158,62,6,6,0,0);
FontBits[173]=new?Array(0,0,24,24,0,24,24,24,60,60,60,24,0,0,0,0);
FontBits[174]=new?Array(0,0,0,0,0,54,108,216,108,54,0,0,0,0,0,0);
FontBits[175]=new?Array(0,0,0,0,0,216,108,54,108,216,0,0,0,0,0,0);
FontBits[176]=new?Array(17,68,17,68,17,68,17,68,17,68,17,68,17,68,17,68);
FontBits[177]=new?Array(85,170,85,170,85,170,85,170,85,170,85,170,85,170,85,170);
FontBits[178]=new?Array(221,119,221,119,221,119,221,119,221,119,221,119,221,119,221,119);
FontBits[179]=new?Array(24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24);
FontBits[180]=new?Array(24,24,24,24,24,24,24,248,24,24,24,24,24,24,24,24);
FontBits[181]=new?Array(24,24,24,24,24,248,24,248,24,24,24,24,24,24,24,24);
FontBits[182]=new?Array(54,54,54,54,54,54,54,246,54,54,54,54,54,54,54,54);
FontBits[183]=new?Array(0,0,0,0,0,0,0,254,54,54,54,54,54,54,54,54);
FontBits[184]=new?Array(0,0,0,0,0,248,24,248,24,24,24,24,24,24,24,24);
FontBits[185]=new?Array(54,54,54,54,54,246,6,246,54,54,54,54,54,54,54,54);
FontBits[186]=new?Array(54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54);
FontBits[187]=new?Array(0,0,0,0,0,254,6,246,54,54,54,54,54,54,54,54);
FontBits[188]=new?Array(54,54,54,54,54,246,6,254,0,0,0,0,0,0,0,0);
FontBits[189]=new?Array(54,54,54,54,54,54,54,254,0,0,0,0,0,0,0,0);
FontBits[190]=new?Array(24,24,24,24,24,248,24,248,0,0,0,0,0,0,0,0);
FontBits[191]=new?Array(0,0,0,0,0,0,0,248,24,24,24,24,24,24,24,24);
FontBits[192]=new?Array(24,24,24,24,24,24,24,31,0,0,0,0,0,0,0,0);
FontBits[193]=new?Array(24,24,24,24,24,24,24,255,0,0,0,0,0,0,0,0);
FontBits[194]=new?Array(0,0,0,0,0,0,0,255,24,24,24,24,24,24,24,24);
FontBits[195]=new?Array(24,24,24,24,24,24,24,31,24,24,24,24,24,24,24,24);
FontBits[196]=new?Array(0,0,0,0,0,0,0,255,0,0,0,0,0,0,0,0);
FontBits[197]=new?Array(24,24,24,24,24,24,24,255,24,24,24,24,24,24,24,24);
FontBits[198]=new?Array(24,24,24,24,24,31,24,31,24,24,24,24,24,24,24,24);
FontBits[199]=new?Array(54,54,54,54,54,54,54,55,54,54,54,54,54,54,54,54);
FontBits[200]=new?Array(54,54,54,54,54,55,48,63,0,0,0,0,0,0,0,0);
FontBits[201]=new?Array(0,0,0,0,0,63,48,55,54,54,54,54,54,54,54,54);
FontBits[202]=new?Array(54,54,54,54,54,247,0,255,0,0,0,0,0,0,0,0);
FontBits[203]=new?Array(0,0,0,0,0,255,0,247,54,54,54,54,54,54,54,54);
FontBits[204]=new?Array(54,54,54,54,54,55,48,55,54,54,54,54,54,54,54,54);
FontBits[205]=new?Array(0,0,0,0,0,255,0,255,0,0,0,0,0,0,0,0);
FontBits[206]=new?Array(54,54,54,54,54,247,0,247,54,54,54,54,54,54,54,54);
FontBits[207]=new?Array(24,24,24,24,24,255,0,255,0,0,0,0,0,0,0,0);
FontBits[208]=new?Array(54,54,54,54,54,54,54,255,0,0,0,0,0,0,0,0);
FontBits[209]=new?Array(0,0,0,0,0,255,0,255,24,24,24,24,24,24,24,24);
FontBits[210]=new?Array(0,0,0,0,0,0,0,255,54,54,54,54,54,54,54,54);
FontBits[211]=new?Array(54,54,54,54,54,54,54,63,0,0,0,0,0,0,0,0);
FontBits[212]=new?Array(24,24,24,24,24,31,24,31,0,0,0,0,0,0,0,0);
FontBits[213]=new?Array(0,0,0,0,0,31,24,31,24,24,24,24,24,24,24,24);
FontBits[214]=new?Array(0,0,0,0,0,0,0,63,54,54,54,54,54,54,54,54);
FontBits[215]=new?Array(54,54,54,54,54,54,54,255,54,54,54,54,54,54,54,54);
FontBits[216]=new?Array(24,24,24,24,24,255,24,255,24,24,24,24,24,24,24,24);
FontBits[217]=new?Array(24,24,24,24,24,24,24,248,0,0,0,0,0,0,0,0);
FontBits[218]=new?Array(0,0,0,0,0,0,0,31,24,24,24,24,24,24,24,24);
FontBits[219]=new?Array(255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255);
FontBits[220]=new?Array(0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255);
FontBits[221]=new?Array(240,240,240,240,240,240,240,240,240,240,240,240,240,240,240,240);
FontBits[222]=new?Array(15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15);
FontBits[223]=new?Array(255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,0);
FontBits[224]=new?Array(0,0,0,0,0,118,220,216,216,216,220,118,0,0,0,0);
FontBits[225]=new?Array(0,0,120,204,204,204,216,204,198,198,198,204,0,0,0,0);
FontBits[226]=new?Array(0,0,254,198,198,192,192,192,192,192,192,192,0,0,0,0);
FontBits[227]=new?Array(0,0,0,0,254,108,108,108,108,108,108,108,0,0,0,0);
FontBits[228]=new?Array(0,0,0,254,198,96,48,24,48,96,198,254,0,0,0,0);
FontBits[229]=new?Array(0,0,0,0,0,126,216,216,216,216,216,112,0,0,0,0);
FontBits[230]=new?Array(0,0,0,0,102,102,102,102,102,124,96,96,192,0,0,0);
FontBits[231]=new?Array(0,0,0,0,118,220,24,24,24,24,24,24,0,0,0,0);
FontBits[232]=new?Array(0,0,0,126,24,60,102,102,102,60,24,126,0,0,0,0);
FontBits[233]=new?Array(0,0,0,56,108,198,198,254,198,198,108,56,0,0,0,0);
FontBits[234]=new?Array(0,0,56,108,198,198,198,108,108,108,108,238,0,0,0,0);
FontBits[235]=new?Array(0,0,30,48,24,12,62,102,102,102,102,60,0,0,0,0);
FontBits[236]=new?Array(0,0,0,0,0,126,219,219,219,126,0,0,0,0,0,0);
FontBits[237]=new?Array(0,0,0,3,6,126,219,219,243,126,96,192,0,0,0,0);
FontBits[238]=new?Array(0,0,28,48,96,96,124,96,96,96,48,28,0,0,0,0);
FontBits[239]=new?Array(0,0,0,124,198,198,198,198,198,198,198,198,0,0,0,0);
FontBits[240]=new?Array(0,0,0,0,254,0,0,254,0,0,254,0,0,0,0,0);
FontBits[241]=new?Array(0,0,0,0,24,24,126,24,24,0,0,255,0,0,0,0);
FontBits[242]=new?Array(0,0,0,48,24,12,6,12,24,48,0,126,0,0,0,0);
FontBits[243]=new?Array(0,0,0,12,24,48,96,48,24,12,0,126,0,0,0,0);
FontBits[244]=new?Array(0,0,14,27,27,24,24,24,24,24,24,24,24,24,24,24);
FontBits[245]=new?Array(24,24,24,24,24,24,24,24,216,216,216,112,0,0,0,0);
FontBits[246]=new?Array(0,0,0,0,24,24,0,126,0,24,24,0,0,0,0,0);
FontBits[247]=new?Array(0,0,0,0,0,118,220,0,118,220,0,0,0,0,0,0);
FontBits[248]=new?Array(0,56,108,108,56,0,0,0,0,0,0,0,0,0,0,0);
FontBits[249]=new?Array(0,0,0,0,0,0,0,24,24,0,0,0,0,0,0,0);
FontBits[250]=new?Array(0,0,0,0,0,0,0,0,24,0,0,0,0,0,0,0);
FontBits[251]=new?Array(0,15,12,12,12,12,12,236,108,108,60,28,0,0,0,0);
FontBits[252]=new?Array(0,216,108,108,108,108,108,0,0,0,0,0,0,0,0,0);
FontBits[253]=new?Array(0,112,216,48,96,200,248,0,0,0,0,0,0,0,0,0);
FontBits[254]=new?Array(0,0,0,0,124,124,124,124,124,124,124,0,0,0,0,0);
FontBits[255]=new?Array(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);
/////////////////////////////////////////////////////////////////////
ImageCharWidth=SourceStr.length;
ImageCharHeight=1;
ImagePixelWidth=ImageCharWidth*8;?//图象宽度为字符个数x8
ImagePixelHeight=16;?//图象高度目前只能是固定的16像素高

ImageInfoStr="#define?XBM_width?"+ImagePixelWidth+"/n";?//生成文件头
ImageInfoStr=ImageInfoStr+"#define?XBM_height?"+ImagePixelHeight+"/n";
ImageInfoStr=ImageInfoStr+"static?char?XBM_bits[]={";
var?CharCode=new?Array();
var?iCnt,iCol;
for(iCnt=0;iCntCharCode[iCnt]=SourceStr.charCodeAt(iCnt)
for(iCnt=0;iCnt{
for(iCol=0;iCol{
if(iCnt!=ImagePixelHeight-1?||?iCol!=ImageCharWidth-1)
ImageInfoStr=ImageInfoStr+"0x"+ToHexString(FontBits[CharCode[iCol]][iCnt])+",";
else
ImageInfoStr=ImageInfoStr+"0x"+ToHexString(FontBits[CharCode[iCol]][iCnt]);
}
}
ImageInfoStr=ImageInfoStr+"};"

Response.ContentType="image/x-xbitmap";?//输出图象数据
Response.Write(ImageInfoStr);
%>
0 0

相关博文

我的热门文章

img
取 消
img