-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[camera] MediaSettings parameter for createCameraWithSettings #3586
Conversation
This is main PR. Platform interface's PR is here: #3615 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution. This is very nice feature to have. Can you share a video capture after this change?
packages/camera/camera/example/integration_test/camera_test.dart
Outdated
Show resolved
Hide resolved
MediaSettings.low changed to const MediaSettings(resolutionPreset: ResolutionPreset.low).
packages/camera/camera/README.md
Outdated
@@ -100,6 +100,7 @@ Here is a small example flutter app displaying a full screen camera preview. | |||
<?code-excerpt "readme_full_example.dart (FullAppExample)"?> | |||
```dart | |||
import 'package:camera/camera.dart'; | |||
import 'package:camera_platform_interface/camera_platform_interface.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still here.
@@ -4,6 +4,7 @@ | |||
|
|||
// #docregion FullAppExample | |||
import 'package:camera/camera.dart'; | |||
import 'package:camera_platform_interface/camera_platform_interface.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same.
CameraController( | ||
CameraDescription description, | ||
this.resolutionPreset, { | ||
this.enableAudio = true, | ||
ResolutionPreset resolutionPreset, { | ||
bool enableAudio = true, | ||
this.imageFormatGroup, | ||
}) : mediaSettings = MediaSettings( | ||
resolutionPreset: resolutionPreset, enableAudio: enableAudio), | ||
super(CameraValue.uninitialized(description)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This hasn't been addressed.
Sorry, what did you mean? |
|
@stuartmorgan |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…r#3586) This PR is for enabling fps and bitrate control of recorded video. Allow users to more control over recorded video size. `CameraPlatform.createCameraWithSettings` is added, leaving original `CameraPlatform.createCamera` commented as deprecated. So this is not breaking change. Tested on a set of mobile devices. Web support depends on browser (perfect with Firefox). Fixes flutter/flutter#54339
flutter/packages@f4719ca...2dfe645 2024-05-06 [email protected] [camera] MediaSettings parameter for createCameraWithSettings (flutter/packages#3586) 2024-05-06 [email protected] Fix unnecessary toList/fromList calls during encode/decode process (flutter/packages#6426) 2024-05-03 [email protected] Roll Flutter from bf7191f to f1037a0 (21 revisions) (flutter/packages#6641) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…ed) (flutter#5223) This is the `platform implementations` part of `camera` PR flutter#3586. `camera_platform_interface: 2.6.0` merged and published in PR flutter#3615. Now repeating steps 3,4 (see [Changing federated plugins](https://github.com/flutter/flutter/wiki/Contributing-to-Plugins-and-Packages#changing-federated-plugins)), because `camera/camera` depends on implementations `camera/camera_android`, `camera/camera_web` etc.
…r#3586) This PR is for enabling fps and bitrate control of recorded video. Allow users to more control over recorded video size. `CameraPlatform.createCameraWithSettings` is added, leaving original `CameraPlatform.createCamera` commented as deprecated. So this is not breaking change. Tested on a set of mobile devices. Web support depends on browser (perfect with Firefox). Fixes flutter/flutter#54339
…ed) (flutter#5223) ## Platform implementations of federated plugin This is the `platform implementations` part of `camera` PR flutter#3586. `camera_platform_interface: 2.6.0` merged and published in PR flutter#3615. Now repeating steps 3,4 (see [Changing federated plugins](https://github.com/flutter/flutter/wiki/Contributing-to-Plugins-and-Packages#changing-federated-plugins)), because `camera/camera` depends on implementations `camera/camera_android`, `camera/camera_web` etc.
…r#3586) This PR is for enabling fps and bitrate control of recorded video. Allow users to more control over recorded video size. `CameraPlatform.createCameraWithSettings` is added, leaving original `CameraPlatform.createCamera` commented as deprecated. So this is not breaking change. Tested on a set of mobile devices. Web support depends on browser (perfect with Firefox). Fixes flutter/flutter#54339
This PR is for enabling fps and bitrate control of recorded video.
Allow users to more control over recorded video size.
CameraPlatform.createCameraWithSettings
is added, leaving originalCameraPlatform.createCamera
commented as deprecated. So this is not breaking change.Tested on a set of mobile devices.
Web support depends on browser (perfect with Firefox).
Fixes flutter/flutter#54339