While creating a service as need be, surfaceView & surfaceHolder are being passed via intent to a service. How can the same be extracted at the service side.
Have been trying this but not able to succeed.
Object view_obj = intent.getExtras().get("surfaceView");
mSurfaceView = (SurfaceView) view_obj;
mSurfaceHolder = (SurfaceHolder) holder_obj;
You cannot pass any
View via an
Intent extra. While you could implement
Parcelable on your
SurfaceHolder implementation, all that will do is give your service a copy of the
SurfaceHolder, one that is not attached to any