Scale mask and image to texture dimensions when loading into Metal
textures, fixing crash when brush mask has different dimensions
than the source image.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Edge refinement: Wire toggle to actually snap brush strokes to edges
using Sobel gradient analysis in EdgeRefinement.swift
- Brush preview circle: Show visual cursor following finger during drawing
- PHAsset storage: Capture localIdentifier for Photo Library imports
- Low-confidence mask warning: Show "Does this look right?" for uncertain
detections based on mask coverage and edge sharpness analysis
- Fix Swift 6 concurrency warnings with nonisolated static methods
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update MaskOperation to store mask dimensions for reconstruction.
Implement proper operation rendering in ImagePipeline:
- Apply mask+inpaint operations with proper mask reconstruction
- Handle adjustment operations by type (brightness/contrast/saturation)
- Scale masks when rendering previews at reduced resolution
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Implement GPU-accelerated inpainting using Metal compute shaders:
- Add Shaders.metal with dilateMask, gaussianBlur, diffuseInpaint, edgeAwareBlend kernels
- Add PatchMatchInpainter class for exemplar-based inpainting
- Update InpaintEngine to use Metal with Accelerate fallback
- Add BrushCanvasView for manual brush-based mask painting
- Add LineBrushView for wire removal line drawing
- Update CanvasView to integrate brush canvas overlay
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add ExportView with JPEG, PNG, HEIC format support
- Include quality slider for JPEG compression
- Show image dimensions and estimated file size
- Implement save to Photo Library with proper permissions
- Add share sheet for AirDrop, Messages, etc.
- Wire export button in PhotoEditorView to show ExportView
- Add HEIC encoding extension for UIImage
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add EditorViewModel coordinating masking, contour detection, and inpainting
- Connect PhotoEditorView to viewModel with mask confirmation bar
- Add processing overlay and error toast UI
- Update CanvasView with tap-to-mask functionality
- Add coordinate conversion from view space to image space
- Update ToolbarView to bind to viewModel state
- Wire up undo/redo actions through viewModel
Person, object, and wire removal now flow:
tap -> detect -> preview mask -> confirm -> inpaint
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add project constitution with vision, principles, and autonomy settings
- Add 15 feature specifications covering full app scope
- Configure agent entry points (AGENTS.md, CLAUDE.md)
- Add build prompt and speckit command for spec creation
- Include comprehensive .gitignore for iOS development
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>