NewCode with Beto MCP

Deargrain

Give everyday photos a film feel. Explore a native SwiftUI camera with live film previews, custom Metal effects, and a photo gallery in one private codebase.

Build a camera with a look of its own

Choose a warm color profile, add a little grain, and see the result before you tap the shutter. Deargrain: Vintage Film Camera brings the texture and color of film-inspired photography to a native iPhone camera.

The project connects SwiftUI, AVFoundation, Core Image, and custom Metal kernels, with native Liquid Glass controls for iOS 26 and later. Photos are processed on the device and saved to your library. The app runs without an account, a backend, or third-party dependencies.

What is inside

  • Ten original film profiles: move from Golden Hour and Summer 200 to Cool Chrome, Mono 400, Noir, and more, with a live preview as you compose.
  • A look you can adjust: control grain, light effects, and dust. Try different light and dust variations with the dice controls.
  • Everyday camera controls: switch between front and back cameras, pinch to zoom, tap to focus, and choose a flash mode.
  • Capture and keep: render still photos with the selected profile and adjustments, then save HEIF images to Photos with film and capture metadata.
  • A complete gallery flow: browse a three-column grid, select multiple photos to share or delete, and open a photo in a swipeable, zoomable viewer with an information sheet.

What you can learn

Follow a camera frame from an actor-managed capture session into a GPU rendering pipeline and onto the screen. Study how the preview and still-photo export share the same film profiles, color processing, and effects.

The interface offers a practical example of native SwiftUI camera controls: a compact adjustments panel, a stack of recent prints, and a gallery that opens photos with a zoom transition. Behind that interface, the code manages local image copies, Photos asset links, permissions, and capture metadata.

The repository includes Swift Testing coverage for framing, focus mapping, metadata, and the rendering kernels. A macOS profile-preview tool renders the app's looks onto supplied photos and produces a contact sheet, so you can compare changes while developing your own profiles.

The current app is an iPhone photography foundation with portrait, 9:16 framing and SDR HEIF output. The README documents the remaining device and performance checks, giving you a clear starting point for continued development.

Run it

  1. Clone the private repository and open FilmCameraLab.xcodeproj in Xcode. The project was created with Xcode 27; its minimum deployment target is iOS 26.
  2. Select the FilmCameraLab scheme. The project and scheme keep their original names; the app appears as Deargrain.
  3. Add your development team to the untracked Config/Local.xcconfig, then build on a physical iPhone to use the camera.

The simulator supports builds and rendering tests, but live capture requires an iPhone. If Xcode reports a missing Metal Toolchain, install it with . No package installation or API keys are needed.

Included with Pro

Pro members get the complete Deargrain source, film profiles, Metal kernels, tests, and project documentation through the private Code with Beto GitHub organization, alongside the other premium projects and courses.

Get Started Today

Get access now

and explore how Deargrain turns camera frames into photographs.

Already a Pro member? Use Visit repo above to open Deargrain on GitHub. For access questions or feedback, email beto@codewithbeto.dev.