Release version 2.0.0-beta06 (#495)

* Bump version

* Fix javadocs
pull/501/head v2.0.0-beta06
Mattia Iavarone 5 years ago committed by GitHub
parent 0f9c7f0e17
commit 299fd76472
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      README.md
  2. 4
      cameraview/build.gradle
  3. 5
      cameraview/src/main/java/com/otaliastudios/cameraview/engine/CameraEngine.java
  4. 5
      cameraview/src/main/java/com/otaliastudios/cameraview/frame/FrameManager.java
  5. 3
      cameraview/src/main/java/com/otaliastudios/cameraview/picture/PictureRecorder.java
  6. 4
      cameraview/src/main/java/com/otaliastudios/cameraview/preview/CameraPreview.java
  7. 2
      cameraview/src/main/java/com/otaliastudios/cameraview/preview/GlCameraPreview.java
  8. 2
      cameraview/src/main/java/com/otaliastudios/cameraview/video/Full2VideoRecorder.java
  9. 2
      cameraview/src/main/java/com/otaliastudios/cameraview/video/VideoRecorder.java
  10. 9
      cameraview/src/main/java/com/otaliastudios/cameraview/video/encoding/MediaEncoder.java
  11. 3
      docs/_posts/2018-12-20-changelog.md
  12. 2
      docs/_posts/2018-12-20-install.md

@ -22,7 +22,7 @@ CameraView is a well documented, high-level library that makes capturing picture
addressing most of the common issues and needs, and still leaving you with flexibility where needed.
```groovy
compile 'com.otaliastudios:cameraview:2.0.0-beta05'
compile 'com.otaliastudios:cameraview:2.0.0-beta06'
```
- Fast & reliable

@ -3,7 +3,7 @@ apply plugin: 'com.github.dcendents.android-maven'
apply plugin: 'com.jfrog.bintray'
// Required by bintray
version = '2.0.0-beta05'
version = '2.0.0-beta06'
group = 'com.otaliastudios'
//region android dependencies
@ -145,7 +145,7 @@ task javadoc(type: Javadoc) {
}
exclude '**/BuildConfig.java'
exclude '**/R.java'
exclude '**/internal/**'
exclude '**/internal/**' // This excludes our internal folder!
}
task javadocJar(type: Jar, dependsOn: javadoc) {

@ -1270,6 +1270,9 @@ public abstract class CameraEngine implements
*
* I could not find the same evidence for videos, but I would say that the same things should
* apply, despite the capturing mechanism being different.
*
* @param reference the reference system
* @return the uncropped snapshot size
*/
@Nullable
public final Size getUncroppedSnapshotSize(@NonNull Reference reference) {
@ -1299,6 +1302,8 @@ public abstract class CameraEngine implements
* dimensions.
* But when it does, the {@link CameraPreview.SurfaceCallback} should be called,
* and this should be refreshed.
*
* @return the capture size
*/
@NonNull
@SuppressWarnings("WeakerAccess")

@ -155,6 +155,11 @@ public class FrameManager {
*
* In Camera1, this is always respected thanks to its internals.
*
* @param data data
* @param time timestamp
* @param rotation rotation
* @param previewSize preview size
* @param previewFormat format
* @return a new frame
*/
@NonNull

@ -27,7 +27,8 @@ public abstract class PictureRecorder {
/**
* Picture was taken or there was some error, if
* the result is null.
* @param result the result or null if there was some error.
* @param result the result or null if there was some error
* @param error the error or null if there wasn't any
*/
void onPictureResult(@Nullable PictureResult.Stub result, @Nullable Exception error);
}

@ -236,12 +236,14 @@ public abstract class CameraPreview<T extends View, Output> {
public void onDestroy() {}
/**
* Here we must crop the visible part by applying a > 1 scale to one of our
* Here we must crop the visible part by applying a scale greater than 1 to one of our
* dimensions. This way our internal aspect ratio (mOutputSurfaceWidth / mOutputSurfaceHeight)
* will match the preview size aspect ratio (mInputStreamWidth / mInputStreamHeight).
*
* There might still be some absolute difference (e.g. same ratio but bigger / smaller).
* However that should be already managed by the framework.
*
* @param op the op
*/
protected void crop(@NonNull Op<Void> op) {
// The base implementation does not support cropping.

@ -51,7 +51,7 @@ import javax.microedition.khronos.opengles.GL10;
* - The SurfaceTexture has buffers of data of mInputStreamSize
* - The SurfaceView hosts a view (and a surface) of size mOutputSurfaceSize.
* These are determined by the CameraView.onMeasure method.
* - We have a GL rich texture to be drawn (in the given method & thread).
* - We have a GL rich texture to be drawn (in the given method and thread).
*
* This class will provide rendering callbacks to anyone who registers a {@link RendererFrameCallback}.
* Callbacks are guaranteed to be called on the renderer thread, which means that we can fetch

@ -65,6 +65,8 @@ public class Full2VideoRecorder extends FullVideoRecorder {
/**
* This method should be called just once.
*
* @param stub the video stub
* @return a surface
* @throws PrepareException if prepare went wrong
*/

@ -42,6 +42,8 @@ public abstract class VideoRecorder {
/**
* Starts recording a video.
*
* @param stub the video stub
*/
public final void start(@NonNull VideoResult.Stub stub) {
mResult = stub;

@ -196,6 +196,9 @@ abstract class MediaEncoder {
/**
* Returns a new input buffer and index, waiting at most {@link #INPUT_TIMEOUT_US} if none is available.
* Callers should check the boolean result - true if the buffer was filled.
*
* @param holder the input buffer holder
* @return true if acquired
*/
@SuppressWarnings("WeakerAccess")
protected boolean tryAcquireInputBuffer(@NonNull InputBuffer holder) {
@ -215,6 +218,8 @@ abstract class MediaEncoder {
/**
* Returns a new input buffer and index, waiting indefinitely if none is available.
* The buffer should be written into, then the index should be passed to {@link #encodeInputBuffer(InputBuffer)}.
*
* @param holder the input buffer holder
*/
@SuppressWarnings({"StatementWithEmptyBody", "WeakerAccess"})
protected void acquireInputBuffer(@NonNull InputBuffer holder) {
@ -223,6 +228,8 @@ abstract class MediaEncoder {
/**
* Encode data into the {@link #mMediaCodec}.
*
* @param buffer the input buffer
*/
@SuppressWarnings("WeakerAccess")
protected void encodeInputBuffer(InputBuffer buffer) {
@ -253,6 +260,8 @@ abstract class MediaEncoder {
* If drainAll is not set, this returns after TIMEOUT_USEC if there is no more data to drain.
* If drainAll is set, we wait until we see EOS on the output.
* Calling this with drainAll set should be done once, right before stopping the muxer.
*
* @param drainAll whether to drain all
*/
@SuppressLint("LogNotTimber")
@SuppressWarnings("WeakerAccess")

@ -8,10 +8,11 @@ order: 3
New versions are released through GitHub, so the reference page is the [GitHub Releases](https://github.com/natario1/CameraView/releases) page.
### v2.0.0-beta06 (to be released)
### v2.0.0-beta06
- New: Full featured Camera2 integration! Use `cameraExperimental="true"` and `cameraEngine="camera2"` to test this out. ([#490][490])
- Improvement: we now choose a video recording profile that is compatible with the chosen size. Should fix some video recording issues. ([#477][477])
- Improvement: most internals are now open to be accessed by subclassing. Feel free to open PRs with more protected methods to be overriden. ([#494][494])
- **Breaking change**: some public classes have been moved to different packages. See [table here](../extra/v1-migration-guide.html#repackaging). ([#482][482])
- **Breaking change**: the listener methods `onFocusStart` and `onFocusEnd` are now called `onAutoFocusStart` and `onAutoFocusEnd`. ([#484][484])
- **Breaking change**: the gesture actions `focus` and `focusWithMarker` have been removed and replaced by `autoFocus`, which shows no marker. ([#484][484])

@ -24,7 +24,7 @@ allprojects {
Then simply download the latest version:
```groovy
api 'com.otaliastudios:cameraview:2.0.0-beta05'
api 'com.otaliastudios:cameraview:2.0.0-beta06'
```
No other configuration steps are needed.
Loading…
Cancel
Save