課程
/前端開(kāi)發(fā)
/Html5
/炫麗的倒計(jì)時(shí)效果Canvas繪圖與動(dòng)畫基礎(chǔ)
在哪能下載這個(gè)文件
2017-03-09
源自:炫麗的倒計(jì)時(shí)效果Canvas繪圖與動(dòng)畫基礎(chǔ) 3-1
正在回答
我也沒(méi)找到, 自己按照?qǐng)D片生成了一個(gè), 看看能否幫助你
var?digit?=?[ ??//?0 ??[ ????[0,0,1,1,1,0,0],[0,1,1,0,1,1,0],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[0,1,1,0,1,1,0],[0,0,1,1,1,0,0] ??],? ??//?1 ??[ ????[0,0,0,1,1,0,0],[0,1,1,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[0,0,0,1,1,0,0],[1,1,1,1,1,1,1] ??], ??//?2 ??[ ????[0,1,1,1,1,0,0],[1,1,0,0,0,1,1],[0,0,0,0,0,1,1],[0,0,0,0,1,1,0],[0,0,0,1,1,0,0],[0,0,1,1,0,0,0],[0,1,1,0,0,0,0],[1,1,0,0,0,0,0],[1,1,0,0,0,1,1],[1,1,1,1,1,1,1] ??], ??//?3 ??[ ????[1,1,1,1,1,1,1],[0,0,0,0,0,1,1],[0,0,0,0,1,1,0],[0,0,0,1,1,0,0],[0,0,1,1,1,0,0],[0,0,0,0,1,1,0],[0,0,0,0,0,1,1],[0,0,0,0,0,1,1],[1,1,0,0,0,1,1],[0,0,1,1,1,1,0] ??], ??//?4 ??[ ????[0,0,0,0,1,1,0],[0,0,0,1,1,1,0],[0,0,1,1,1,1,0],[0,1,1,0,1,1,0],[1,1,0,0,1,1,0],[1,1,1,1,1,1,1],[0,0,0,0,1,1,0],[0,0,0,0,1,1,0],[0,0,0,0,1,1,0],[0,0,0,1,1,1,1] ??], ??//?5 ??[ ????[1,1,1,1,1,1,1],[1,1,0,0,0,0,0],[1,1,0,0,0,0,0],[1,1,1,1,1,1,0],[0,0,0,0,0,1,1],[0,0,0,0,0,1,1],[0,0,0,0,0,1,1],[0,0,0,0,0,1,1],[1,1,0,0,0,1,1],[0,1,1,1,1,1,0] ??], ??//?6 ??[ ????[0,0,0,0,1,1,0],[0,0,1,1,0,0,0],[0,1,1,0,0,0,0],[1,1,0,0,0,0,0],[1,1,0,1,1,1,0],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[0,1,1,1,1,1,0] ??], ??//?7 ??[ ????[1,1,1,1,1,1,1],[1,1,0,0,0,1,1],[0,0,0,0,1,1,0],[0,0,0,1,1,0,0],[0,0,1,1,0,0,0],[0,0,1,1,0,0,0],[0,0,1,1,0,0,0],[0,0,1,1,0,0,0],[0,0,1,1,0,0,0],[0,0,1,1,0,0,0] ??], ??//?8 ??[ ????[0,1,1,1,1,1,0],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[0,0,1,1,1,1,0],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[0,1,1,1,1,1,0] ??], ??//?9 ??[ ????[0,1,1,1,1,1,0],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[1,1,0,0,0,1,1],[0,1,1,1,0,1,1],[0,0,0,0,0,1,1],[0,0,0,0,1,1,0],[0,0,0,1,1,0,0],[0,0,1,1,0,0,0],[0,1,1,0,0,0,0] ??], ??//?: ??[ ????[0,0,0,0], ????[0,0,0,0], ????[0,1,1,0], ????[0,1,1,0], ????[0,0,0,0], ????[0,0,0,0], ????[0,1,1,0], ????[0,1,1,0], ????[0,0,0,0], ????[0,0,0,0] ??] ];
慕前端2924538 提問(wèn)者
或者你用下面的代碼自己生成一套
<!DOCTYPE?html> <html> ????<head> ????????<meta?charset="utf-8"> ????????<meta?name="viewport"?content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/> ????????<meta?name="format-detection"?content="telephone=no,email=no,date=no,address=no"> ????????<title>點(diǎn)陣數(shù)字生成</title> ????????<style> ????????????body?{ ????????????} ????????????.active?{ ????????????????background:?#F00; ????????????} ????????????table?{width:100%;} ????????????td?{height:2em;?text-align:center;?vertical-align:middle;} ????????</style> ????</head> ????<body> ????????<table?border="1"> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????????<tr> ????????????????<td>1</td> ????????????????<td>2</td> ????????????????<td>3</td> ????????????????<td>4</td> ????????????????<td>5</td> ????????????????<td>6</td> ????????????????<td>7</td> ????????????</tr> ????????</table> ????????<div?style="padding:1em;?background:#CDFE67;?text-align:center;?color:#FFF;">清空</div> ????????<p?style="padding:1em;?background:#04F;?text-align:center;?color:#FFF;">生成</p> ????</body> ????<script?type="text/javascript"?src="./script/jquery-2.1.0.js"></script> ????<script?type="text/javascript"> ??????apiready?=?function()?{ ????????$j('td').click(function(){ ????????????$j(this).toggleClass('active'); ????????}); ????????$j('div').click(function(){ ????????????$j('td').removeClass('active'); ????????}); ????????$j('p').click(function(){ ????????????var?arr?=?[]; ????????????$j('table?tr').each(function(){ ????????????????var?trArr?=?[]; ????????????????$j(this).find('td').each(function(){ ????????????????????trArr.push($j(this).hasClass('active')?1:0); ????????????????}); ????????????????arr.push(trArr); ????????????}); ????????????console.log(JSON.stringify(arr)); ????????}); ??????}; ????</script> </html>
舉報(bào)
學(xué)習(xí)HTML5中最激動(dòng)人心的技術(shù)Canvas,徹底釋放自己的創(chuàng)造力
1 回答代碼在哪里下載???
2 回答當(dāng)另外一個(gè)js文件需要用digit的時(shí)候,需要在該js文件中引用digit這個(gè)js文件嗎
1 回答哪里下載源碼啊
3 回答要下載什么軟件
1 回答兩個(gè)html文件分別放一個(gè)canvas,用同一個(gè)js文件,第二個(gè)html文件的canvas畫不出畫是咋回事?
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購(gòu)課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2017-03-11
我也沒(méi)找到, 自己按照?qǐng)D片生成了一個(gè), 看看能否幫助你
2017-03-11
或者你用下面的代碼自己生成一套