Thank you, gimmick2509! I think the problem I have with that approach is timing. So I have a schedule that runs every second. After 10 seconds (or whatever the user wishes), that's when I load the next image. This allows me to show a countdown timer in the corner of the screen with the number of seconds remaining before the next image is shown.
My newbie thinking is I would need to set up another "temporary" schedule/clock interval of say like point one ( .1) seconds which would reduce the opacity. However, I found that approach to rather choppy depending on the size of the next image and reading it from disk. I also feel like have 2 more temporary schedules is not clean (1 to fade out, then 1 to fade in) Is this possible to do through some sprite animation? Also, how can I load the second image during the 'countdown' time without delaying said countdown? I've found that if I do a heavy load task, all pyglet processing stops until that task finishes. In real terms it seems like if i'm counting down from 10-9-8 and i do a load that takes 2 seconds, the countdown pauses at 8 for 2 seconds and resumes at . It'd be nice if I could load the image into a sprite in the "background" without affecting the countdown. I'm sure there is a clean/elegant way to do it, I'm just too new at this to know what it is. On Sunday, November 24, 2019 at 5:09:58 PM UTC-5, gimmick2509 . wrote: > > 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 <rbon...@gmail.com <javascript:>> > 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...@googlegroups.com <javascript:>. >> 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/f6f04243-c5d3-41e5-806f-505326316592%40googlegroups.com.