Per Apple's macOS AVCaptureSession.h docs (line 1106), setting `videoRotationAngle` on `AVCapturePhotoOutput`'s connection "does not necessarily result in physical rotation of video buffers … In the AVCapturePhotoOutput, orientation is handled using Exif tags." So our connection-rotation tweaks only affect the EXIF Orientation tag the JPEG carries — pixel data is sensor-native. Yet the user keeps seeing a rotated JPEG even after `stripJpegApp1` removes APP1 (EXIF). So either the pixel buffer IS rotated despite the docs, or EXIF is in a non-APP1 marker, or Flutter's decoder auto-rotates somehow. Log the actual captured JPEG's dimensions + EXIF Orientation to banlu.jsonl via the existing per-handle diagnostic stream: `CGImageSourceCopyPropertiesAtIndex` reads `kCGImagePropertyPixelWidth/Height/Orientation` from the JPEG bytes that `AVCapturePhoto.fileDataRepresentation()` produces. Format: `photo: WxH landscape|portrait exifOrientation=N`. Once we see what AVCapturePhotoOutput is actually producing on the user's Mac we'll know which side of the pipeline to fix.
20 KiB
20 KiB