第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定

星星這章實(shí)現(xiàn)不了

代碼實(shí)現(xiàn)不了效果

正在回答

1 回答

<!DOCTYPE html>
<html lang="en">
<head>
? ?<meta charset="UTF-8">
? ?<title>Title</title>
? ?<style>
html,body{width: 100%;height: 100%;background:#001122; }
? ?</style>
</head>
<body>

<svg width="100%" height="100%" viewBox="-960 -540 1920 1080" preserveAspectRatio="xMidYMid slice">
? ?<defs>
? ? ? ?<polygon id="star" points="0 -10 2 -2 10 0 2 2 0 10 -2 2 -10 0 -2 -2" fill="white"> </polygon>
? ?</defs>
? ?<g id="real">
? ? ? ?<g id="star-group"> </g>
? ? ? ?<g id="moon-group">
? ? ? ? ? ?<mask id="moon-mask">
? ? ? ? ? ? ? ?<circle r="100" cx="-250" cy="-150" fill="white"></circle>
? ? ? ? ? ? ? ?<circle r="100" cx="-200" cy="-200" fill="black"></circle>
? ? ? ? ? ?</mask>
? ? ? ? ? ?<circle r="100" cx="-250" cy="-150" fill="white" mask="url(#moon-mask)"></circle>
? ? ? ?</g>
? ? ? ?<g id="light-tower" transform="translate(250,0)">
? ? ? ? ? ?<defs>
? ? ? ? ? ? ? ?<linearGradient id="tower" x1="0" y1="0" x2="1" y2="0">
? ? ? ? ? ? ? ? ? ?<stop offset="0" stop-color="#999"></stop>
? ? ? ? ? ? ? ? ? ?<stop offset="1" stop-color="#333"></stop>
? ? ? ? ? ? ? ?</linearGradient>
? ? ? ? ? ? ? ?<radialGradient id="light" cx="0.5" cy="0.5" r="0.5">
? ? ? ? ? ? ? ? ? ?<stop offset="0" stop-color="rgba(255,255,255,.8)"></stop>
? ? ? ? ? ? ? ? ? ?<stop offset="1" stop-color="rgba(255,255,255,0)"></stop>
? ? ? ? ? ? ? ?</radialGradient>
? ? ? ? ? ? ? ?<clipPath id="light-clip">
? ? ? ? ? ? ? ? ? ?<polygon points="0 0 -400 -15 -400 15" fill="rgba(255,0,0,0.5)">
? ? ? ? ? ? ? ? ? ? ? ?<animateTransform
attributeName="transform"
attributeTpye="XML"
type="rotate"
from="0"
to="360"
dur="10s"
repeatCount="indefinite"
>
? ? ? ? ? ? ? ? ? ? ? ?</animateTransform>
? ? ? ? ? ? ? ? ? ?</polygon>
? ? ? ? ? ? ? ? ? ?<circle cxc="0" cy="0" r="2"></circle>
? ? ? ? ? ? ? ?</clipPath>
? ? ? ? ? ?</defs>
? ? ? ? ? ?<polygon points="0 0 5 50 -5 50" fill="url(#tower)"></polygon>
? ? ? ? ? ?<ellipse cx="0" cy="0" rx="300"ry="100" fill="url(#light)"clip-path="url(#light-clip)"></ellipse>

? ? ? ?</g>

? ?</g>
? ?<g id="reflact" transform="translate(0 50)"mask="url(#fading)">
? ? ? ?<defs>
? ? ? ? ? ? <linearGradient id="fade" x1="0" y1="0" x2="1" y2="0">
? ? ? ? ? ? ? ?<stop offset="0" stop-color="rgba(255,255,255,.3)"></stop>
? ? ? ? ? ? ? ?<stop offset="0.5" stop-color="rgba(255,255,255,.3)"></stop>
? ? ? ? ? ?</linearGradient>
? ? ? ? ? ?<mask id="fading">
? ? ? ? ? ? ?<rect x="-400" y="0" width="800" height="300" fill="url(#fade)"></rect>
? ? ? ? ? ?</mask>
? ? ? ?</defs>
? ? ? ?<use xlink:href="#real" transform="scale(1,-1) translate(0 -50)"></use>
? ?</g>
? ?<line x1="-400" y1="50" x2="400" y2="50" stroke="white"></line>
</svg>

<script>
var SVG_NS = "http://www.w3.org/2000/svg";
var XLINK_NS = "http://www.w3.org/1999/xlink";
var paper = document.querySelector("svg");
function use(origin){
? ? ? ?var _use = document.createElementNS(SVG_NS,"use");
_use.setAttributeNS(XLINK_NS,"xlink:href","#"+origin.id);
return _use;
}
? ?function ?random(min,max){
? ? ? ?return min + (max - min)*Math.random();
}
? ?renderStar();
function ?renderStar(){
? ? ? ?var starRef = document.getElementById("star");
var starGroup = document.getElementById("star-group");
var starConut = 500;

var star;
while(starConut--){
? ? ? ? ? ?star =use(starRef);
star.setAttribute("opacity",random(0.1,0.4));
star.setAttribute("transform","translate("+ random(-400,400)+ ","+ random(-300,50)+")" + "scale("+ random(0.1,0.6)+")");
starGroup.appendChild(star);
}
? ?}
</script>
</body>
</html>

0 回復(fù) 有任何疑惑可以回復(fù)我~

舉報(bào)

0/150
提交
取消

星星這章實(shí)現(xiàn)不了

我要回答 關(guān)注問題
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)