I have put together an image scroller using jquery, like this
function rotateImages(whichHolder, start) {
var images = $('#' +whichHolder).find('img');
if(images.length < 1) return;
start = start || 0; // Allow not to specify 0 when first calling
if (start >= images.length) start=0;
images.css({display: 'none'});
var thisImg = $('#' +whichHolder +' img').get(start);
$(thisImg).css({display: 'block'});
return start + 1;
}
var start = 1;
$(function(){
window.setInterval(function() {
start = rotateImages('rotator', start);
}, 5000);
});
the images just change from one to the next, what i would like to do is put a transition effect in there, similar to ones that NivoSlider uses. How would I go about this or where can I find the resources to see how it is done. I would like to make the transition a little more pleasing to the eye.
Any help appreciated.
well, trying to answer “how”, what that slideshow do is to divide the image into slices (or boxes), e.g.: they use this function to divide the image into slices
once they divide the images into peaces they try to make a transition animating each peace, e.g.: this is how they are supposed to animate the slices
but, I personally think if you want a slideshow that animate every slide like that, just use NivoSlider, don’t you think