Hello and welcome to the pyglet community! You can create the second Sprite while the image is shown for 10 seconds or so and load the next image here. Use fade-out effect for the first Sprite, delete it when opacity reaches 0 and then activate fade-in effect for the remaining Sprite. Hope it helps!
On Sun, Nov 24, 2019, 20:34 Rick Bonafied <rbonaf...@gmail.com> wrote: > Hi, > > This is not only my first pyglet attempt but also my first python > program. And yes, my first project is a slideshow. I have a raspberry pi > that will drive an older monitor that will display family photos. I'm > mostly done and really happy with how it behaves. There are no transition > affects between images. Unfortunately, I don't really understand GL or > texture use or blending or any of that. I'm hoping someone can provide me > a snippet of code that will do the trick. > > Basically I created a subclass of Window called ImageWindow. I load the > image into a single sprite and after every 10 scheduled seconds or so, the > new image is loaded into that same sprite and displayed. This works great > when progressing through images without any transition affect. I've tried > to schedule a "fade out" method that would fire off before the next image. > The "fade out" method just reduced the sprite opacity by a small increment > until it got to zero. Then the schedule was removed. This did some of > what I want but I don't think it was very efficient or very reliable. And > then the fade-in of the next image had me stumped. I tried to do the > reverse of the fade-out but combining that with the time it took to load > the next image from a network share made the fade-out last too long before > the fade in. > > Is there a cleaner/proper way to do this? > > Thank you! > R > > -- > You received this message because you are subscribed to the Google Groups > "pyglet-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to pyglet-users+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/pyglet-users/f560aab8-93c3-4a07-a4e9-67e19958f351%40googlegroups.com > <https://groups.google.com/d/msgid/pyglet-users/f560aab8-93c3-4a07-a4e9-67e19958f351%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "pyglet-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to pyglet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/pyglet-users/CAAbEUy6NJKoVs%3DOaxJghJcR5V6bQ_hJcedmP8BvJFXVOb260tg%40mail.gmail.com.