What "continuous jpeg frames"? The only 'continuous' frames in the viewfinder are the preview frames, and those are not jpeg: they are YCrCb at 15 fps. Unless you make your own jpeg out of YCrBb, but why bother? You need a Bitmap for the Canvas for SurfaceView anyway: you may as well use RGB or ARGB instead of JPEG (see Bitmap.Config). Then no conversion is necessary. In fact, it is not useful with a Canvas, since it is not among the formats listed on Bitmap.Config.
Now if you are willing to live with the Camera object's preview, you can let it display the frames, but capture the frames also for your own processing using the Camera.setPreviewCallback() method to register your own handler for each frame. I realize this does not do exactly what you asked for, but it is a lot less work than what you are proposing, and gives you much of what you probably really need. On Nov 17, 11:26 am, "s.rawat" <imsaurabhra...@gmail.com> wrote: > Hi, > I am trying to by-pass the default camera viewfinder and making an > application which will give the Surfaceview some continuous jpeg frames > (instead of getting it from Camera view finder)., but I have realized its > quiet a gigantic task and I have to modify the files in the > framework/core/jni(native calls), framework/core/java and services and > client as well and even the CameraHardware.cpp for this > as Surfaceview(Surfaceholder instance) connected with the mCamera > instance (as the fully initialized SurfaceHolder is to be passed to the > setPreviewDisplay()(which is connectd with the Camera Hardware code).So i > wanted to ask these questions: > > (1) Is it possible to bypass the default camera view finder at the > application (android application code) level. > (2) I am able to generate the video by passing the continuous jpeg frames to > * image view*(running in a thread being spawned form the main thread until > i press stop), can I also in some way pass these frames to Surface > holder(surface view so that I can see the video in the viewfinder- my > understanding is that Surface holder is responsible for the viewfinder on > the camera) > (3) Any other way to implement this without delving deep into the Android > framework. > Plz suggest . > Rgds and Thanks for your reply > Saurabh -- 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