2

In it's simplest explanation, I'm making a really small "interactive movie" app on Android.

In a nut shell, when the app is loaded, it will play a short movie (maybe a few seconds at most @ 12-24fps). I will then have 2 buttons displayed on the screen, and depending on what button is pressed, it I will play another short movie (5-10 seconds). While waiting for the user to make a decision, the movie will be looping.

The movie source is stop-motion photography so it's already chopped up into frames.

My question here is if I should use a Frame Animation technique, or if I should use a Movie player for this. All in all perhaps there's less than 100 still frames that make up the stop-motion. I was going to go the Frame Animation route, but I wasn't sure if having so many individual frames would kill the app so I thought I'd post here to see if anyone had any insight.

Thanks!

justinl
  • 10,448
  • 21
  • 70
  • 88

1 Answers1

2

After trial and error, it would seem that if you need to play a lot of large frames in your app, going the movie file route will be a better route. I had decent success on Android 2.2 with the frame animation technique, but when I tried it on Android 1.5 I ran into major "out of memory" exceptions and ended up having to scrap that method and instead, use a movie file of which I seek to different frames of the movie file to give me a similar effect.

justinl
  • 10,448
  • 21
  • 70
  • 88
  • wow actually the movie route is NOT better because there is small lag time in between stitching different movies together or seeking to different spots in the movie. I went back to the frame animation technique but ended up pre-loading all my images instead of dynamically assigning them and it seemed to do the trick :) – justinl Aug 24 '10 at 10:35
  • Which method did you eventually used for this? – Pasman Nov 25 '11 at 20:43
  • 1
    I ended up using the Frame Animation Technique (loading frames into a view and then playing through them like an animated gif) – justinl Nov 30 '11 at 07:38
  • @justinl When you say "preloading images", did you used any special techique to preload images or you've just used XML resource as the source of the ImageView? – sandalone Feb 07 '12 at 09:01
  • Yes, I believe I just used normal XML resources as the source of the ImageView but I seem to recall that I did all of the resource assignment using java instead of XML. It's been a while and I don't have access to that code any more but I remember assigning all the resources in Java for some reason... – justinl Feb 07 '12 at 12:35