Giter VIP home page Giter VIP logo

cameraview's Introduction

Build Status Code Coverage Release Issues Funding

This is a new major version (v2) of the library. It includes breaking changes, signature changes and new functionality. Keep reading if interested, or head to the legacy-v1 branch to read v1 documentation and info.

The v2 version is still in beta and its API surface might still change. Functions might be renamed, options might be removed (though they probably won't), signatures might change. If this is a problem, please wait for the final release and keep using v1.

CameraView

CameraView is a well documented, high-level library that makes capturing pictures and videos easy, addressing most of the common issues and needs, and still leaving you with flexibility where needed.

compile 'com.otaliastudios:cameraview:2.0.0-beta06'
  • Fast & reliable
  • Gestures support [docs]
  • Camera1 or Camera2 powered engine [docs]
  • Frame processing support [docs]
  • Watermarks & animated overlays [docs]
  • OpenGL powered preview [docs]
  • Take high-quality content with takePicture and takeVideo [docs]
  • Take super-fast snapshots with takePictureSnapshot and takeVideoSnapshot [docs]
  • Smart sizing: create a CameraView of any size [docs]
  • Control HDR, flash, zoom, white balance, exposure, location, grid drawing & more [docs]
  • Lightweight
  • Works down to API level 15
  • Well tested

Read the official website for setup instructions and documentation. You might also be interested in changelog or in the v1 migration guide.

If you like the project, use it with profit, or simply want to thank back, please consider donating to the project now! You can either make a one time donation or become a sponsor, in which case your company logo will immediately show up here.

Thank you for any contribution - it is a nice reward for what has been done until now, and a motivation boost to push the library forward.

<com.otaliastudios.cameraview.CameraView
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    app:cameraPictureSizeMinWidth="@integer/picture_min_width"
    app:cameraPictureSizeMinHeight="@integer/picture_min_height"
    app:cameraPictureSizeMaxWidth="@integer/picture_max_width"
    app:cameraPictureSizeMaxHeight="@integer/picture_max_height"
    app:cameraPictureSizeMinArea="@integer/picture_min_area"
    app:cameraPictureSizeMaxArea="@integer/picture_max_area"
    app:cameraPictureSizeSmallest="false|true"
    app:cameraPictureSizeBiggest="false|true"
    app:cameraPictureSizeAspectRatio="@string/video_ratio"
    app:cameraVideoSizeMinWidth="@integer/video_min_width"
    app:cameraVideoSizeMinHeight="@integer/video_min_height"
    app:cameraVideoSizeMaxWidth="@integer/video_max_width"
    app:cameraVideoSizeMaxHeight="@integer/video_max_height"
    app:cameraVideoSizeMinArea="@integer/video_min_area"
    app:cameraVideoSizeMaxArea="@integer/video_max_area"
    app:cameraVideoSizeSmallest="false|true"
    app:cameraVideoSizeBiggest="false|true"
    app:cameraVideoSizeAspectRatio="@string/video_ratio"
    app:cameraSnapshotMaxWidth="@integer/snapshot_max_width"
    app:cameraSnapshotMaxHeight="@integer/snapshot_max_height"
    app:cameraVideoBitRate="@integer/video_bit_rate"
    app:cameraAudioBitRate="@integer/audio_bit_rate"
    app:cameraGestureTap="none|autoFocus|takePicture"
    app:cameraGestureLongTap="none|autoFocus|takePicture"
    app:cameraGesturePinch="none|zoom|exposureCorrection"
    app:cameraGestureScrollHorizontal="none|zoom|exposureCorrection"
    app:cameraGestureScrollVertical="none|zoom|exposureCorrection"
    app:cameraEngine="camera1|camera2"
    app:cameraPreview="glSurface|surface|texture"
    app:cameraFacing="back|front"
    app:cameraHdr="on|off"
    app:cameraFlash="on|auto|torch|off"
    app:cameraWhiteBalance="auto|cloudy|daylight|fluorescent|incandescent"
    app:cameraMode="picture|video"
    app:cameraAudio="on|off"
    app:cameraGrid="draw3x3|draw4x4|drawPhi|off"
    app:cameraGridColor="@color/grid_color"
    app:cameraPlaySounds="true|false"
    app:cameraVideoMaxSize="@integer/video_max_size"
    app:cameraVideoMaxDuration="@integer/video_max_duration"
    app:cameraVideoCodec="deviceDefault|h264|h263"
    app:cameraAutoFocusResetDelay="@integer/autofocus_delay"
    app:cameraAutoFocusMarker="@string/cameraview_default_autofocus_marker"
    app:cameraUseDeviceOrientation="true|false"
    app:cameraExperimental="false|true">
    
    <!-- Watermark! -->
    <ImageView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="bottom|end"
        android:src="@drawable/watermark"
        app:layout_drawOnPreview="true|false"
        app:layout_drawOnPictureSnapshot="true|false"
        app:layout_drawOnVideoSnapshot="true|false"/>
        
</com.otaliastudios.cameraview.CameraView>

Backers

Thanks to all backers! Become a backer.

Sponsors

Thanks to sponsors! Become a sponsor and have your logo here.

cameraview's People

Contributors

natario1 avatar dwillmc avatar yperess avatar noln avatar andreidiaconu avatar android-dataticket avatar m1r0n41k avatar eomine avatar agrawalsuneet avatar nethergrim avatar anpez avatar aartikov avatar austinkettner avatar caleb-allen avatar calebdre avatar cneuwirt avatar tryadelion avatar suomi35 avatar johnson145 avatar jonasrottmann avatar josh-burton avatar thehollidayinn avatar larryng avatar mahdi-ninja avatar matfl avatar elevenfive avatar rocketrider avatar wosiu avatar robertomorelos avatar ssakhavi avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.