| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ | 5 #ifndef MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ |
| 6 #define MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ | 6 #define MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/android/scoped_java_ref.h" | 11 #include "base/android/scoped_java_ref.h" |
| 12 | 12 |
| 13 namespace media { | 13 namespace media { |
| 14 | 14 |
| 15 class PhotoCapabilities { | 15 class PhotoCapabilities { |
| 16 public: | 16 public: |
| 17 // Focus modes from Java side, equivalent to media.mojom::FocusMode. | 17 // Focus modes from Java side, equivalent to media.mojom::MeteringMode, except |
| 18 // NOT_SET, which is used to signify absence of setting configuration. |
| 18 // A Java counterpart will be generated for this enum. | 19 // A Java counterpart will be generated for this enum. |
| 19 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.media | 20 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.media |
| 20 enum class AndroidFocusMode { | 21 enum class AndroidMeteringMode { |
| 22 NOT_SET, |
| 21 UNAVAILABLE, | 23 UNAVAILABLE, |
| 22 FIXED, | 24 FIXED, |
| 23 SINGLE_SHOT, | 25 SINGLE_SHOT, |
| 24 CONTINUOUS, | 26 CONTINUOUS, |
| 25 }; | 27 }; |
| 26 | 28 |
| 27 explicit PhotoCapabilities(base::android::ScopedJavaLocalRef<jobject> object); | 29 explicit PhotoCapabilities(base::android::ScopedJavaLocalRef<jobject> object); |
| 28 ~PhotoCapabilities(); | 30 ~PhotoCapabilities(); |
| 29 | 31 |
| 30 int getMinIso() const; | 32 int getMinIso() const; |
| 31 int getMaxIso() const; | 33 int getMaxIso() const; |
| 32 int getCurrentIso() const; | 34 int getCurrentIso() const; |
| 33 int getMinHeight() const; | 35 int getMinHeight() const; |
| 34 int getMaxHeight() const; | 36 int getMaxHeight() const; |
| 35 int getCurrentHeight() const; | 37 int getCurrentHeight() const; |
| 36 int getMinWidth() const; | 38 int getMinWidth() const; |
| 37 int getMaxWidth() const; | 39 int getMaxWidth() const; |
| 38 int getCurrentWidth() const; | 40 int getCurrentWidth() const; |
| 39 int getMinZoom() const; | 41 int getMinZoom() const; |
| 40 int getMaxZoom() const; | 42 int getMaxZoom() const; |
| 41 int getCurrentZoom() const; | 43 int getCurrentZoom() const; |
| 42 AndroidFocusMode getFocusMode() const; | 44 AndroidMeteringMode getFocusMode() const; |
| 45 AndroidMeteringMode getExposureMode() const; |
| 43 | 46 |
| 44 private: | 47 private: |
| 45 const base::android::ScopedJavaLocalRef<jobject> object_; | 48 const base::android::ScopedJavaLocalRef<jobject> object_; |
| 46 }; | 49 }; |
| 47 | 50 |
| 48 } // namespace media | 51 } // namespace media |
| 49 | 52 |
| 50 #endif // MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ | 53 #endif // MEDIA_CAPTURE_VIDEO_ANDROID_PHOTO_CAPABILITIES_H_ |
| OLD | NEW |