标签:
css
.transformBox{
    transform-style: preserve-3d;
    -webkit-transition: all 0.5s ease-out;
    -moz-transition: all 0.5s ease-out;
    -o-transition: all 0.5s ease-out;
    transition: all 0.5s ease-out;
}
html
<div class="col-lg-4 transformBox">
			          	    <div style="transform: translateZ(100px);">
			          	        <img src="images/bannerPic.png"  />
			          	    </div>
			          	</div>
js
$(‘.transformBox‘).mousemove(function (e) {
        var xx = e.pageY/100;
        var yy = e.pageX/100;
        $(this).find(‘.aa‘).css({
            "transform": "rotateX(" +xx+"deg) rotateY("+yy+"deg)"
            //"transform":(+y)+"px"
        });
});
标签:
原文地址:http://www.cnblogs.com/sentiment/p/5955991.html