переходы fadeInOut фонового изображения дают странный эффект белого цвета во всех текстах

Ну эта проблема довольно странная,

У меня есть сайт, где фоновое изображение меняется с переходом fadeIn/Out

Видео: http://www.screenr.com/ZCvs

Web в действии: http://toniweb.us/gm

Разметка:

        

CSS:

.headerimg { 
    background-position: center top; background-repeat: no-repeat; width:100%;position:absolute;height:100%;cursor:pointer; 
     -webkit-background-size: cover;
        -moz-background-size: cover;
        -o-background-size: cover;
        background-size: cover;

}
.headerimg img{ 
    min-width:100%; width:100%; height:100%;
}

    .fondo{
    position:absolute;
    z-index:1;
    width:100%;
    height:100%;
    cursor:pointer;
}

Javascript:

/*Gestion de pase de imágenes de fondo*/
$(document).ready(function() {
    /*controla la velocidad de la animación*/
    var slideshowSpeed = 3000;
    var transitionSpeed = 2000;
    var timeoutSpeed = 500;

    /*No tocar*/
    var interval;
    var activeContainer = 1;    
    var currentImg = 0;
    var animating = false;
    var navigate = function(direction) {
        // Si ya estamos navegando, entonces no hacemos nada!
        if(animating) {
            return;
        }
        currentImg++;
        if(currentImg == photos.length + 1) {
            currentImg = 1;
        }
        // Tenemos dos, uno en el que tenemos la imagen que se ve y otro d?nde tenemos la imagen siguiente
        var currentContainer = activeContainer;
        // Esto puedo optimizarlo con la funci?n modulo, y cambiar 1 y 2 por 0 y 1-> active = mod2(active + 1)
        if(activeContainer == 1) {
            activeContainer = 2;
        } else {
            activeContainer = 1;
        }
        // hay que decrementar el ?ndice porque empieza por cero
        cargarImagen(photos[currentImg - 1], currentContainer, activeContainer);
    };
    var currentZindex = -1;
    var cargarImagen = function(photoObject, currentContainer, activeContainer) {
        animating = true;
        // Nos aseguramos que el nuevo contenedor está siempre dentro del cajon
        currentZindex--;
        //if(currentZindex < 0) currentZindex=1;
        // Actualizar la imagen
        $("#headerimg" + activeContainer).css({
            "background-image" : "url(" + photoObject + ")",
            "display" : "block",
            "z-index" : currentZindex
        });
        // FadeOut antigua
        // Cuando la transición se ha completado, mostramos el header 
        $("#headerimg" + currentContainer).fadeOut(transitionSpeed,function() {
            setTimeout(function() {
                $("#headertxt").css({"display" : "block"});
                animating = false;
            }, timeoutSpeed);
        });
    };
    //ver la primera
     navigate("next");
    //iniciar temporizador que mostrará las siguientes



    interval = setInterval(function() {
        navigate("next");
    }, slideshowSpeed);

});

Есть также накладной div (класс fondo) (высота и ширина 100%), так что я могу определить, когда фон был нажат (я не могу использовать непосредственно фоновый div, потому что переход делает его с отрицательным z-индексом)

Проблема в том, что этот переход производит странный эффект во всех белых текстах

Есть идеи, что я упускаю?

6
задан Toni Michel Caubet 13 December 2011 в 16:12
поделиться