mirror of
https://gitee.com/shuto/customCamera.git
synced 2026-05-02 00:07:24 +08:00
Modification des fichiers après le premier pull request
This commit is contained in:
@@ -1,14 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/globalLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" >
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/camera_preview"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="1067dp"
|
||||
android:gravity="center" >
|
||||
android:layout_height="fill_parent" >
|
||||
</FrameLayout>
|
||||
|
||||
<ImageView
|
||||
|
||||
@@ -200,8 +200,6 @@ public class CameraActivity extends Activity {
|
||||
|
||||
DisplayMetrics dm = new DisplayMetrics();
|
||||
getWindowManager().getDefaultDisplay().getMetrics(dm);
|
||||
final int widthScreen = dm.widthPixels;
|
||||
final int heightScreen = dm.heightPixels;
|
||||
|
||||
FrameLayout cameraPreview = (FrameLayout) findViewById(R.id.camera_preview);
|
||||
RelativeLayout.LayoutParams paramsCameraPreview =
|
||||
@@ -218,7 +216,9 @@ public class CameraActivity extends Activity {
|
||||
maxSize = camParameters.height;
|
||||
minSize = camParameters.width;
|
||||
}
|
||||
|
||||
|
||||
int widthScreen = dm.widthPixels;
|
||||
int heightScreen = dm.heightPixels;
|
||||
float ratio;
|
||||
if (widthScreen > heightScreen) {
|
||||
paramsCameraPreview.height = LayoutParams.FILL_PARENT;
|
||||
|
||||
Reference in New Issue
Block a user