# Android video problem

**URL:** <https://discourse.processing.org/t/android-video-problem/26948>\
**Category:** Processing for Android\
**Created:** [January 10, 2021, 2:37pm UTC](https://discourse.processing.org/t/android-video-problem/26948 "2021-01-10T14:37:18Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 10, 2021, 2:37pm UTC](https://discourse.processing.org/t/android-video-problem/26948/1 "2021-01-10T14:37:18Z")

</div>

Hello, I can’t play video on my phone, but the picture is working, I don’t know what I did wrong I have looked at other forums but quite old ones I would be glad if you could help. HERE IS MY CODE

import processing.video.\*;

Movie mov;  
int timer=1500;

void setup() {  
size(displayWidth,displayHeight);  
mov=new Movie(this,“anime1.mp4”);

}

void draw() {  
background(0);

```
 page3();

```

}  
void page3() {  
image(mov,0,0,width,height/2);  
fill(255);

textSize(50);  
text(“John Doe, Yedi Olumcul Gunahtan Birini Isledikleri Icin Suclulari \n Cezalandirir. Once Pesine Dustugu Kurban Hangi Gunahtan Suclu?”, 0, height/2+100);

if (mouseX\>50 && mouseY\>height/2+400 && mouseX\<350 && mouseY\<height/2+550 && mousePressed==true ) {

```
 rect(50, height/2+400, 300, 150);
rect(width/2-130, height/2+400, 300, 150);
rect(width/2+400, height/2+400, 300, 150);
setup();

```

} else if (mouseX\>width/2-130 && mouseY\>height/2+400 && mouseX\<width/2+170 && mouseY\<height/2+550 && mousePressed==true) {

```
 rect(50, height/2+400, 300, 150);
rect(width/2-130, height/2+400, 300, 150);
rect(width/2+400, height/2+400, 300, 150);

setup();

```

} else if (mouseX\>width/2+400 && mouseY\>height/2+400 && mouseX\<width/2+700 && mouseY\<height/2+550 && mousePressed==true) {

```
 rect(50, height/2+400, 300, 150);
rect(width/2-130, height/2+400, 300, 150);
rect(width/2+400, height/2+400, 300, 150);
setup();

```

} else {  
fill(0);  
stroke(255);  
rect(50, height/2+400, 300, 150);  
rect(width/2-130, height/2+400, 300, 150);  
rect(width/2+400, height/2+400, 300, 150);  
fill(255);  
text(“Kibir”, 145, height/2+488);  
text(“Tembellik”, width/2-70,height/2+488);  
text(“Kiskanclik”, width/2+450, height/2+488);  
textSize(60);  
text("KALAN SANIYE : "+timer/100.0,420,height/2+900);  
timer–;

}  
}

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 10, 2021, 2:50pm UTC](https://discourse.processing.org/t/android-video-problem/26948/2 "2021-01-10T14:50:59Z")

</div>

keep gives me this error FATAL EXCEPTION: Animation Thread

---

<div class="post-metadata">

**Author:** ![akenaton](https://avatars.discourse-cdn.com/v4/letter/a/a88e4f/32.png) [@akenaton](https://discourse.processing.org/u/akenaton)\
**Post date:** [January 10, 2021, 7:04pm UTC](https://discourse.processing.org/t/android-video-problem/26948/3 "2021-01-10T19:04:09Z")

</div>

@clay21 === Processing videos do not work with android and there are a lot of posts about android+video on the forum…

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 10, 2021, 10:59pm UTC](https://discourse.processing.org/t/android-video-problem/26948/4 "2021-01-10T22:59:34Z")

</div>

yeah but they’re old and i cant find any library for android video so can you help me really i didnt find anything im not that pro at this 🙂

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 11, 2021, 1:46pm UTC](https://discourse.processing.org/t/android-video-problem/26948/5 "2021-01-11T13:46:12Z")

</div>

I saw you in every android video forum, I understand that you are trying to teach the code, but I believe that I will learn better by studying the code.

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 11, 2021, 1:47pm UTC](https://discourse.processing.org/t/android-video-problem/26948/6 "2021-01-11T13:47:00Z")

</div>

can you just send me a simple android video code that works please

---

<div class="post-metadata">

**Author:** ![noel](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/noel/32/213_2.png) [@noel](https://discourse.processing.org/u/noel)\
**Post date:** [January 11, 2021, 2:06pm UTC](https://discourse.processing.org/t/android-video-problem/26948/7 "2021-01-11T14:06:56Z")

</div>

Not a simple maybe. I’ve just tested it [with this video](https://drive.google.com/file/d/1PO6x1kKs85_cPs1TzOOXjgsNp1dFjiRt/view?usp=sharing), on an Android 10 and a Lollipop device.  
[Here’s the code.](https://github.com/EmmanuelPil/Android-java-code-utilities-widgets-for-Processing-for-Android/blob/master/Video%20player)  
Edit: If you are using APDE, you have to move fullScreen(); from settings() to setup(), because in the last version, settings() can be used anymore.

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 11, 2021, 3:26pm UTC](https://discourse.processing.org/t/android-video-problem/26948/8 "2021-01-11T15:26:21Z")

</div>

what i want to do is just play videos i don’t want to give any features

---

<div class="post-metadata">

**Author:** ![clay21](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@clay21](https://discourse.processing.org/u/clay21)\
**Post date:** [January 11, 2021, 3:27pm UTC](https://discourse.processing.org/t/android-video-problem/26948/9 "2021-01-11T15:27:02Z")

</div>

Will my video not work unless I write all of this?

thanks for the answer by the way

---

<div class="post-metadata">

**Author:** ![akenaton](https://avatars.discourse-cdn.com/v4/letter/a/a88e4f/32.png) [@akenaton](https://discourse.processing.org/u/akenaton)\
**Post date:** [January 11, 2021, 3:38pm UTC](https://discourse.processing.org/t/android-video-problem/26948/10 "2021-01-11T15:38:12Z")

</div>

@clay21 === dont teach nothing, i am an android developper who likes P5 and tryes to help when he has some time left…As for videos, sorry there is only the ketai library for helping wrapping the android code: if you dont use it, you have to write and code yourself…looking what was pubiished in the forum

---

<div class="post-metadata">

**Author:** ![noel](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/noel/32/213_2.png) [@noel](https://discourse.processing.org/u/noel)\
**Post date:** [January 11, 2021, 4:12pm UTC](https://discourse.processing.org/t/android-video-problem/26948/11 "2021-01-11T16:12:48Z")

</div>

> [@clay21](#):
>
> but I believe that I will learn better by studying the code.

That’s the way I learn also. Take a working code and strip it all to the part you just want. But at least you have to try.
