日本一卡精品视频免费丨国产午夜片无码区在线播放丨国产精品成人久久久久久久丨国产亚洲日韩av在线播放不卡丨亚洲日韩av无码

CSS 3D 基礎知識

2017/2/11 8:32:47   閱讀:1743    發布者:1743

css3d 總結

3d transform (3D變形)(rotate skew scale translate)

基礎知識

perspective (視距,景深) perspective-origin (視點)
transfrom

(1) 坐標 x y z

(2) 變形 基點位置 transform-origin
(3)transfrom-style:preserve-3d

3D旋轉圖片相冊

3d transform (3D變形)(rotate skew scale translate)

基礎知識

perspective (視距,景深) perspective-origin (視點)
transfrom

(1) 坐標 x y z

(2) 變形 基點位置 transform-origin
(3)transfrom-style:preserve-3d

3D旋轉圖片相冊


它就用到了一個比較簡單的坐標y 軸旋轉那咱們看一下他的代碼

html的代碼:
	

首先要建九個盒子放九張圖片,這個很容易理解的。

css的代碼
body{ background: #6daf39;(背景加了個顏色 主要是好看) } .xj{ perspective:600px;(這是井深) } .kj{ transition: 1s;(運動時間) transform-style:preserve-3d;(實現3d效果 當然這是非常重的) width:200px; height: 300px; margin:80px auto; position: relative; transform: rotateY(0deg) rotateX(0deg) translateZ(-275px); transform-origin: center center -275px; } .mian{ position:absolute; font-size: 50px; color:#fff; text-align: center; line-height: 300px; } .mian:nth-child(1){ width:200px; height: 300px; background: #ff2223; transform: rotateY(0deg)translateZ(275px); } .mian:nth-child(2){ width:200px; height: 300px; background: #ff2223; transform: rotateY(40deg)translateZ(275px); } .mian:nth-child(3){ width:200px; height: 300px; background: #ff2223; transform: rotateY(80deg)translateZ(275px); } .mian:nth-child(4){ width:200px; height: 300px; background: #ff2223; transform: rotateY(120deg)translateZ(275px); } .mian:nth-child(5){ width:200px; height: 300px; background: #ff2223; transform: rotateY(160deg)translateZ(275px); } .mian:nth-child(6){ width:200px; height: 300px; background: #ff2223; transform: rotateY(200deg)translateZ(275px); } .mian:nth-child(7){ width:200px; height: 300px; background: #ff2223; transform: rotateY(240deg)translateZ(275px); } .mian:nth-child(8){ width:200px; height: 300px; background: #ff2223; transform: rotateY(280deg)translateZ(275px); } .mian:nth-child(9){ width:200px; height: 300px; background: #ff2223; transform: rotateY(320deg)translateZ(275px); }

css就到這里,很簡單的;

js的代碼
kj.onclick=function () { 
      cishu++; 
      var jiaodu=40*cishu; 


      kj.style.transform="rotateY("+jiaodu+"deg)translateZ(-275px)" 
    }

(kj)就是3d空間,點擊kj要是一種效果,就要有一種方法或步驟;
3d空間樣式rotateY(這就是上下軸旋轉)translateZ(Z這就是3d立體字軸;
讓3d空間后移275px找到軸心位置)

完畢 希望大家看到這篇文章后能夠學到知識。



主站蜘蛛池模板: 国产不卡视频一区二区三区| 欧洲丰满少妇做爰视频爽爽| 亚洲国产成人爱av在线播放| 日韩av专区| 波多野结衣亚洲视频| 亚洲精品无码久久久久久久| 亚洲中文字幕无码久久| 成人免费在线| 色综合久久成人综合网| 国产偷窥熟女精品视频大全| 精品人妻伦九区久久aaa片69| 自拍偷拍21p| 特级毛片在线大全免费播放| 欧洲成人午夜免费大片| 午夜精品久久久久久久久久久久久 | 暴操白丝美女| 久久久久青草大香综合精品| 国产午夜精品一区二区三区 | 中文字幕久热精品视频在线| 天天色天天搞| 亚洲va成无码人在线观看天堂| 男人的天堂在线视频| 黄色在线观看免费| 亚洲一区二区三区无码中文字幕| 亚洲日韩av无码一区二区三区人| 日韩不卡的av| 天天做天天躁天天躁| a√视频在线| 国产日韩欧美亚欧在线| av网站的免费观看| www无套内射高清免费| 久久人人97超碰a片精品| 男男军官互攻互受h啪肉np文| 欧美精品18videosex性欧美| 91高潮大合集爽到抽搐| 亚洲第一se情网站| 亚洲国产精品一区二区www| 欧美自拍亚洲综合图区|