Skip to content

support multi image capture#852

Open
VegardHV wants to merge 11 commits intomainfrom
pbi/vhv-720493-multi-image-capture-support
Open

support multi image capture#852
VegardHV wants to merge 11 commits intomainfrom
pbi/vhv-720493-multi-image-capture-support

Conversation

@VegardHV
Copy link
Copy Markdown
Contributor

@VegardHV VegardHV commented May 4, 2026

Description of Change

  • Adds the ability to capture multiple images in one camera session.
  • Added two separate flows for multi-capture, one with confirmation of each image, and one without.
  • Adds a Done button for when the user wants to complete multi-image session.
  • Splits the camera entry point into two methods: single capture and multi capture.
  • Replaces the single ImageCaptureSettings (with its PostCaptureAction enum) with two option types: shared CameraOptions and a MultiImageCaptureOptions.
  • Adds a new multi-image sample to the sample app and renames the existing one to "Single Image Capture". - Updates ImageCapture wiki docs for new API.

Further refactoring should be considered when more time is available.

Copilot AI review requested due to automatic review settings May 4, 2026 08:46
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds multi-image capture support to the ImageCapture camera use case, introducing a dedicated multi-capture session flow (with optional per-image confirmation) and updating public options/docs/samples accordingly.

Changes:

  • Split image capture startup into StartSingleImageCapture and StartMultiImageCapture, replacing ImageCaptureSettings/PostCaptureAction with CameraOptions + MultiImageCaptureOptions.
  • Updated iOS/Android implementations and shared state handling to support multi-capture behavior.
  • Updated wiki docs, added/renamed samples, and added a changelog entry.

Reviewed changes

Copilot reviewed 26 out of 26 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
wiki/Media/ImageCapture.md Updates public documentation to describe single vs multi capture and new options types.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/ImageCapture.cs Introduces single/multi start methods and session-driven behavior branching.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/CaptureSession.cs Adds session records to distinguish single vs multi capture.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Settings/CameraOptions.cs Adds new public options types (CameraOptions, MultiImageCaptureOptions).
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/ImageCapture.StreamingState.cs Routes settings restart through CameraOptions.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/ImageCapture.ConfirmState.cs Adjusts “Use photo” behavior to continue in multi mode vs stop in single mode.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Views/TopToolbar/ImageCaptureTopToolbarView.cs Adds a finished button for multi mode and updates cancel/settings visibility logic.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/BottomSheets/ImageCaptureSettingsBottomSheet.cs Reworks settings sheet to operate on CameraOptions.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Android/ImageCapture.cs Updates Android capture pipeline to call shared multi/single handling.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/iOS/ImageCapture.cs Updates iOS capture pipeline to call shared multi/single handling.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/dotnet/ImageCapture.cs Updates net10.0 stub signature to match new options type.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/CapturedImage.cs Minor formatting-only change.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/camera-feature-overview.md Adds an internal overview of modes/states and file map.
src/library/DIPS.Mobile.UI/API/Camera/Camera.cs Updates facade to use new single-capture start API.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Settings/ImageCaptureSettings.cs Removes deprecated settings type.
src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Settings/PostCaptureAction.cs Removes deprecated enum.
src/app/Components/REGISTER_YOUR_SAMPLES_HERE.cs Updates sample registration entry point to a new ImageCapturing samples page.
src/app/Components/ComponentsSamples/ImageCapturing/ImageCapturingSamples.xaml Adds a navigation hub for single vs multi capture samples.
src/app/Components/ComponentsSamples/ImageCapturing/ImageCapturingSamples.xaml.cs Code-behind for the new navigation hub.
src/app/Components/ComponentsSamples/ImageCapturing/SingleImageCaptureSample.xaml Renames sample to single capture.
src/app/Components/ComponentsSamples/ImageCapturing/SingleImageCaptureSample.xaml.cs Updates single capture sample to use CameraOptions + StartSingleImageCapture.
src/app/Components/ComponentsSamples/ImageCapturing/MultiImageCaptureSample.xaml Adds a UI to choose multi-capture mode and show results.
src/app/Components/ComponentsSamples/ImageCapturing/MultiImageCaptureSample.xaml.cs Adds code-behind for launching the modal multi-capture flow and presenting results.
src/app/Components/ComponentsSamples/ImageCapturing/MultiImageCaptureModalPage.xaml Adds a modal page hosting CameraPreview for multi capture.
src/app/Components/ComponentsSamples/ImageCapturing/MultiImageCaptureModalPage.xaml.cs Implements the modal multi capture flow and completion task.
CHANGELOG.md Adds release note entry for multi-image capture support.

Comment thread src/library/DIPS.Mobile.UI/API/Camera/ImageCapturing/Android/ImageCapture.cs Outdated
Comment thread CHANGELOG.md Outdated
VegardHV and others added 4 commits May 4, 2026 11:10
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Comment thread CHANGELOG.md Outdated
internal CameraInfo CameraInfo { get; } = new();
}

public record MultiImageCaptureOptions
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, ingen av disse properties er bindable slik det er nå. Men det er kanskje ikke et problem da dette er et code-behind API. Ser også at den tidligere ImageCaptureSettings ikke var bindable og. De kan i grunn være bindable, men da må du arve av BindableObject i så fall,

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ja, det spørs om vi vil eksponere oss selv til økt kompleksitet via endring av options underveis. Tenker personlig at det egentlig er best at de er immutable i utgangspunktet, så er bruken av option parametrene mere forutsigbar.

/// <summary>
/// Determines what should happen after people have confirmed their capture.
/// </summary>
public enum PostCaptureAction
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hvordan får jeg ekvivalent mulig oppsett med singleimagecapture nå?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PostCaptureAction.Close skjer alltid i SingleImageCapture nå, og er det som er brukt i Arena Mobil.

Om man vil ha ekvivalent oppsett som PostCaptureAction.Continue, bruker man MultiImageCapture med RequiresConfirmationOnEachImage = true 😄

Copy link
Copy Markdown
Member

@haavamoa haavamoa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vi holder igjen denne PR til etter Arena Mobil 4.6 er levert.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants