开发者

android surfaceview is no longer visible after back from other activity

开发者 https://www.devze.com 2022-12-25 08:53 出处:网络
i have a question in developing some android program... i use surfaceview for camera preview. it works fine, but has one problem when i start other activity (by clicking something) and then back from

i have a question in developing some android program...

i use surfaceview for camera preview. it works fine, but has one problem when i start other activity (by clicking something) and then back from that a开发者_如何转开发ctivity. after that, surfaceview is no longer visible. (but onclicklistener is working)

but when i occur surfacecreated/destoryed by visible/invisible surfaceview in single activity, it works very good.

plz give me any help.


This is a 2.0 and 2.1-update1 issue. Was unable to reproduce on 2.2 and 1.5, 1.6. Canvas of the SurfaceView just displays black after returning from another activity. If you happen to find a workaround please note me.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号