http://osdir.com/ml/Android-Developers/2010-03/msg00077.html
Mark Murphy mentioned a VideoView can overlay camera preview (based on PUSH_BUFFERS surfaceview). I tested the solution. It seems Android doesn't let more than one SurfaceView with its setting SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS work simultaneously, no matter how we layout the two SurfaceViews (with RelativeLayout, FramwLayout or whatever). When I debug the android program, I find both VideoView and camera preview need use SEC_Overlay(hardware overlay?) but the overlay is exclusively used (I understand that's hardware ovelay), resulting in either movie video show or live camera video display on the screen. Anyway, one non PUSH_BUFFER surface view can overlay one PUSH_BUFFER surface view. If we implement live camera frame display based on a SurfacceView (with a thread for update/draw on canvas) , the live camera preview can overlay a playing movie video. Could guys have more comments? Thanks. ================================================= http://osdir.com/ml/Android-Developers/2010-03/msg00077.html use RelativeLayout. Put the camera preview as the first child of the RelativeLayout and the VideoView as the second child. The VideoView will appear to be "on top of" the SurfaceView for the camera preview. BTW, VideoView really is a SurfaceView. Note that you may decide someday to use a SurfaceView and MediaPlayer, rather than a VideoView, so you can get more control on video playback. -- 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