# About how to load images after the video is over

**URL:** https://discourse.processing.org/t/about-how-to-load-images-after-the-video-is-over/29749
**Category:** Libraries
**Created:** [April 30, 2021, 4:54pm UTC](https://discourse.processing.org/t/about-how-to-load-images-after-the-video-is-over/29749 "2021-04-30T16:54:11Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Yujung](https://avatars.discourse-cdn.com/v4/letter/y/a9a28c/32.png) [@Yujung](https://discourse.processing.org/u/Yujung)
#### Post date: [April 30, 2021, 4:54pm UTC](https://discourse.processing.org/t/about-how-to-load-images-after-the-video-is-over/29749/1 "2021-04-30T16:54:11Z")

</div>

I wanted to make two images of case2 appear after the ‘intro’ video, but it didn’t work. What could be the problem?

import processing.video.\*;  
Movie intro;

int caseNum=1;  
PImage start;  
PImage press;

void setup() {  
size (1423, 800);  
intro=new Movie(this, "intro.mp4 ");  
intro.play();  
}

void draw() {  
switch(caseNum) {  
case 1:  
if (intro.available()==true) {  
intro.read();  
}  
image(intro, 0, 0, width, height);  
if (intro.time() \>= intro.duration()) {  
intro.stop();  
caseNum=2;  
}  
break;

case 2:  
start=loadImage(“start.png”);  
image(start, 0, 0);  
press=loadImage(“press.png”);  
image(press, 500, 620);  
break;

```
void mousePressed() {

  switch(caseNum) {
  case 1:
    break;
  }
}
```

---

<div class="post-metadata">

### Author: ![micuat](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/micuat/32/19407_2.png) [@micuat](https://discourse.processing.org/u/micuat)
#### Post date: [April 30, 2021, 7:21pm UTC](https://discourse.processing.org/t/about-how-to-load-images-after-the-video-is-over/29749/2 "2021-04-30T19:21:49Z")

</div>

please format the code!

[https://www.khm.de/~n.hieda/discourse-code.mp4](https://www.khm.de/~n.hieda/discourse-code.mp4)

---

<div class="post-metadata">

### Author: ![th75](https://avatars.discourse-cdn.com/v4/letter/t/ebca7d/32.png) [@th75](https://discourse.processing.org/u/th75)
#### Post date: [May 1, 2021, 3:08pm UTC](https://discourse.processing.org/t/about-how-to-load-images-after-the-video-is-over/29749/3 "2021-05-01T15:08:51Z")

</div>

hi,  
from the code here, you have void mousePressed() inside your draw() … not good : [mousePressed](https://processing.org/reference/mousePressed_.html)

then you can set caseNum =2 to check if images display as expected,  
in your code for each frame you call loadImage(“start.png”);, are you sure it’s what you want to do, if png files doesn’t change, you need to call it only one time
