『壹』 怎樣能製作出雪花飄落的動態效果圖片
用flash引導線製作雪花飄落的動畫教程
在 Flash 中利用引導線製作雪花飄飄動畫。 這種方法最笨但也效果最好,就是用引導線功能,讓雪花不停的飄呀飄,如果多用幾個圖層,效果更好。
1、新建一個flash影片。設背景為「黑色」,其他的用默認值。
2、按ctrl+f8新建一個組件,類型為「影片剪輯」,命名為「雪花」。在它的正中用「鉛筆」工具畫一個不規則的多邊形,然後用「顏料桶工具」將它填上白色。(如圖1-1所示)
3、再用ctrl+f8建一個組件,類型為「影片剪輯」,命名為「前層」。
4、將組件「雪花」拖到其中,用「選定工具」中的「比例」功能把它縮小(小技巧:先用「放大鏡」將它放大,然後再用「比例」功能,可縮得更小)。在第80幀上「插入關鍵幀」,在「圖層1」上用滑鼠右鍵的「添加引導線」功能(見圖1-2)。
在新增加的「引導線:圖層1」的第1幀上,從「雪花」開始,畫一條彎曲的曲線。將第80幀上的「雪花」沿曲線從頭拖到曲線的末尾。然後在「圖層1」的第1幀上點滑鼠右鍵,選「創見動畫動作」功能,見圖1-3。
5、第4步是製作一片雪花,下雪不是只下一片的吧。插入圖層,將第4步重復做10次。做好後的效果見圖1-4。6、把第3至5步重復做兩次,不同之處是組件的命名分別為「中層」和「後層」。「雪花」的大小和「引導線」的路徑不要一樣。這是為了多做幾個圖層,看起來效果細膩一點。
7、現在回到場景1中,插入6個圖層,分別命名為「後層1」、「後層2」、「中層1」、「中層2」、「中層3」、「中層4」、「前層1」、「前層2」。在對應的層上拖入對應的組件,並適當的調整時間軸,讓雪花飄得連貫起來。見圖1-5。
按ctrl+enter就可以看到效果了。
(這種方法簡單且效果好,主要是用「引導線」功能,讓雪花不停的飄下,多用幾個圖層效果會更好)
『貳』 網頁飄雪花的代碼是什麼
在後台添加js特效可實現這樣的效果。
js代碼為:
<script language="JavaScript">
<!--
var no = 5; //雪片數目
var speed = 20; //飄動速度。(值越大越慢)
var ns4up = (document.layers) ? 1 : 0; //當前瀏覽器類型,如果是NS則為1
var ie4up = (document.all) ? 1 : 0; //當前瀏覽器類型,如果是IE則為1
var s, x, y, sn, cs;
var a, r, cx, cy;
var i, doc_width = 800, doc_height = 600;
x = new Array();
y = new Array();
r = new Array();
cx = new Array();
cy = new Array();
s = 8; //每次下落的高度,越小越平滑,但是也越慢
if (ns4up) { //以NS兼容方式
doc_width = self.innerWidth; //取頁面寬度
doc_height = self.innerHeight; //取頁面高度
}
else
if (ie4up) { //以IE兼容方式
doc_width = document.body.clientWidth; //取頁面寬度
doc_height = document.body.clientHeight; //取頁面高度
}
for (i = 0; i < no; ++ i) { //根據前面定義的雪片數目寫進相應數目的層
initSnow(); //隨機初始化層的坐標
if (ns4up) { //如果瀏覽器是NS
//用layer作為雪片(星號)的容器
document.write("<layer name=\"dot"+ i +"\" left=\"1\" ");
document.write("top=\"1\" visibility=\"show\"><font color=\"red\">");
document.write("*</font></layer>");
}
else
if (ie4up) { //如果瀏覽器是IE
//用div作為雪片的容器
document.write("<div id=\"dot"+ i +"\" style=\"POSITION: ");
document.write("absolute; Z-INDEX: "+ i +"; VISIBILITY: ");
document.write("visible; TOP: 15px; LEFT: 15px;\"><font color=\"red\">");
document.write("*</font></div>");
}
}
//初始化雪片,生成隨機坐標
function initSnow() {
a = 6;
r[i] = 1;
sn = Math.sin(a);
cs = Math.cos(a);
cx[i] = Math.random() * doc_width + 1;
cy[i] = Math.random() * doc_height + 1;
x[i] = r[i] * sn + cx[i];
y[i] = cy[i];
}
//計算雪花位置,從新位置上出現,看起來就像是新產生的一樣。
function makeSnow() {
r[i] = 1;
cx[i] = Math.random() * doc_width + 1;
cy[i] = 1;
x[i] = r[i] * sn + cx[i];
y[i] = r[i] * cs + cy[i];
}
//雪花下落的計算
function updateSnow() {
r[i] += s;
x[i] = r[i] * sn + cx[i];
y[i] = r[i] * cs + cy[i];
}
//在NS瀏覽器上處理雪片下落的主程序
function SnowdropNS() {
for (i = 0; i < no; ++ i) { //依次處理每片雪花
updateSnow(); //下落
if ((x[i] <= 1) || (x[i] >= (doc_width - 20)) || (y[i] >= (doc_height - 20))) { //如果超出屏幕范圍
makeSnow(); //則調整雪片到新位置上
doc_width = self.innerWidth; //更新頁面寬度數據
doc_height = self.innerHeight; //更新頁面高度數據
}
document.layers["dot"+i].top = y[i]; //改變層的Y坐標,應用新的位置
document.layers["dot"+i].left = x[i]; //改變層的X坐標,應用新的位置
}
setTimeout("SnowdropNS()", speed);
}
//在IE瀏覽器上處理雪片下落的主程序
function SnowdropIE() {
for (i = 0; i < no; ++ i) { //依次處理每片雪花
updateSnow(); //下落
if ((x[i] <= 1) || (x[i] >= (doc_width - 20)) || (y[i] >= (doc_height - 20))) { //如果超出屏幕范圍
makeSnow(); //則調整雪片到新位置上
doc_width = document.body.clientWidth; //更新頁面寬度數據
doc_height = document.body.clientHeight; //更新頁面高度數據
}
document.all["dot"+i].style.pixelTop = y[i]; //改變層的坐標,應用新的位置
document.all["dot"+i].style.pixelLeft = x[i];
}
setTimeout("SnowdropIE()", speed); //准備下一次下落過程。
}
if (ns4up) { //如果是NS
SnowdropNS(); //調用SnowdropNS使雪片下落
}
else
if (ie4up) { //如果是NS
SnowdropIE(); //調用SnowdropIE使雪片下落
}
-->
</script>
說明:可以根據自己的需求根據說明進行相應參數的修改
『叄』 PS簡單教程:製作雪花飄落的動態效果
首先,你要打開photoshop,打開原圖。
第二步:新建圖層,黑色填充,執行:濾鏡>雜色>添加雜色,數量100,高斯分布,單色。
第三步:執行:濾鏡>模糊>進一步模糊,圖像>調整>色階,屬性值分別設為:104,0.41,187。
第四步:將此圖層混合模式設為“濾色”。
第五步:濾鏡 >> 模糊 >> 動感模糊,角度-65,距離8。
第六步:復制雪花層,執行:濾鏡>像素化>晶格化,數值:12。
第七步:合並兩個雪花圖層,將此圖層混合模式設為“濾色”。
第八步:窗口>時間軸,切換到幀動畫模式,復制一幀,將該幀的雪花圖層往右下方移動一段距離,使用仿製圖章工具,將沒有雪花的地方填滿。
第九步:選中兩個幀,點擊”過渡動畫幀“,確定完成;點擊播放可查看效果,選擇文件>導出>存為web所用格式,選擇gif格式。
關於PS簡單教程:製作雪花飄落的動態效果,青藤小編就和您分享到這里了。如果您對頁面排版、網站設計、圖像處理等有濃厚的興趣,希望這篇文章可以對您有所幫助。如果您還想了解更多關於平面設計的素材及技巧等內容,可以點擊本站的其他文章進行學習。
以上是小編為大家分享的關於PS簡單教程:製作雪花飄落的動態效果的相關內容,更多信息可以關注環球青藤分享更多干貨
『肆』 淘寶里首頁飄雪花 怎麼弄啊 js代碼放在哪裡啊 本人小白 希望大神詳解.....
<div class="J_TWidget" data-widget-config="{'ration':0.1,'activeTriggerCls':'.tshop-psm-shop-ww-hover','interval':0.1,'effect':'scrollx','activeIndex':1,'navCls':'user-crzysj','contentCls':'user-crzysjii','autoplay':true}" data-widget-type="Carousel" style="position:relative;"><ul class="user-crzysjii" style="display: none; width: 999999px; left: 0px; position: absolute;"><li class="-_-switchable-panel-internal535 ks-switchable-panel-internal998" style="width: 475px; height: 800px; display: block; float: left;"> </li></ul><ul class="user-crzysj"><li class="-_-switchable-trigger-internal534 ks-switchable-trigger-internal997 tshop-psm-shop-ww-hover" style="width:475px;height:800px;right:50%;margin-right:505px;"><embed allownetworking="all" allowscriptaccess="never" flashvars="scene=taobao_shop" height="1000" name="flashfirebug_1387778983714" src="http://img1.tbcdn.cn/tfscom/T1lmk2Fk8bXXXtxVjX.swf" type="application/x-shockwave-flash" width="475" wmode="transparent"></li></ul></div><div class="J_TWidget" data-widget-config="{'ration':0.1,'activeTriggerCls':'.tshop-psm-shop-ww-hover','interval':0.1,'effect':'scrollx','activeIndex':1,'navCls':'user-crzysj','contentCls':'user-crzysjii','autoplay':true}" data-widget-type="Carousel" style="position:relative;z-index:99;"><ul class="user-crzysjii" style="display: none; width: 999999px; left: 0px; position: absolute;"><li class="-_-switchable-panel-internal635 ks-switchable-panel-internal1108" style="width: 475px; height: 800px; display: block; float: left;"> </li></ul><ul class="user-crzysj"><li class="-_-switchable-trigger-internal634 ks-switchable-trigger-internal1107 tshop-psm-shop-ww-hover" style="width:475px;height:800px;left:50%;margin-left:505px;"><embed allownetworking="all" allowscriptaccess="never" flashvars="scene=taobao_shop" height="1000" name="flashfirebug_1387778983652" src="http://img1.tbcdn.cn/tfscom/T1lmk2Fk8bXXXtxVjX.swf" type="application/x-shockwave-flash" width="475" wmode="transparent"></li></ul></div>
直接在首頁添加個自定義模塊 編輯 點兩個箭頭的那個編輯代碼模式 然後復制代碼放進去 確定就好!
『伍』 求VB程序設計,有一段雪花飄揚的代碼,求添加代碼讓用戶選擇往左飄或者往右飄,還有飄雪速度代碼。
Private sub form1_load(省略)
Dim i As Integer
For i=0 To 99
Randomize()
s(i)=New snowflakes(Rnd()*Me.width,Rnd()*Me.Height)
Next
End Sub
Private sub timer1_tick(省略)
Me.Refresh()
pen1=New pen(color.white,5)
g=Me.CreateGraphics
For i=0 to 99
g.DrawEllipse(pen1,s(i).x,s(i).y,1,1)
s(i).down(10)
If s(i).x>=Me.width Then
s(i).x=Rnd()*20
End If
If s(i).y>=Me.Height Then
s(i).y=Rnd()*10
End If
『陸』 天貓店鋪頁面兩邊動態飄落雪花怎麼做的(還有導航)
代碼添加的,直接添加到導航下面 <div class="J_TWidget" data-widget-config="{'ration':0.1,'activeTriggerCls':'.tshop-psm-shop-ww-hover','interval':0.1,'effect':'scrollx','activeIndex':1,'navCls':'user-crzysj','contentCls':'user-crzysjii','autoplay':true}" data-widget-type="Carousel" style="position:relative;"> <ul class="user-crzysjii" style="display:none;width:999999px;left:0px;"> <li class="-_-switchable-panel-internal535 ks-switchable-panel-internal998" style="width:475px;height:800px;display:block;float:left;"> </li> </ul> <ul class="user-crzysj"> <li class="-_-switchable-trigger-internal534 ks-switchable-trigger-internal997 " style="width:475px;height:800px;right:50%;margin-right:505px;"> <embed allownetworking="all" allowscriptaccess="never" flashvars="scene=taobao_shop" height="1000" name="flashfirebug_1387778983714" src="http://img1.tbcdn.cn/tfscom/T1lmk2Fk8bXXXtxVjX.swf" type="application/x-shockwave-flash" width="475" wmode="transparent"></embed></li> </ul> </div> <div class="J_TWidget" data-widget-config="{'ration':0.1,'activeTriggerCls':'.tshop-psm-shop-ww-hover','interval':0.1,'effect':'scrollx','activeIndex':1,'navCls':'user-crzysj','contentCls':'user-crzysjii','autoplay':true}" data-widget-type="Carousel" style="position:relative;z-index:99;"> <ul class="user-crzysjii" style="display:none;width:999999px;left:0px;"> <li class="-_-switchable-panel-internal635 ks-switchable-panel-internal1108" style="width:475px;height:800px;display:block;float:left;"> </li> </ul> <ul class="user-crzysj"> <li class="-_-switchable-trigger-internal634 ks-switchable-trigger-internal1107 " style="width:475px;height:800px;left:50%;margin-left:505px;"> <embed allownetworking="all" allowscriptaccess="never" flashvars="scene=taobao_shop" height="1000" name="flashfirebug_1387778983652" src="http://img1.tbcdn.cn/tfscom/T1lmk2Fk8bXXXtxVjX.swf" type="application/x-shockwave-flash" width="475" wmode="transparent"></embed></li> </ul> </div>
『柒』 QQ空間雪花代碼
可以通過添加透明flash來達到你要的效果,以下是使用方法和可以引用的透明flash地址(有多個是雪花的效果,可以仔細找下):
日誌加透明flash步驟:
1.在日誌頁面上點擊(寫日誌)
2.點擊那個紅色圖案
3.輸入透明Flash地址
4.點自定義、(寬.800.px 高.800.px)
5.點設置為透明背景(Flash需支持)
6.背景位置(left.0.px top.0.px)
以上任何一步不正確都不會被顯示
http://imgfree.21cn.com/free/flash/209.swf 紅色汽球
http://i39.photobucket.com/albums/e161/haihaiyoyo/-1.swf 小紅心組大紅心
http://i39.photobucket.com/albums/e161/haihaiyoyo/iloveu.swf我愛你加星光
http://i82.photobucket.com/albums/j257/ayumi_927/True_Star.swf 掛五角星
http://1stblog.cn//swf/trns/001.swf 左右流星
http://1stblog.cn//swf/trns/002.swf 一隻蜻蜓
http://imgfree.21cn.com/free/flash/1.swf紅色背景白色小流星
http://imgfree.21cn.com/free/flash/2.swf淺綠色背景亮色豎條
http://imgfree.21cn.com/free/flash/3.swf光球光芒時隱時現
http://imgfree.21cn.com/free/flash/4.swf米字星光
http://imgfree.21cn.com/free/flash/5.swf灰色背景米字星光
http://imgfree.21cn.com/free/flash/6.swf灰藍背景飄落雨滴
http://imgfree.21cn.com/free/flash/7.swf黃色背景飛星閃閃
http://imgfree.21cn.com/free/flash/8.swf青蛙
http://imgfree.21cn.com/free/flash/9.swf藍色蝴蝶
http://imgfree.21cn.com/free/flash/10.swf豎條箭頭
http://imgfree.21cn.com/free/flash/11.swf寬窄豎條
http://imgfree.21cn.com/free/flash/12.swf左右晃動的豎條(寬、窄)
http://imgfree.21cn.com/free/flash/13.swf黑色背景旋轉輪盤
http://imgfree.21cn.com/free/flash/14.swf蝌蚪旋轉、隨滑鼠的白色光團
http://imgfree.21cn.com/free/flash/15.swf黑色背景綠色飄帶幻影
http://imgfree.21cn.com/free/flash/16.swf黑色背景飛星閃閃
http://imgfree.21cn.com/free/flash/17.swf金魚
http://imgfree.21cn.com/free/flash/18.swf藍色背景水平飛鏢
http://imgfree.21cn.com/free/flash/19.swf左右晃動的豎條
http://imgfree.21cn.com/free/flash/20.swf黑色背景水平閃動的橫條
http://imgfree.21cn.com/free/flash/21.swf黑色背景光暈
http://imgfree.21cn.com/free/flash/22.swf光圈由小變大
http://imgfree.21cn.com/free/flash/23.swf藍色背景雪花飄飄
http://imgfree.21cn.com/free/flash/24.swf左右閃動的豎條
http://imgfree.21cn.com/free/flash/25.swf三隻黑螞蟻
http://imgfree.21cn.com/free/flash/26.swf左右晃動的黃、綠、藍豎線
http://imgfree.21cn.com/free/flash/27.swf無色背景水珠
http://imgfree.21cn.com/free/flash/28.swf黑色背景豎條
http://imgfree.21cn.com/free/flash/29.swf圓圈內海浪波動
http://imgfree.21cn.com/free/flash/30.swf黑色背景藍色夢幻
http://imgfree.21cn.com/free/flash/30.swf黑色背景藍色夢幻
http://imgfree.21cn.com/free/flash/31.swf黑色背景無數小亮點飄落
http://imgfree.21cn.com/free/flash/32.swf長發女孩
http://imgfree.21cn.com/free/flash/33.swf粉黃色5瓣花飄飄
http://imgfree.21cn.com/free/flash/35.swf小星、大星光暈夢幻
http://imgfree.21cn.com/free/flash/35.swf紫色唇印升騰
http://imgfree.21cn.com/free/flash/36.swf上下閃動的橫條
http://imgfree.21cn.com/free/flash/37.swf綠色、黃色的樹葉飛舞
http://imgfree.21cn.com/free/flash/38.swf流星飛降
http://imgfree.21cn.com/free/flash/39.swf小+字旋轉大光圈
http://imgfree.21cn.com/free/flash/40.swf大、小八瓣雪花飄落
http://imgfree.21cn.com/free/flash/41.swf紫色背景大、小八瓣雪花飄落
http://imgfree.21cn.com/free/flash/42.swf空中飄動的黃球
http://imgfree.21cn.com/free/flash/45.swf兩只黃色的蝴蝶在左上角飛舞
http://imgfree.21cn.com/free/flash/46.swf一片淺粉色的雲團
http://imgfree.21cn.com/free/flash/47.swf 箭頭左右穿梭
http://imgfree.21cn.com/free/flash/48.swf一個光球從右上方慢慢飛入
http://imgfree.21cn.com/free/flash/49.swf飄落的淺粉色花瓣
http://imgfree.21cn.com/free/flash/50.swf晃動的文字「sweet kiss day」
http://imgfree.21cn.com/free/flash/51.swf三隻飛舞的蜻蜓、閃閃的星光
http://imgfree.21cn.com/free/flash/52.swf黑色背景飄落的紅葉
http://imgfree.21cn.com/free/flash/53.swf雪糕降落
http://imgfree.21cn.com/free/flash/54.swf綠色的心和I love you垂直降落
http://imgfree.21cn.com/free/flash/55.swf兩只跳躍的青蛙
http://imgfree.21cn.com/free/flash/56.swf六邊形、降落的豎條
http://imgfree.21cn.com/free/flash/57.swf燕魚和水泡
http://imgfree.21cn.com/free/flash/58.swf光暈、光圈
http://imgfree.21cn.com/free/flash/59.swf天上散綠葉
http://imgfree.21cn.com/free/flash/59.swf藍色背景飛翔的海鷗
http://imgfree.21cn.com/free/flash/60.swf黑色背景降落的螢火蟲
http://imgfree.21cn.com/free/flash/61.swf飛騰的紅心
http://imgfree.21cn.com/free/flash/62.swf五彩禮花燃放
http://imgfree.21cn.com/free/flash/63.swf黃色的四瓣花飄落
http://imgfree.21cn.com/free/flash/64.swf淺藍色的雪花在空中,小雪花降落
http://imgfree.21cn.com/free/flash/65.swf飄落的空心小蘭圈
http://imgfree.21cn.com/free/flash/66.swf一隻手的圖形
http://imgfree.21cn.com/free/flash/67.swf由遠而近飛來的流星
http://imgfree.21cn.com/free/flash/68.swf黑色背景飄落的雪花
http://imgfree.21cn.com/free/flash/69.swf七彩光光芒四射(全屏)
http://imgfree.21cn.com/free/flash/70.swf七彩光光芒四射(全屏)
http://imgfree.21cn.com/free/flash/71.swf閃動的小豎條
http://imgfree.21cn.com/free/flash/72.swf一隻和平鴿展翅飛舞
http://imgfree.21cn.com/free/flash/73.swf藍色背景藍色氣泡慢慢升空
http://imgfree.21cn.com/free/flash/74.swf白色背景淺藍色的氣泡慢慢升空
http://imgfree.21cn.com/free/flash/75.swf跟隨滑鼠游動的七彩光圈
http://imgfree.21cn.com/free/flash/76.swf 線條變形
http://imgfree.21cn.com/free/flash/77.swf藍色旋轉
http://imgfree.21cn.com/free/flash/78.swf跟隨滑鼠旋轉的數字時鍾
http://imgfree.21cn.com/free/flash/79.swf滑鼠滑過方塊圖形變換
http://www.12127.net/q-zone/tx/4.swf滿天星星
http://www.12127.net/q-zone/tx/5.swf米字星光
http://www.12127.net/q-zone/tx/7.swf大雨點
http://www.12127.net/q-zone/tx/8.swf發散的光
http://www.12127.net/q-zone/tx/9.swf背景光暈
http://www.12127.net/q-zone/tx/21.swf 背景光暈
http://www.12127.net/q-zone/tx/23.swf 藍色雪花
http://www.12127.net/q-zone/tx/31.swf黑色背景無數小亮點飄落
http://www.12127.net/q-zone/tx/33.swf粉黃色5瓣花飄飄
http://www.12127.net/q-zone/tx/35.swf小星、大星光暈夢幻
http://www.12127.net/q-zone/tx/41.swf紫色背景大、小八瓣雪花飄落
http://www.12127.net/q-zone/tx/42.swf蒲公英
http://www.12127.net/q-zone/tx/46.swf一片淺粉色的雲團
http://www.12127.net/q-zone/tx/51.swf三隻飛舞的蜻蜓、閃閃的星光
http://www.12127.net/q-zone/tx/52.swf黑色背景飄落的楓葉
http://www.12127.net/q-zone/tx/54.swf綠色的心和I love you垂直降落
http://www.12127.net/q-zone/tx/59.swf藍色背景飛翔的海鷗
http://www.12127.net/q-zone/tx/61.swf飛騰的紅心
http://www.12127.net/q-zone/tx/62.swf五彩禮花燃放
http://www.12127.net/q-zone/tx/64.swf淺藍色的雪花
http://www.12127.net/q-zone/tx/67.swf由遠而近飛來的流星
http://www.12127.net/q-zone/tx/69.swf飛翔的鷹
http://www.12127.net/q-zone/tx/73.swf藍色背景藍色氣泡慢慢升
http://www.12127.net/q-zone/tx/87.swf跟隨滑鼠移動的黃色小球
http://www.12127.net/q-zone/tx/69.swf七彩光光芒四射(全屏)
http://www.12127.net/q-zone/tx/82.swf雪花旋舞
http://www.12127.net/q-zone/tx/84.swf閃動的白色圓圈
http://www.12127.net/q-zone/tx/89.swf金光閃閃(中間到四周)
http://www.12127.net/q-zone/tx/92.swf飄舞的七彩絲線
http://www.12127.net/q-zone/tx/93.swf閃電效果
http://www.12127.net/q-zone/tx/95.swf 七彩光8字形旋轉
http://www.12127.net/q-zone/tx/97.swf 旋轉的花瓣、蝴蝶隨滑鼠飛舞
http://www.12127.net/q-zone/tx/98.swf 飛旋的七彩光
http://www.12127.net/q-zone/tx/99.swf 白色旋轉的花瓣變形
http://www.12127.net/q-zone/tx/100.swf 藍寶石七彩閃光
http://www.12127.net/q-zone/tx/103.swf 從空特大雨滴
http://www.12127.net/q-zone/tx/mhh.swf 漂亮的玫瑰花從上飄落
http://www.12127.net/q-zone/tx/sh.swf 從上飄落的鮮花和紅心
http://imgfree.21cn.com/free/flash/80.swf跟隨滑鼠的「歡迎下載」及七彩星