Skip to content

Fix camera, display, and fingerprint documentation (R062, pass 2) - #1750

Merged
jonathanpeppers merged 2 commits into
mainfrom
jonathanpeppers-fix-android-hardware-documentation-error
Nov 23, 2026
Merged

jonathanpeppers merged 2 commits into
mainfrom
jonathanpeppers-fix-android-hardware-documentation-error

Conversation

@jonathanpeppers

@jonathanpeppers jonathanpeppers commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Changes

Second-pass review of 68 files in Android.Hardware.Camera2.Params, Android.Hardware.Display, and Android.Hardware.Fingerprints.

Uncertain finding

Face.Builder.SetLeftEyePosition, SetRightEyePosition, and SetMouthPosition have non-null parameter descriptions consistent with their annotations, but their remarks describe cases that require or permit null. The implementation accepts null in its setters and checks landmark combinations in build(). The published annotation and implementation conflict, so this text is unchanged.

Checks

  • Reviewed 269 substantive changed documentation blocks; excluded 104 binding boilerplate blocks, two deferred IntDef-only blocks, and one formatting-only block.
  • Parsed all 68 scoped XML files: 683 Docs blocks and zero placeholders. Checked the 13 changed blocks and preserved non-documentation bytes, metadata, BOMs, and line endings.
  • Verified added cref targets, linked JNI signatures, and git diff --check.
  • Final gemini-4-argon review found no actionable issues. Source review used the pinned Android 37.2 r01 archive (SHA-256 9d637c3af6654a2f1b696b3d19c54bb77e38df2b0106116934703f314b3d4e84), with r02 binding differences treated cautiously.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings November 23, 2026 06:36
@jonathanpeppers
jonathanpeppers enabled auto-merge (squash) November 23, 2026 06:36

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues are recorded for this documentation-only change.

No open issues 🎉

What changed in this PR

This documentation-only PR refines the .NET Android API reference for camera parameters, displays, and fingerprints. It clarifies existing behavior without changing bindings or runtime code.

Changes:

  • Correct camera collection wording, HDR typos, and the snapshot active-array description.
  • Move session-wide setter guidance into property remarks and clarify null defaults and version-dependent behavior.
  • Correct display descriptions and remove misleading fingerprint removal notices while retaining deprecation guidance.
File Description
docs/​xml/​Android.Hardware.Fingerprints/​FingerprintManager.xml Remove removal notices from two property values.
docs/​xml/​Android.Hardware.Display/​VirtualDisplayConfig.xml Document the unset dim-brightness value of -1.
docs/​xml/​Android.Hardware.Display/​DisplayTopology.xml Describe absolute bounds as retrieved, not assigned.
docs/​xml/​Android.Hardware.Display/​DisplayManager.xml Correct historical virtual-display creation wording.
docs/​xml/​Android.Hardware.Camera2.Params/​UsecaseMode.xml Clarify the snapshot sensor active-array reference.
docs/​xml/​Android.Hardware.Camera2.Params/​Face+Builder.xml Qualify copy-constructor behavior by Android version.
docs/​xml/​Android.Hardware.Camera2.Params/​ExtensionSessionConfiguration.xml Relocate setter guidance and document the null default.
docs/​xml/​Android.Hardware.Camera2.Params/​DynamicRangeProfiles.xml Fix two HDR documentation typos.
docs/​xml/​Android.Hardware.Camera2.Params/​ColorSpaceProfiles.xml Remove inaccurate list terminology from collection descriptions.

Review effort: Balanced

@jonathanpeppers

Copy link
Copy Markdown
Member Author

@dalexsoto review

@dalexsoto dalexsoto left a comment

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.

I checked all 9 files against AOSP for each member's API levels. Eight are accurate:

  • The XML at a5fbef2 is well-formed and every change is inside <Docs>.
  • The only added cref (M:Android.Hardware.Camera2.Params.Face.Builder.Build) resolves.
  • main has not touched these files since the merge base.

One blocker:

  • docs/xml/Android.Hardware.Camera2.Params/Face+Builder.xml:106 (Face.Builder(Face), ApiSince 34)
    • Problem: "In some Android versions, the copy constructor does not mark the bounds and score as set" suggests the behavior depends on the version. It doesn't. A reader may skip SetBounds/SetScore and hit IllegalStateException in Build.
    • Evidence: In every public source that has this API, the copy constructor copies the fields but never sets mBuilderFieldsSet. Only the setters set those flags, and build() throws IllegalStateException when they are missing. The sources checked were android-14.0.0_r1, android-15.0.0_r1, android-16.0.0_r1, android16-qpr2-release, 94b4c163 and android-17.0.0_r1.
    • Suggested fix: drop the qualifier, so the remark reads: "The copy constructor does not mark the bounds and score as set, so call SetBounds and SetScore before Build." Keep the existing <see cref> to Build.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues block this documentation-only clarification of the .NET Android API reference.

No open issues 🎉

Review effort: Balanced

@jonathanpeppers

Copy link
Copy Markdown
Member Author

@dalexsoto review

@dalexsoto dalexsoto left a comment

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.

Reviewed all nine changed files and 13 changed member blocks at 1de50d2, including the delta from my earlier changes-requested review.

The Face.Builder copy-constructor blocker is fixed: the remark now states unconditionally that the constructor does not mark bounds and score as set. This matches the constructor and build checks across API 34–37 (Face.java constructor, build checks).

The remaining camera, display and fingerprint corrections match their AOSP implementations and API-level context. In particular, the snapshot wording agrees with the CTS active-array check, DimBrightness preserves the unset -1 sentinel, and the FingerprintManager edits retain the deprecation guidance.

All nine files are well-formed XML; nothing outside <Docs> changed, and no cref was added or removed. Main's newer commits do not overlap these files. The local-correctness, integration and final independent-blocker passes found no blockers.

@jonathanpeppers
jonathanpeppers merged commit ce2f34b into main Nov 23, 2026
4 checks passed
@jonathanpeppers
jonathanpeppers deleted the jonathanpeppers-fix-android-hardware-documentation-error branch November 23, 2026 09:06
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.

3 participants