LandScape App. freezes during launching

by scheme » Thu, 03 Sep 2009 01:46:48 GMT


Sponsored Links
 I had written landscape app. which use surface view and camera.
It works fine mostly.

However, The weird thing is that the app sometimes (once a 5~6 times)
freezes when I started it.
The DDMS spits out following log.

09-02 10:58:29.191: WARN/WindowManager(1132): App freeze timeout
expired.
09-02 10:58:29.201: WARN/WindowManager(1132): Force clearing freeze:
AppWindowToken{43b4ea00 token=HistoryRecord{4386bcc0 {com.home.camera/
com.home.camera.Camera}}}
09-02 10:58:29.251: WARN/SurfaceFlinger(1132): timeout expired
mFreezeDisplay=1, mFreezeCount=0

The following lines are added in the manifest.xml

android:configChanges="orientation|keyboardHidden"
android:screenOrientation="landscape"

I have struggled but have no progress.

Any Ideas?
Thnks in advance.

--~--~---------~--~----~------------~-------~--~----~



LandScape App. freezes during launching

by Dianne Hackborn » Thu, 03 Sep 2009 01:57:27 GMT


 What is your app doing in the debugger?  That message is saying that the
window manager gave up waiting for the app to draw all of its windows before
unfreezing the screen in the new orientation, so for some reason you aren't
getting your windows/surfaces drawn.






-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


LandScape App. freezes during launching

by scheme » Thu, 03 Sep 2009 22:56:34 GMT


 I had checked my app. again and I found that the onCreate function
sometimes take more than 5 sec. to complete.
After modify the onCreate function, the problem is gone.

Thanks.




--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Non blocking io with LocalSocket

Hi,

Is it possible to do non blocking IO with LocalSocket?

-- 
Mike Cardwell
(https://secure.grepular.com/) (http://perlcv.com/)

--~--~---------~--~----~------------~-------~--~----~

2. Problems trying to play RTSP stream from VLC

For the last few days I've been trying to play an RTSP stream on the
physical device (dev phone) from an instance of VLC (0.9.9) running on
my machine, but I've had no success.

I started with some mp4 video files that I verified will play off the
SD card on the device.  I took one of these files and published an
RTSP stream from an instance of a VLC server running on my laptop.
Here's the output string in VLC that is used to create the stream from
the base mp4:

:sout=#transcode
{vcodec=mp4v,vb=200,scale=1,acodec=mp4a,ab=16,channels=2}:duplicate
{dst=display,dst=rtp{dst=,mux=ts,port=1234,sdp=rtsp://
192.168.1.100:1234/stream.sdp}}

Which corresponds to:

Video codec - MPEG-4
Audio codec - AAC
Video bitrate - 200 kbps
Audio bitrate - 16 kbps
Resolution - 320x240

I can publish this stream in the VLC server and consume it from a VLC
player (running on the same machine as the server or from another
machine on the network) without any problems by simply telling it to
play the stream at this address:

rtsp://192.168.1.100:1234/stream.sdp

The problem I'm having is trying to play this same stream from the
device.  I'm using the 1.1 release of the SDK, and the project I'm
using to test this is the ApiDemos project
(MediaPlayerDemo_Video.java).  All I'm doing is setting the "path"
variable in code to the rtsp:// link above.  When this line executes:

mMediaPlayer.prepare();

This exception is thrown:

java.io.IOException: Prepare failed.: status=0xFFFFFFFF

So it's not clear to me what exactly the failure is.  I've tried
tinkering with the VLC output a million different ways, but I can't
get around this error.  I've tried using several different mp4 source
files and even some wmv's.

I'm by no means an expert in streaming video protocols, but it seems
that VLC may not be able to produce an RTSP stream that Android is
able to recognize, and that's really what I'm looking for an answer
to.  I'm hoping someone has been able to take an mp4 file (or a source
file of any video format, really) and, in VLC, transcode it and make
it available in an RTSP stream that the device is able to play back.
I've read some other posts that are semi-related to the RTSP issues
I'm seeing here, but I don't think I've seen anything yet where
someone confirmed outright that they were able to play an RTSP stream
from VLC to Android.  I'm going to post this in the VideoLAN forums as
well.  Any help is appreciated.  Thanks.

--~--~---------~--~----~------------~-------~--~----~

3. Android and neighbour cells

4. Capturing ACTION_MOVE events over multiple OnTouchListener

5. Reg Android UI Clock

6. how to know which file the user selected on another application?

7. Changing between multiple views