On Sat, Jun 25, 2011 at 4:16 AM, alexandros mouzakidis <greatalexand...@gmail.com> wrote: > HI, i want to create a camera preview that is invisible, i have read > (here) that i only have to not use the SURFACE_TYPE_PUSH_BUFFERS but > when i do it my application crashes (i have tested it on the emulator) > the code is this > > public CameraPreview(SCamera context, DrawView view) { > super(context); > > mSurfaceView = new SurfaceView(context); > addView(mSurfaceView); > > // Install a SurfaceHolder.Callback so we get notified when > the > // underlying surface is created and destroyed. > mHolder = mSurfaceView.getHolder(); > mHolder.addCallback(this); > //mHolder.setType(SurfaceHolder.SURFACE_TYPE_NORMAL); > mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS); > drawView = view; > } > > Am i doing something wrong?
You are trying to make the SurfaceView invisible. Please don't do that. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- 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