We have never tested that scenario on the G1 or the emulator and I would be surprised if it worked. The hardware video decoder can only support one decode at a time, which means the second stream would fall back to a software codec. I'm not saying it can't work, but if it doesn't, we probably won't be jumping on this bug for awhile.
There is no such thing as an application "running in background" on Android. Take a look at the Activity Lifecycle documentation on the android.com developer's site. If your application does not have focus, it is not "running" and you need to save your state because your application may be killed at any time. If you need something to run in the background, it must be a service, and a service is not an application. CPU cycles equate directly to battery life, so services should be lightweight processes. I think you need to scale down your expectations a little, this is not a desktop computer connected to the power grid. On Jan 15, 6:08 pm, mongd <mongdl...@gmail.com> wrote: > Hi, I'm trying to implement a simple media player that plays 2 > different videos at the same time. (I mean on the same activity.) > Based on the media player in API demos, I added another surface view, > copied the rest of the code for the media player and changed the names > of variables accordingly. > This code kept crashing when the second media player tried prepare() > without throwing exception message. Is there anyone who know how to > implement this kind of functionality on android? Or, does not Android > allow this kind of implementation? > > Also, another question is, is it possible to run the same application > twice at the same time? > I mean... as far as I understood, I can make applications run in > background by using 'service', so in this way, I guess it would be > possible to run the same application when one of them is running in > background. Am I right? > > I just started to look into Android, so I'm trying to figure out what > Android can/can't do. > Please help me~ =D > > Thank you so much in advance. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---