How to avoid any fade duration during slide transition
1) Script Title: Simple Controls Gallery
2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...plegallery.htm
I am using the gallery to display weather maps (gif/png images) in a loop. When transitioning from one slide (image) to the next, I don't want to there to be any fade...just an instant display of the next slide. I tried placing the fadeduration down to 1 ms, but there's still an "annoying" flash between images in the loop. I tried setting this to zero and I'm getting no images to display at all when it is at zero. Sometimes the first run through the loop is fine and then the next run flashes between slides. Makes it hard to see details/changes between slides (important for weather map displays).
Any help would be appreciated.
Here's a little code snipit.
Code:
var mygallery=new simpleGallery({
wrapperid: "simplegallery1", //ID of main gallery container,
dimensions: [x_dimension, y_dimension], //width/height of gallery in pixels. Should reflect dimensions of the images exactly
imagearray: [ <?php for($index=0;$index<sizeof($xml->TAB[$p_index]->IMAGE);$index++)
{?>
[<?php if($xml->TAB[$p_index]->IMAGE[$index]->URL != '' && url_validate($xml->TAB[$p_index]->IMAGE[$index]->URL)){?>"<?=$xml->TAB[$p_index]->IMAGE[$index]->URL?>",<? } else {?> "http://<?=$_SERVER['HTTP_HOST']?>/wx/photo_not_available.jpg", <? } ?> <?php if($xml->TAB[$p_index]->IMAGE[$index]->LINK != '')
{ ?> "<?=$xml->TAB[$p_index]->IMAGE[$index]->LINK?>", <? } else { if(!empty($xml->TAB[$p_index]->IMGGENERICLINK)){?> "<?=$xml->TAB[$p_index]->IMGGENERICLINK?>", <? } else {?> "nolink", <?} } ?> "_new", <?php if($xml->TAB[$p_index]->IMAGE[$index]->LABEL!=''){?>"<?=$xml->TAB[$p_index]->IMAGE[$index]->LABEL?>",<?php } else {?> " ",<?php } ?>""]<?php if($index<sizeof($xml->TAB[$p_index]->IMAGE)-1){?>,<? } ?>
<? } ?>
],
autoplay: [false, delay, 2], //[auto_play_boolean, delay_btw_slide_millisec, cycles_before_stopping_int]
persist: false, //remember last viewed slide and recall within same session?
fadeduration: 1, //transition duration (milliseconds)
oninit:function(){ //event that fires when gallery has initialized/ ready to run
//Keyword "this": references current gallery instance (ie: try this.navigate("play/pause"))
},
onslide:function(curslide, i){ //event that fires after each slide is shown
//Keyword "this": references current gallery instance
//curslide: returns DOM reference to current slide's DIV (ie: try alert(curslide.innerHTML)
//i: integer reflecting current image within collection being shown (0=1st image, 1=2nd etc)
}
})