Apparence-io / CamerAwesome

📸 Embedding a camera experience within your own app shouldn't be that hard. A flutter plugin to integrate awesome Android / iOS camera experience.
https://ApparenceKit.dev
MIT License
981 stars 260 forks source link

.5 zoom not working on iOS when pinch screen #516

Open tomasweigenast opened 2 months ago

tomasweigenast commented 2 months ago

Steps to Reproduce

Create a custom layout of Camerawesome:

CameraAwesomeBuilder.custom(
    builder: (cameraState, preview) {
      return cameraState.when(
        onPreparingCamera: (state) {
          return _buildLoadingInterface();
        },
        onPhotoMode: (picState) {
          return _buildInterface(picState);
        },
      );
    },
    previewFit: CameraPreviewFit.cover,
    sensorConfig: SensorConfig.single(
      sensor: Sensor.position(SensorPosition.back),
      flashMode: FlashMode.auto,
      aspectRatio: CameraAspectRatios.ratio_16_9,
    ),
    progressIndicator: _buildLoadingInterface(),
    saveConfig: SaveConfig.photoAndVideo(
      exifPreferences:
          ExifPreferences(saveGPSLocation: true),
      photoPathBuilder: (sensors) async {
        return await _cameraProvider
            .photoPathBuilder(sensors.first);
      },
      videoPathBuilder: (sensors) async {
        return await _cameraProvider
            .videoPathBuilder(sensors.first);
      },
    ),
  );

Expected results

In the initial camera state, if the device has the ultrawide sensor (0.5 zoom), if you pinch the screen, the camera should zoom out.

Actual results

It only works on Android. On iOS it works with the AwesomeZoomSelector widget.

Your flutter version

Flutter 3.22.3 • channel stable • https://github.com/flutter/flutter.git
Framework • revision b0850beeb2 (9 weeks ago) • 2024-07-16 21:43:41 -0700
Engine • revision 235db911ba
Tools • Dart 3.4.4 • DevTools 2.34.3
Luvain9 commented 2 weeks ago

Same issue here