Skip to content

Commit 61c8a40

Browse files
authored
Updating CameraCaptureUI Spec Doc (#4895)
* Addressing comments from PR-review! * addressing comments * Addressing comment
1 parent b05c65c commit 61c8a40

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

specs/CameraCaptureUI/CameraCaptureUI.md

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,12 @@ Provides settings for capturing photos with CameraCaptureUI.
190190
The settings include aspect ratio, image size, format, resolution,
191191
and whether or not cropping is allowed by the user interface (UI).
192192

193+
**Important Note**:
194+
- By default, `AllowCropping` is true.
195+
- Don't specify both size and aspect ratio in the `PhotoSettings`, doing so will cause an invalid argument exception.
196+
- `PhotoSettings` can't have a ratio or size specified with cropping disabled. Attempting to do so will result in an invalid argument exception.
197+
198+
193199
## CameraCaptureUIPhotoCaptureSettings Properties
194200

195201
| Name | Description | Value |
@@ -207,6 +213,12 @@ and whether or not cropping is allowed by the user interface (UI).
207213
Provides settings for capturing videos.
208214
The settings include format, maximum resolution, maximum duration, and whether or not to allow trimming.
209215

216+
**Important Note**:
217+
- By default, `AllowTrimming` is true.
218+
- `MaxDurationInSeconds` must be a valid value (i.e., the duration should be in the range of 0 to `UINT32_MAX`). Specifying an invalid value will result in an invalid argument exception.
219+
- `MaxDurationInSeconds` cannot be set if `AllowTrimming` is false. Attempting to do so will result in an invalid argument exception.
220+
221+
210222
## CameraCaptureUIVideoCaptureSettings Properties
211223
| Name | Description | Value |
212224
|-|-|-|
@@ -355,8 +367,6 @@ namespace Microsoft.Windows.Media.Capture
355367
}
356368

357369
[contract(CameraCaptureUIContract, 1)]
358-
[threading(sta),
359-
marshaling_behavior(none)]
360370
runtimeclass CameraCaptureUI
361371
{
362372
CameraCaptureUI(Microsoft.UI.WindowId window);

specs/WinRT/WinRTAPIContracts.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ The list of all contracts defined across Windows App SDK
106106
| AppLifecycle | windowsappsdk | AppLifecycleContract | Microsoft.Windows.AppLifecycle | |
107107
| AppNotifications | windowsappsdk | AppNotificationsContract | Microsoft.Windows.AppNotifications | |
108108
| BackgroundTask | windowsappsdk | BackgroundTaskContract | Microsoft.Windows.ApplicationModel.Background | |
109+
| CameraCaptureUI | windowsappsdk | CameraCaptureUIContract | Microsoft.Windows.Media.Capture | |
109110
| Deployment | windowsappsdk | DeploymentManagerContract | Microsoft.Windows.ApplicationModel.WindowsAppRuntime | |
110111
| DynamicDependency | windowsappsdk | DynamicDependencyContract | Microsoft.Windows.ApplicationModel.DynamicDependency | |
111112
| EnvironmentManager | windowsappsdk | EnvironmentManagerContract | Microsoft.Windows.System | |

0 commit comments

Comments
 (0)