Home › Forums › CSS › CSS3 Rotating YouTube Video › Re: CSS3 Rotating YouTube Video
May 21, 2012 at 6:10 am
#103183
anton2k
Participant
So after some tinkering around with this i can only conclude that the problem is with chrome and IE, here is something cool for you all to look at, using animation to rotate a YouTube video 360 degrees, only works on FireFox at the moment, here is the css and html any way.
CSS
@-webkit-keyframes rotate {
from {
-webkit-transform: rotate(0deg);
}
to {
-webkit-transform: rotate(360deg);
}
}
@-moz-keyframes rotate {
from {
-moz-transform: rotate(0deg);
}
to {
-moz-transform: rotate(360deg);
}
}
@-ms-keyframes rotate {
from {
-ms-transform: rotate(0deg);
}
to {
-ms-transform: rotate(360deg);
}
}
#emb {
position: absolute;
width:560px;
height:315px;
}
iframe {
width:560px;
height:315px;
-webkit-animation-name: rotate;
-webkit-animation-duration: 50000ms; /* 50 seconds */
-webkit-animation-iteration-count: infinite;
-webkit-animation-timing-function: linear;
-moz-animation-name: rotate;
-moz-animation-duration: 50000ms; /* 50 seconds */
-moz-animation-iteration-count: infinite;
-moz-animation-timing-function: linear;
-ms-animation-name: rotate;
-ms-animation-duration: 50000ms; /* 50 seconds */
-ms-animation-iteration-count: infinite;
-ms-animation-timing-function: linear;
}
HTML
:D