am trying to use both the upload function and camera function in my application. However, when I have the uploading and camera function code on the same class one of them doesn't work.
I've written a camera application, but when I want to show the camera's live preview(before taking the picture), the preview is rotated 90 degrees!
I continuously get OutOfMemory exceptions trying to decode an image from camera in my Android app.
How do I add a rectangular overlay (which should be more like a rectangular frame) in the camera preview? My application consists of a button that opens the camera upon clicking.
I have a problem with camera. I want to get picture in onPreviewFrame but it's never called. I opened a camera, set preview Display and preview Callback but nothing. I just want to understand where I was wrong.
When someone clicks on the ad and comes back to the app the app is not resuming.
I have added android:launchMode="singleInstance" in the mainfest and android:alwaysRetainTaskState="true" in the activity declaration in manifest.
I am not getting where am i going wrong.
My code for .java file is as follows :
public class MainActivity extends Activity implements AdListener{
public static int c
I am using MediaCodec low level Api in android to decode h264 raw stream received from IP CAMERA.
Raw stream from IP camera , receiving on TCP/IP connection.
To decode stream , My code is :
@Override
protected void onCreate(Bundle savedInstanceState) {
MediaCodec mCodecc;
MediaFormat mFormat;
BufferInfo mInfo;
ByteBuffer[] inputBuffers ;
ByteBuffer[] outputBuffers ;
}
protected void Init_
Android provides this code to make a camera preview appear face-up for all camera and screen orientations:
public static void setCameraDisplayOrientation(Activity activity,
int cameraId, android.hardware.Camera camera) {
android.hardware.Camera.CameraInfo info =
new android.hardware.Camera.CameraInfo();
android.hardware.Camera.getCameraInfo(cameraId, info);
in
I am developing a simple app for videos by using android camera. In my app I have a button having name "Make Video " and a list view which is for to show the video name recorded by my app. Now as I click the button it opens my mobile camera for recording but when I complete my recording the camera gives me two options. "Save" and "Discard".