Skip to content

docs: refresh to current state and drop .antigravity tooling config#19

Merged
fxd0h merged 3 commits into
mainfrom
docs/refresh-and-drop-antigravity
Jun 26, 2026
Merged

docs: refresh to current state and drop .antigravity tooling config#19
fxd0h merged 3 commits into
mainfrom
docs/refresh-and-drop-antigravity

Conversation

@fxd0h

@fxd0h fxd0h commented Jun 26, 2026

Copy link
Copy Markdown
Owner

Brings the repo docs in line with what actually shipped, and removes the .antigravity/ agent-orchestration config (local tooling, not part of the project; now gitignored).

Correctness fixes (claims that were no longer true)

  • HDR was listed as implemented. It is not: the AR30/XR30 path keeps only the top 8 of 10 bits (no PQ/BT.2020/tone-mapping), and 16-bit (XR48/AR48) and P010 are unhandled. Now marked in progress (HDR10 not supported: naive 10->8-bit truncation, no 16-bit/P010 formats, no color management/metadata #16) with an honest note in the README.
  • Detile story said Intel/AMD use a CPU path. The EGL/GLES2 backend is the primary detiler now; CPU deswizzle is a fallback.
  • virtio performance text described a TRANSFER_FROM_HOST + mmap-cache mechanism with unsupported FPS figures. Replaced with the V2-copy / V3-zero-copy-DMA-BUF model and the measured per-core CPU figures. Plain virtio still uses TRANSFER_FROM_HOST (direct path) / V3 (helper path); only the virgl 3D scanout needs GPU EGL readback, captured correctly and tracked for production integration in virgl-rendered virtio-gpu scanout captures as a black frame (host-side resource, no guest readback) #15.
  • SECURITY.md now matches the current helper: fd-3 spawn check plus the SO_PEERCRED peer-uid match, O_RDONLY device open, the default-KILL seccomp allowlist with open/openat deliberately excluded, exploit-mitigation flags, and the DoS geometry guard.

Kept on purpose

The AI-assisted-development story (docs/AI_DEVELOPMENT.md, AGENTS.md, the README section) is refreshed, not removed — the project documents and welcomes AI-assisted development. Versions (libdrmtap-sys 0.4.3 / libdrmtap 0.3.2), internal links, and each document's voice are preserved.

Removed

.antigravity/ (9 files: orchestrator/agents config + personas) — local agent-orchestration tooling that does not belong in the repo. Added to .gitignore.

Internal markdown links verified (0 broken). Docs-only change; no code touched.

Bring the repo docs in line with what actually shipped, and remove the
.antigravity/ agent-orchestration config (local tooling, not part of the
project; now gitignored).

The most important fixes correct claims that were no longer true:
- HDR/10-bit was listed as implemented. It is not: the AR30/XR30 path keeps
  only the top 8 of 10 bits with no PQ/BT.2020/tone-mapping, and 16-bit
  (XR48/AR48) and P010 are unhandled. Now marked in progress (#16) with an
  honest note.
- The detile story said Intel/AMD use a CPU path. The EGL/GLES2 backend is
  the primary detiler now, with CPU deswizzle as a fallback.
- The virtio performance text described a TRANSFER_FROM_HOST + mmap-cache
  mechanism with unsupported FPS figures. Replaced with the V2 copy / V3
  zero-copy DMA-BUF model and the measured per-core CPU figures. Plain
  virtio still uses TRANSFER_FROM_HOST (direct) / V3 (helper); only the
  virgl 3D scanout needs GPU EGL readback, which is captured correctly and
  tracked for production integration in #15.
- SECURITY.md now matches the current helper: fd-3 spawn check plus the
  SO_PEERCRED peer-uid match, O_RDONLY device open, the default-KILL seccomp
  allowlist with open/openat deliberately excluded, exploit-mitigation
  flags, and the DoS geometry guard.

The AI-assisted-development story (AI_DEVELOPMENT.md, AGENTS.md, the README
section) is kept and refreshed, not removed. Versions, internal links, and
each document's voice are preserved.
@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: bb7880cc-aa4a-4039-8875-8a269094ddd8

📥 Commits

Reviewing files that changed from the base of the PR and between e11982b and a063d83.

📒 Files selected for processing (2)
  • README.md
  • docs/research/08_reframe_egl_analysis.md
📜 Recent review details
🧰 Additional context used
📓 Path-based instructions (2)
docs/**/*.md

📄 CodeRabbit inference engine (AGENTS.md)

Write documentation in English.

Files:

  • docs/research/08_reframe_egl_analysis.md
docs/research/**/*.md

📄 CodeRabbit inference engine (AGENTS.md)

Include a date and sources in research documents.

Files:

  • docs/research/08_reframe_egl_analysis.md
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Before starting work, read the research docs—especially `docs/research/05_api_and_architecture.md` and `docs/research/06_github_issues_analysis.md`—and avoid reintroducing known bugs.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: When writing code, never cache `fb_id`; refresh it via `drmModeGetPlane()` on every frame.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: When writing code, detect `handles[0] == 0` as a missing `CAP_SYS_ADMIN` condition and route through the helper.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Use the Prime path, not GEM_FLINK.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Check framebuffer modifiers for tiling; `DRM_FORMAT_MOD_LINEAR` means no deswizzle is needed.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Use `gpu_egl.c` as the primary detile path for tiled/compressed framebuffers; treat CPU deswizzle as fallback only.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Do not mark HDR10 or 10-bit support as implemented or verified; treat it as in progress and reference issue `#16`.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Any new function should have a corresponding test when possible; document GPU-specific code that requires real hardware.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: Always handle errors with negative errno returns, `set_error(ctx, ...)`, and `goto cleanup` resource cleanup.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: When creating commits, use the `component: short description` imperative format and mention issues with `#NNN` when relevant.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:52:35.334Z
Learning: When creating pull requests, use one concern per PR, include test results, and reference the research docs when the change is based on a finding.
🔇 Additional comments (5)
README.md (3)

97-103: 📐 Maintainability & Code Quality

Remove the stray blank quote lines.

Same MD028 issue remains on Line 97 and Line 103; the empty > lines will keep markdown lint failing.


81-81: 🎯 Functional Correctness | ⚡ Quick win

Narrow the detiling coverage claim.

all GPUs reads as a blanket guarantee, but the testing note below still leaves AMD hardware unverified. Please scope this row to the primary EGL path or list the confirmed vendors instead.

✏️ Proposed wording
-| EGL/GLES2 GPU-universal detiling | ✅ Implemented (primary, all GPUs) |
+| EGL/GLES2 GPU detiling | ✅ Implemented (primary) |

199-216: LGTM!

Also applies to: 254-258, 311-313

docs/research/08_reframe_egl_analysis.md (2)

5-6: LGTM!


103-114: 🎯 Functional Correctness | ⚡ Quick win

Clarify the CCS fallback branch.

-ENOTSUP and “raw pixels passed through as linear” describe opposite outcomes. If compressed modifiers have no safe CPU fallback without EGL, this branch should say it is rejected rather than implying a successful linear pass-through.

✏️ Proposed wording
-    └── EGL unavailable, CCS/compressed → -ENOTSUP (raw pixels passed through as linear)
+    └── EGL unavailable, CCS/compressed → -ENOTSUP (no safe CPU fallback; EGL required)

📝 Walkthrough

Summary by CodeRabbit

  • Documentation

    • Updated README, contribution guides, and research docs to reflect the current EGL-based detiling workflow and to clarify HDR/10-bit limitations and tested environments.
    • Refreshed performance/architecture explanations and CI/testing instructions, including PR template checklist updates.
  • Security

    • Improved documented privileged-helper isolation and hardening details (peer verification, confinement/allowlisting behavior, safer geometry validation).
    • Refined multi-user installation and recommended permissions.
  • Chores

    • Removed local AI orchestration/persona configuration files and added repository ignore rules to prevent them from being committed.

Walkthrough

The PR removes local antigravity agent config content and updates contributor, security, integration, and research documentation to match the current helper, capture, HDR, and RustDesk status.

Changes

Repository docs and local agent cleanup

Layer / File(s) Summary
Remove local agent config
.antigravity/agents.json, .gitignore
Removed the antigravity agent registry content and added .antigravity/ to ignore rules.
Refresh contributor guidance
.github/PULL_REQUEST_TEMPLATE.md, AGENTS.md, CONTRIBUTING.md, docs/AI_DEVELOPMENT.md
The pull request template, AGENTS guidance, contributing instructions, and AI development notes were updated to reflect the current build, test, commit, and repository-layout documentation.
Update public docs and integration notes
README.md, docs/README.md, bindings/rust/libdrmtap-sys/README.md, contrib/integrations/*, patches/rustdesk/README.md
The main README, topic index, Rust binding README, integration tables, and RustDesk patch notes were updated to reflect current feature, performance, and integration status.
Document helper security
SECURITY.md, docs/research/01_wayland_capture_problem.md, docs/research/03_permissions.md
The security policy and permissions notes were expanded with helper authentication, confinement, geometry, and installation details.
Revise capture and HDR research
docs/research/00_landscape.md, docs/research/02_drm_kms_mechanism.md, docs/research/04_gpu_and_testing.md, docs/research/05_api_and_architecture.md, docs/research/06_github_issues_analysis.md, docs/research/07_potential_adopters.md, docs/research/08_reframe_egl_analysis.md
The research documents were updated to describe the shipped EGL-primary capture path, helper protocol, HDR limitations, GPU-specific verification, API shape, release state, and adopter notes.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

I nibbled the docs with a twitchy nose,
and found the helper path where the bright light glows.
EGL hopped first, with HDR still shy,
while .antigravity/ drifted by the sky.
Thump-thump, libdrmtap—carrots and code!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title concisely reflects the docs refresh and removal of .antigravity tooling config.
Description check ✅ Passed The description matches the PR's documentation updates and removal of .antigravity local tooling.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/refresh-and-drop-antigravity

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 markdownlint-cli2 (0.22.1)
README.md

markdownlint-cli2 wrapper config was not available before execution

docs/research/08_reframe_egl_analysis.md

markdownlint-cli2 wrapper config was not available before execution


Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 6

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
SECURITY.md (1)

191-199: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Reorder the ownership and capability steps.

setcap runs before the chown/chmod block here, but the sibling install guide does the ownership/mode changes first and only then applies the capability. If the ownership change lands after setcap, the file capability can be lost and this example will no longer leave the helper with CAP_SYS_ADMIN.

♻️ Proposed fix
- sudo setcap cap_sys_admin+ep /usr/lib/rustdesk/drmtap-helper
-
- # Recommended on multi-user hosts: restrict who can execute the setcap helper
- # to a dedicated group rather than leaving it world-executable.
- sudo chown root:rustdesk-capture /usr/lib/rustdesk/drmtap-helper
- sudo chmod 0750 /usr/lib/rustdesk/drmtap-helper
+ # Recommended on multi-user hosts: restrict who can execute the helper
+ # to a dedicated group before granting the capability.
+ sudo chown root:rustdesk-capture /usr/lib/rustdesk/drmtap-helper
+ sudo chmod 0750 /usr/lib/rustdesk/drmtap-helper
+ sudo setcap cap_sys_admin+ep /usr/lib/rustdesk/drmtap-helper
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@SECURITY.md` around lines 191 - 199, Reorder the helper setup steps in
SECURITY.md so the ownership and mode changes on drmtap-helper happen before the
capability grant. Update the example around the setcap/chown/chmod sequence to
match the sibling install guide, keeping the chown and chmod steps first and
applying setcap last to preserve CAP_SYS_ADMIN on the helper binary.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@CONTRIBUTING.md`:
- Around line 116-118: The real-GPU test example is missing the explicit
DRM_DEVICE setting, unlike the vkms example, which can lead to selecting the
wrong GPU on multi-card systems. Update the meson test example in
CONTRIBUTING.md to include DRM_DEVICE or clearly document how the device is
resolved by default, and keep it consistent with the repo guidance referenced by
AGENTS.md.

In `@docs/research/05_api_and_architecture.md`:
- Around line 67-72: Reword the privilege-boundary description in the research
doc to avoid saying DRM master or CAP_SYS_ADMIN is what directly enables reading
other clients’ framebuffers. Update the explanation around the two-process flow,
`drmtap-helper`, `socketpair`, and the framebuffer export path using
`drmModeGetFB2()` and `drmPrimeHandleToFD()`, making clear that the helper only
provides the privilege needed for the export flow.

In `@docs/research/06_github_issues_analysis.md`:
- Around line 226-246: The HDR checklist entry mixes short-form and explicit DRM
fourcc names, which makes the supported formats ambiguous. Update the item in
the research notes to use a single naming scheme consistently, and split the
16-bit formats as needed so `AB48`/`ABGR16161616` are not conflated with `XR48`
or `AR48`; keep the wording around the HDR blocker clear and unambiguous.

In `@docs/research/08_reframe_egl_analysis.md`:
- Around line 5-6: The “ALL GPU tiling formats” wording overstates what ReFrame
demonstrated; revise the claim in the analysis text to limit it to the tested
formats/GPUs/modifiers covered by the EGL path, while still noting that it
informed src/gpu_egl.c as the primary detile path and the CPU backends as
fallback.
- Around line 103-107: The branching description around drmtap_grab_mapped
currently treats all non-linear buffers as eligible for the
gpu_{intel,amd,nvidia}.c CPU fallback, which is incorrect for compressed
modifiers. Update the flow in the drmtap_grab_mapped mapping path to add an
explicit unsupported branch for compressed modifiers such as CCS/DCC: if DMA-BUF
+ EGL is available, route through gpu_egl.c; if only dumb-mmap data is available
for a compressed modifier, mark it as unsupported with -ENOTSUP instead of
falling back to gpu_{intel,amd,nvidia}.c. Use the existing symbols
drmtap_grab_mapped, gpu_egl.c, and gpu_{intel,amd,nvidia}.c to keep the decision
tree clear.

In `@README.md`:
- Around line 92-103: Remove the empty quoted lines in the README blockquotes so
the callouts stay contiguous and markdown lint does not flag MD028. Edit the
quoted sections around the testing status and virgl note text, keeping the
content directly adjacent without blank lines inside the blockquote.

---

Outside diff comments:
In `@SECURITY.md`:
- Around line 191-199: Reorder the helper setup steps in SECURITY.md so the
ownership and mode changes on drmtap-helper happen before the capability grant.
Update the example around the setcap/chown/chmod sequence to match the sibling
install guide, keeping the chown and chmod steps first and applying setcap last
to preserve CAP_SYS_ADMIN on the helper binary.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 89a92448-a016-478a-819e-d86a5b351716

📥 Commits

Reviewing files that changed from the base of the PR and between d1e3d18 and a92435e.

📒 Files selected for processing (30)
  • .antigravity/agents.json
  • .antigravity/orchestrator.json
  • .antigravity/personas/architect.md
  • .antigravity/personas/coder.md
  • .antigravity/personas/devops.md
  • .antigravity/personas/researcher.md
  • .antigravity/personas/reviewer.md
  • .antigravity/personas/security.md
  • .antigravity/personas/tester.md
  • .github/PULL_REQUEST_TEMPLATE.md
  • .gitignore
  • AGENTS.md
  • CONTRIBUTING.md
  • README.md
  • SECURITY.md
  • bindings/rust/libdrmtap-sys/README.md
  • contrib/integrations/README.md
  • contrib/integrations/rustdesk/README.md
  • docs/AI_DEVELOPMENT.md
  • docs/README.md
  • docs/research/00_landscape.md
  • docs/research/01_wayland_capture_problem.md
  • docs/research/02_drm_kms_mechanism.md
  • docs/research/03_permissions.md
  • docs/research/04_gpu_and_testing.md
  • docs/research/05_api_and_architecture.md
  • docs/research/06_github_issues_analysis.md
  • docs/research/07_potential_adopters.md
  • docs/research/08_reframe_egl_analysis.md
  • patches/rustdesk/README.md
💤 Files with no reviewable changes (9)
  • .antigravity/personas/security.md
  • .antigravity/personas/reviewer.md
  • .antigravity/personas/tester.md
  • .antigravity/agents.json
  • .antigravity/personas/researcher.md
  • .antigravity/personas/coder.md
  • .antigravity/personas/devops.md
  • .antigravity/orchestrator.json
  • .antigravity/personas/architect.md
📜 Review details
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:29:05.192Z
Learning: Never introduce or claim HDR10/10-bit support as implemented; the AR30/XR30 path is incomplete and 16-bit/P010 are unhandled.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:29:05.192Z
Learning: Before starting work, read the research docs and check the gotcha checklist to avoid reintroducing known bugs.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:29:05.192Z
Learning: When writing code, do not mix concerns between grab, enumerate, convert, and helper layers.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:29:05.192Z
Learning: Use the `goto cleanup` error-handling pattern; never crash or abort.
Learnt from: CR
Repo: fxd0h/libdrmtap

Timestamp: 2026-06-26T17:29:05.192Z
Learning: Commit messages should use `component: short description` in imperative mood and may reference issues with `#NNN`.
🪛 LanguageTool
.github/PULL_REQUEST_TEMPLATE.md

[uncategorized] ~26-~26: The official name of this software platform is spelled with a capital “H”.
Context: ...s) - [ ] Gotcha checklist reviewed ([06_github_issues_analysis.md](../docs/research/06...

(GITHUB)


[uncategorized] ~26-~26: The official name of this software platform is spelled with a capital “H”.
Context: ... reviewed (06_github_issues_analysis.md) - [ ] CI green: Bu...

(GITHUB)

CONTRIBUTING.md

[uncategorized] ~124-~124: The official name of this software platform is spelled with a capital “H”.
Context: ...sh and pull request runs GitHub Actions: - Build & Test ...

(GITHUB)

docs/research/02_drm_kms_mechanism.md

[grammar] ~184-~184: Ensure spelling is correct
Context: ...ia block-linear. EGL is the primary detile path; a CPU deswizzle survives only as ...

(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)

docs/research/05_api_and_architecture.md

[grammar] ~83-~83: Ensure spelling is correct
Context: ... to linear RGBA. EGL is the primary detile path; a CPU deswizzle exists as a fallb...

(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)


[grammar] ~85-~85: Ensure spelling is correct
Context: ...simple VMs) are mapped directly with no detile. ### Proposed API (headers) ```c // === drmt...

(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)

🪛 markdownlint-cli2 (0.22.1)
docs/AI_DEVELOPMENT.md

[warning] 48-48: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 57-57: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)

CONTRIBUTING.md

[warning] 104-104: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 105-105: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


[warning] 109-109: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 110-110: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)

docs/research/08_reframe_egl_analysis.md

[warning] 103-103: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

README.md

[warning] 97-97: Blank line inside blockquote

(MD028, no-blanks-blockquote)


[warning] 103-103: Blank line inside blockquote

(MD028, no-blanks-blockquote)

docs/research/02_drm_kms_mechanism.md

[warning] 5-5: Blank line inside blockquote

(MD028, no-blanks-blockquote)


[warning] 179-179: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 188-188: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 191-191: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 194-194: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 200-200: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 203-203: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 206-206: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 214-214: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)

🔇 Additional comments (14)
.gitignore (1)

26-27: LGTM!

.github/PULL_REQUEST_TEMPLATE.md (1)

22-27: LGTM!

AGENTS.md (1)

10-22: LGTM!

Also applies to: 136-142, 224-238, 335-341, 372-409

CONTRIBUTING.md (1)

22-27: LGTM!

docs/AI_DEVELOPMENT.md (1)

48-60: LGTM!

Also applies to: 83-83

README.md (1)

73-89: LGTM!

Also applies to: 104-109, 199-216, 254-258, 311-313

docs/README.md (1)

31-31: LGTM!

bindings/rust/libdrmtap-sys/README.md (1)

36-43: LGTM!

contrib/integrations/README.md (1)

10-12: LGTM!

contrib/integrations/rustdesk/README.md (1)

7-11: LGTM!

patches/rustdesk/README.md (1)

34-42: LGTM!

SECURITY.md (1)

33-36: LGTM!

Also applies to: 68-99, 111-117, 134-143, 158-161

docs/research/03_permissions.md (1)

86-87: LGTM!

Also applies to: 132-139

docs/research/01_wayland_capture_problem.md (1)

29-30: LGTM!

Also applies to: 54-55, 124-124

Comment thread CONTRIBUTING.md Outdated
Comment thread docs/research/05_api_and_architecture.md
Comment thread docs/research/06_github_issues_analysis.md Outdated
Comment thread docs/research/08_reframe_egl_analysis.md Outdated
Comment thread docs/research/08_reframe_egl_analysis.md Outdated
Comment thread README.md Outdated
Comment on lines +92 to +103
> ⚠️ **Testing status**: Capture pipeline verified with the V3 zero-copy path on
> `virtio_gpu` (QEMU/Parallels VMs), Intel Meteor Lake (`i915`, dual 3840x2160,
> EGL CCS detiling), and NVIDIA Jetson Orin Nano (`nvidia-drm`, aarch64, Wayland).
> The AMD (`amdgpu`) backend is implemented but still awaits real hardware testing.
> If you test on real hardware, please [report results](https://github.com/fxd0h/libdrmtap/issues).

> ℹ️ **virgl note**: Plain `virtio-gpu` is captured with a direct linear map. A
> host-rendered **virgl** (3D) scanout cannot be read by the guest CPU (it comes
> out black, and `TRANSFER_FROM_HOST` does not bring it back); it is captured via
> GPU-side EGL readback on the guest. Solved technically; production integration is
> in progress ([#15](https://github.com/fxd0h/libdrmtap/issues/15)).

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Remove the empty quoted lines.

The blank > lines at Lines 97 and 103 trigger MD028 and will fail markdown lint. Keep the callouts contiguous instead of inserting empty lines inside the blockquote.

♻️ Proposed fix
 > If you test on real hardware, please [report results](https://github.com/fxd0h/libdrmtap/issues).
->
 > ℹ️ **virgl note**: Plain `virtio-gpu` is captured with a direct linear map. A
@@
 > Solved technically; production integration is
 > in progress ([`#15`](https://github.com/fxd0h/libdrmtap/issues/15)).
->
 > 🚧 **HDR is not ready.** HDR10 / 10-bit scanouts are **not** properly supported
🧰 Tools
🪛 markdownlint-cli2 (0.22.1)

[warning] 97-97: Blank line inside blockquote

(MD028, no-blanks-blockquote)


[warning] 103-103: Blank line inside blockquote

(MD028, no-blanks-blockquote)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@README.md` around lines 92 - 103, Remove the empty quoted lines in the README
blockquotes so the callouts stay contiguous and markdown lint does not flag
MD028. Edit the quoted sections around the testing status and virgl note text,
keeping the content directly adjacent without blank lines inside the blockquote.

Source: Linters/SAST tools

…names, install order)

- CONTRIBUTING: make the real-GPU integration-test example set DRM_DEVICE
  explicitly (or note auto-detection), consistent with AGENTS.md.
- 05_api_and_architecture: reword the privilege boundary so it is precise —
  DRM gates foreign-framebuffer access on master/CAP_SYS_ADMIN, the helper
  holds it and exports the scanout, the unprivileged library maps and reads.
- 06_github_issues_analysis: use a single fourcc naming scheme for the HDR
  formats (AR30/XR30, XR48/AR48) instead of mixing short and long names.
- 08_reframe_egl_analysis: soften the 'handles ALL GPU tiling formats' claim
  to the tested vendors/modifiers, and note that CCS-compressed modifiers
  have no CPU fallback (EGL required).
- SECURITY: in the install snippet, restrict ownership/mode (0750) before the
  setcap grant so the binary is never world-executable while it already
  carries the capability.
@fxd0h

fxd0h commented Jun 26, 2026

Copy link
Copy Markdown
Owner Author

Thanks, addressed all six in the latest push (e11982b):

  • CONTRIBUTING real-GPU example now sets DRM_DEVICE explicitly and notes the auto-detect default.
  • 05_api_and_architecture: reworded the privilege boundary to be precise. DRM gates access to other clients framebuffers on master/CAP_SYS_ADMIN; the helper holds that capability and exports the scanout via GetFB2 + PrimeHandleToFD, and the unprivileged library maps the exported buffer to read pixels.
  • 06_github_issues_analysis: HDR checklist now uses a single fourcc scheme (AR30/XR30 for 10-bit, XR48/AR48 for 16-bit), dropped the mixed AB48/ABGR16161616 form.
  • 08_reframe_egl_analysis: softened 'handles ALL GPU tiling formats' to the tested vendors/modifiers, and added a note that CCS-compressed modifiers have no CPU fallback (EGL required).
  • SECURITY install snippet: chown/chmod 0750 now happen before setcap, so the helper is never world-executable while it already carries the capability. Good catch.

All internal links verified (0 broken).

- README: join the three adjacent status blockquotes with quoted-blank lines
  so they do not trip MD028.
- 08_reframe_egl_analysis: give the dispatch diagram an explicit
  CCS/compressed -> -ENOTSUP branch (not a CPU fallback) and a fenced-code
  language.
@fxd0h

fxd0h commented Jun 26, 2026

Copy link
Copy Markdown
Owner Author

Round 2:

  • README MD028: joined the three adjacent status blockquotes (testing status / virgl note / HDR note) with quoted-blank lines so they no longer trip MD028.
  • 08 dispatch diagram: split the EGL-unavailable branch into classic-tiling (CPU fallback) vs CCS/compressed (-ENOTSUP, raw passed through as linear), and added a language to the code fence. Good call, the single CPU-fallback arrow did imply compressed modifiers have a CPU path, which they do not.
  • 05 privilege boundary: I think this one is now accurate as written. It no longer says CAP_SYS_ADMIN reads the pixels; it says DRM gates access to other clients framebuffers behind master/CAP_SYS_ADMIN, the helper holds that capability and exports the scanout (GetFB2 + PrimeHandleToFD), and the unprivileged library maps the exported buffer to read. That is the real boundary (DRM does restrict foreign-framebuffer lookup to master/CAP_SYS_ADMIN), and the privilege/export/read split is explicit. Leaving it as is.

@fxd0h fxd0h merged commit c5041f4 into main Jun 26, 2026
9 checks passed
@fxd0h fxd0h deleted the docs/refresh-and-drop-antigravity branch June 26, 2026 17:59
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.

1 participant