wechat_camera_picker_plus 1.0.3 copy "wechat_camera_picker_plus: ^1.0.3" to clipboard
wechat_camera_picker_plus: ^1.0.3 copied to clipboard

A camera picker for Flutter projects based on WeChat's UI, which is also a separate runnable extension to the wechat_assets_picker_plus.

Flutter WeChat Camera Picker #

MIT License pub dart

A camera picker based on WeChat's UI which is a separate runnable extension to wechat_assets_picker_plus. The package based on camera for camera functions and photo_manager for asset implementation.

πŸ“· Screenshots #

1 2 3 4 5

Features ✨ #

  • ♻️ Fully implementable with States override
  • πŸ’š 99% similar to WeChat style
  • πŸ“· Picture taking support
  • πŸŽ₯ Video recording support
    • ⏱ Duration limitation support
    • πŸ” Scale when recording support
  • β˜€οΈ Exposure adjust support
  • πŸ”οΈ Scale with pinch support
  • πŸ’± i18n support
    • βͺ RTL language support
  • 🎏 Fully customizable theme
  • πŸ–Ύ Foreground custom widget builder support
  • πŸ•ΉοΈ Intercept saving with custom process

πŸ“¦ Installation #

Add the package to your pubspec.yaml:

dependencies:
  wechat_camera_picker_plus: ^latest_version
dependencies:
  flutter pub get

Setup #

Android 13 (API 33) permissions

If you don't need to take photos or videos, consider removing relevant permission in your apps, more specifically:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.your.app">
    <!-- Add this if you need to take photos. -->
    <uses-permission android:name="android.permission.READ_MEDIA_IMAGES" />
    <!-- Add this if you need to take videos. -->
    <uses-permission android:name="android.permission.READ_MEDIA_VIDEO" />
</manifest>

πŸš€ Usage #

Import the package:

import 'package:wechat_camera_picker_plus/wechat_camera_picker_plus.dart';

Usage πŸ“– #

Record Video:

  final entity = await CameraPicker.pickFromCamera(
      Get.context!,
      pickerConfig: CameraPickerConfig(
        enableRecording: true,
        onlyEnableRecording: true,
        resolutionPreset: ResolutionPreset.high,
        maximumRecordingDuration: const Duration(seconds: 60),
        minimumRecordingDuration: const Duration(seconds: 7),
        enableTapRecording: true,
        permissionRequestOption: PermissionRequestOption(
          androidPermission:
              AndroidPermission(type: RequestType.all, mediaLocation: true),
        ),
        textDelegate: EnglishCameraPickerTextDelegate(),
        onMinimumRecordDurationNotMet: () {
          'Minimum recording duration is 7 seconds'.errorToast();
        },
      ),
    );

  final file = await entity?.file;

Take Picture:

  final entity = await CameraPicker.pickFromCamera(
      Get.context!,
      pickerConfig: CameraPickerConfig(
        enableRecording: false,
        resolutionPreset: ResolutionPreset.high,
        permissionRequestOption: PermissionRequestOption(
          androidPermission:
              AndroidPermission(type: RequestType.all, mediaLocation: true),
        ),
        textDelegate: EnglishCameraPickerTextDelegate(),
      ),
    );

  final file = await entity?.file;

πŸ’­ Frequently asked question #

Why the orientation behavior is strange on iOS? Currently, the preview is not correctly synced on the iOS. You can find more details in this issue: https://github.com/flutter/flutter/issues/89216 . Other than that, please submit issues to describe your question.

πŸ“„ License #

This project is licensed under the MIT License. See the LICENSE file for details.

Contributors ✨ #

Thank goes to these wonderful people (emoji key):


Alex Li

πŸ’» 🎨 πŸ“– πŸ’‘ πŸ€” 🚧 πŸ’¬ πŸ‘€

Caijinglong

πŸ’‘ πŸ€”

Lael

πŸ“–

mjl0602

πŸ’» πŸ€”

AliasWang

πŸ’» πŸ€”

leftcoding

πŸ›

Luong The Vinh

πŸ’»

luomo-pro

️️️️♿️ πŸ›

LeonardoZhu

πŸ’»

This project follows the all-contributors specification. Contributions of any kind welcome!

🌐 Author #

Made with ❀️ by Deepak.

0
likes
140
points
68
downloads
screenshot

Publisher

unverified uploader

Weekly Downloads

A camera picker for Flutter projects based on WeChat's UI, which is also a separate runnable extension to the wechat_assets_picker_plus.

Repository (GitHub)
View/report issues

Topics

#picker #camera #image #video #wechat

Documentation

API reference

License

MIT (license)

Dependencies

camera, camera_platform_interface, collection, flutter, meta, path, photo_manager, photo_manager_image_provider, sensors_plus, uuid, video_player, wechat_picker_library

More

Packages that depend on wechat_camera_picker_plus