CSS3 Animation
-webkit-animation:'picslide' 20s infinite;
@-webkit-keyframes 'picslide'{}
<body>
<div class="pic"></div>
<div class="description">CSS3 Animation</div>
</body>
.pic{
position: relative;
width:500px;
height:300px;
margin:0 auto;
border:1px solid #333;
overflow: hidden;
background-size:cover;
-webkit-animation:'picslide' 20s infinite;
}
.description{
position: absolute;
width:500px;
height:40px;
background: rgba(244,244,244,0.6);
left: 0;
top:0;
right:0;
bottom: 0;
margin: 261px auto;
font-size:2em;
text-align: center;
-webkit-animation:'description' 20s infinite;
}
@-webkit-keyframes 'picslide'{
0%{
background: url("../1.jpg") no-repeat;
}
50%{
background: url("../2.jpg") no-repeat;
}
100%{
background: url("../3.jpg") no-repeat;
}
}
@-webkit-keyframes 'description'{
0%{
color: red;
}
50%{
color: green;
}
100%{
color: blue;
}
}