Hello,
I created a layout where my surface view has been resized from the
"original size", I did the following:

        ViewGroup.LayoutParams params =
mSurfaceView.getLayoutParams();
        int
mPixels=getResources().getDimensionPixelSize(R.dimen.profile_pic_dimension); //
200
        params.width=mPixels;
        params.height=mPixels;
        mSurfaceView.setLayoutParams(params);
        
this.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
and I obta
in a view like this:
http://goo.gl/8ZXvR

but then.. whenever I take the picture.. it doesnt saves as how I can
see it on the view... but instead it saves it normal size like if the
view was taking the whole screen (like if the surfaceview was never
resized).

I tried using this:

Camera.ShutterCallback mShutterCallback = new Camera.ShutterCallback()
{
        @Override
        public void onShutter() {
                Camera.Parameters p = mCamera.getParameters();
                p.setPictureSize(mSurfaceView.getWidth(),
mSurfaceView.getHeight());
               mCamera.setParameters(p);
                }
        };

but still didnt get the image size i wanted to.
Any help to achieve this would be greatly appreciated.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to