Repository navigation
iOS 27 camera, display side: probe backboardd's read of the preview, note CoreAnimation's draw (diagnostics, draft) - #416
Draft
claudiusthebot wants to merge 2 commits into
Draft
claudiusthebot wants to merge 2 commits into
claudiusthebot wants to merge 2 commits into
Conversation
… preview, and note CoreAnimation's draw of it Diagnostics in the Metal frontend, all off unless set in /var/local/mtl2-env: - SWEET_MTL2_YCCPROBE=1 (YCbCrProbe.h/.metal): at bindings of a converted two-plane YCbCr texture (formats 500-510), read an 8x8 grid on the process's own GPU (compute read, linear and nearest samples; fragment-stage half samples from slot 3, linear and nearest) beside the processor's read of the surface. - SWEET_MTL2_DRAWNOTE=1 (DrawNote.h): once per pipeline, the full state of a draw that samples such a texture (fragment function, attachments, blending, samplers, fragment bytes, first vertex floats). - SWEET_MTL2_YCCFLAT=1: a test switch that binds a BGRA8 copy of such a texture instead. Run on phone 1 (24 Nov, D1-D7): the texture reads the picture in every mode; with the BGRA8 copy the viewfinder is still black. CoreAnimation draws the camera into a memoryless color attachment (TimgA3S1Xhfu_Ixrg) and composites it later in the pass; that is the next place to measure. docs/ios27/CAMERA.md, 'The display side'. The frontend's size allowance goes from 2767 to 2777 lines for the three hooks.
… (no pass split, no notice)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Diagnostics only, all off by default (set in
/var/local/mtl2-env). Built into StarbiteMetal and run on phone 1 on 24 Nov (boots D1-D7, kernel from main 72c0b59 + fork 4285c9c8,cam_trace=1 cam_metal=1).What they measured
SWEET_MTL2_YCCPROBE=1: backboardd's fmt 500 (YCbCr8_420_2P) texture over the image queue sink's surfaces reads the picture on backboardd's own GPU in every mode tried. Compute read, linear and nearest samples, and half-precision fragment samples from slot 3 all give about RGB 59 60 59 (40/64 lit), matching the CPU's luma 59.SWEET_MTL2_YCCFLAT=1(test switch): binding a BGRA8 copy instead of the YCbCr texture leaves the viewfinder black. The YCbCr texture is not the cause.SWEET_MTL2_DRAWNOTE=1plus the pass log: steady frames draw the camera withTimgA3S1Xhfu_Ixrginto the pass's memoryless RGBA16Float colour 1 (colour 0 masked off).TimgBbcmA3Xhf_Isup/TbdsA3Xhf_Isup_Isrcthen composite it. That path (memoryless attachment + framebuffer fetch on PanVK) is the next place to measure.Not a fix. The viewfinder is still black. Kept as a draft: the parent decides whether to merge the tools.
tools/arch-size.allow: the frontend's allowance goes from 2767 to 2777 lines for the three hooks; the code itself is in new headers.Checks run locally: provenance-check, arch-check --report, docs-check, drivers-check, metallib-test (all pass).
Details:
docs/ios27/CAMERA.md, "The display side".