Rjs fade one image into another

Hi,

Has anyone got any suggestions on the best effect to use when fadding
one image into another?

Thanks
Mark

I’ve wanted to do this, but haven’t really found anything. You can try
playing with queues to make both effects (fade in and fade out) happen
simultaneously, but the main difficulty is that it’s HTML, and the
normal
flow layout will not place items on top of each other.

The only way I can think of doing it is with some CSS absolute
positioning,
which is always fun to get working across browsers correctly.

Jason

abs positioning, science no.

if your image is like this

then you do

assuming they are the same size img1 should now be over img2.
now all you need is to activate the fade effect on img 1.

I am a huge fan of this little library:
Cross Fade Anything
http://www.millstream.com.au/view/code/cross-fade-anything

On 6/4/07, Jason R. [email protected] wrote:


Posted via http://www.ruby-forum.com/ .


Thanks,
-Steve
http://www.stevelongdo.com

Eh, whoops. That Crossfader library is cool! I will definitely be using
that.

As for the image hack, I guess I was thinking of fading divs through
each
other, not just images. Good to know about images and floating.

Jason

thanks for the link, looks good :slight_smile:

Is it possible just to greyscale am image?

Mark wrote:

Hi,

Has anyone got any suggestions on the best effect to use when fadding
one image into another?

Thanks
Mark

I’m working on something along these lines right now with YUI. I’m still
having a few issues with the image preloading, but other than that it’s
working ok. I’ll post when completed.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs