--- title: "Focus: autofocus and manual focus" description: "Autofocus a Sony, Canon or Nikon camera from your computer, focus on a point in the frame, nudge manual focus, and set focus mode, area and subject detection." url: https://darkgrade.com/docs/functionality/focus last_updated: 2026-12-04 docs_index: https://darkgrade.com/docs/llms.txt --- # Focus: autofocus and manual focus > Autofocus a Sony, Canon or Nikon camera from your computer, focus on a point in the frame, nudge manual focus, and set focus mode, area and subject detection. > ## Documentation Index > Fetch the complete documentation index at: https://darkgrade.com/docs/llms.txt > Use this file to discover all available pages before exploring further. Focus a Sony, Canon or Nikon camera from your computer: autofocus once or on a point, move manual focus a step at a time, and choose how the camera finds and follows a subject. Your camera takes only the values it offers right now and refuses the rest: [what the camera can do](https://darkgrade.com/docs/functionality/connection.md#what-the-camera-can-do) lists them. Every change answers with the value the camera reports afterwards, so you know it took. | What | Does | | - | - | | [Autofocus](#autofocus) | Focus once and say whether it locked. | | [Focus on a point](#focus-on-a-point) | Focus on a spot in the frame. | | [Reset the focus point](#reset-the-focus-point) | Put the focus point back in the centre. | | [Nudge manual focus](#nudge-manual-focus) | Step focus nearer or farther. | | [Focus mode](#focus-mode) | Single, continuous or manual focus. | | [Focus area](#focus-area) | Where in the frame autofocus looks. | | [Subject detection](#subject-detection) | Whether autofocus finds a subject itself. | | [Detection subject](#detection-subject) | What subject detection looks for. | | [Eye selection](#eye-selection) | Which eye to focus on. | | [Continuous AF](#continuous-af) | Canon: keep roughly in focus before the press. | Each example has a tab per product. Pick yours once and every example follows. In Studio, the microphone that starts [voice](https://darkgrade.com/docs/studio/voice.md) is under the picture. MCP tabs show the tool Claude calls on Studio; on [your own server](https://darkgrade.com/docs/ai/server.md#what-differs-from-studio) the tools also take `camera`. Each CLI command opens the camera, does one thing and closes it. ## Autofocus Focuses once, using the camera's current [focus area](#focus-area), and tells you whether focus locked. ```text Studio Click Autofocus under the picture, or press F. Or click the microphone and say “Focus”. ``` ```text MCP Ask Claude: “Focus.” → camera_autofocus {} ``` ```bash CLI npx darkgrade camera autofocus ``` ```typescript Slate const result = await camera.autofocus() // 'acquired', 'not-acquired' or 'unknown' ``` ### What you get back One of `acquired` `not-acquired` `unknown`. `acquired`: the camera reported focus. `not-acquired`: it could not focus (low contrast, too dark, too close). `unknown`: the camera focused for a while but reports nothing either way, as Canon does, and Sony in movie mode. [MCP](https://darkgrade.com/docs/ai/results.md#what-a-tool-returns) and the [CLI](https://darkgrade.com/docs/cli/output.md#json-results) return the same word as JSON. Also called *focus*, *focus once*, *half press*, *half-press shutter*, *AF on*, *S1*. Slate reference: [`autofocus`](https://darkgrade.com/docs/slate/getting_started/camera.md#autofocus) ## Focus on a point Moves the focus point to a spot in the picture and focuses there. The spot is two numbers from 0 to 1: `0, 0` is the top-left corner and `1, 1` the bottom-right. ```text Studio Click the picture where you want focus. Or click the microphone and say “Focus on the background”. ``` ```text MCP Ask Claude: “Focus on the middle of the frame.” → camera_set_focus_point {"x": 0.5, "y": 0.5} ``` ```bash CLI # Focuses there. The focus point and area go back # when the command ends. npx darkgrade camera set-focus-point 0.5 0.5 ``` ```typescript Slate await camera.setFocusPoint(0.5, 0.5) // move the point without focusing await camera.setFocusPoint(0.3, 0.6, { autofocus: false }) ``` ### Inputs - **`x`** · a number · required From 0 (left) to 1 (right). - **`y`** · a number · required From 0 (top) to 1 (bottom). - **`autofocus`** · true or false · CLI `--[no-]autofocus` Default true: focus once at the point. False only moves the point. * Where the focus area has no position (Sony Wide, Zone and Center; Canon Wide; Nikon Auto Area), the camera is switched to a spot or a single point, and on Sony [subject detection](#subject-detection) is paused so it does not pull focus back to a face. * [Reset the focus point](#reset-the-focus-point), or disconnecting, puts both back. Also called *focus position*, *tap to focus*, *touch focus*, *touch AF*, *move focus point*. Slate reference: [`setFocusPoint`](https://darkgrade.com/docs/slate/getting_started/camera.md#setfocuspoint) ## Reset the focus point Puts the focus point back in the centre, and the focus area and subject detection back as they were before [Focus on a point](#focus-on-a-point) changed them. ```text Studio Click the microphone and say “Reset the focus point”. ``` ```text MCP Ask Claude: “Put the focus point back in the centre.” → camera_reset_focus_point {} ``` ```bash CLI # Rarely needed here: set-focus-point puts the point back # when its command ends. npx darkgrade camera reset-focus-point ``` ```typescript Slate await camera.resetFocusPoint() ``` Also called *centre focus point*, *center focus point*, *clear focus point*. Slate reference: [`resetFocusPoint`](https://darkgrade.com/docs/slate/getting_started/camera.md#resetfocuspoint) ## Nudge manual focus Moves manual focus one small, medium or large step nearer or farther. ```text Studio Click the microphone and say “Focus a little closer”. ``` ```text MCP Ask Claude: “Focus a little closer.” → camera_nudge_focus {"direction": "near", "size": "small"} ``` ```bash CLI npx darkgrade camera nudge-focus near small ``` ```typescript Slate const nudge = await camera.nudgeFocus('near', 'small') // { atLimit: false } ``` ### Inputs - **`direction`** · `near` `far` · required `near` moves focus towards the camera, `far` away from it. - **`size`** · `small` `medium` `large` · required How far to move. ### What you get back Slate returns a [`FocusNudge`](https://darkgrade.com/docs/slate/reference/types-results.md#focusnudge). [MCP](https://darkgrade.com/docs/ai/results.md#what-a-tool-returns) and the [CLI](https://darkgrade.com/docs/cli/output.md#json-results) return the same fields as JSON. - **`atLimit`** · `boolean` The lens stopped at the end of its focus travel that way: it moved less than the step, or not at all when it was already there. Another nudge the same way will not move it. * `atLimit` is true when the lens reached the end of its travel. That is not an error. * Sony: only with focus mode MF or DMF. * Nikon: only in an autofocus mode such as AF-S, not MF. * Canon: never reports `atLimit`. Also called *manual focus*, *focus near*, *focus far*, *focus by step*. Slate reference: [`nudgeFocus`](https://darkgrade.com/docs/slate/getting_started/camera.md#nudgefocus) ## Focus mode How the camera focuses: once and lock (AF-S), keep following the subject (AF-C), or by hand (MF). ```text Studio In the sidebar, choose Focus › Mode. Or click the microphone and say “Continuous autofocus”, or ask “What's the focus mode?” ``` ```text MCP Ask Claude: “Continuous autofocus.” → camera_set_focus_mode {"value": "AF-C"} Ask Claude: “What's the focus mode?” → camera_get_focus_mode {} ``` ```bash CLI npx darkgrade camera set-focus-mode AF-C npx darkgrade camera get-focus-mode ``` ```typescript Slate await camera.setFocusMode('AF-C') const focusMode = await camera.getFocusMode() // 'AF-C' ``` **Values** `AF-S` `AF-C` `MF` and more. ### All values (11) `AF-S` `AF-C` `MF` `AF-F` `DMF` `AF-A` `AF-D` `Preset focus` `MF reverse` `AF` `AF macro` Also called *One-Shot*, *AI Servo*, *AF-S*, *AF-C*, *AF-F*, *DMF*, *Movie Servo AF*, *movie servo autofocus*. Slate reference: [Focus mode](https://darkgrade.com/docs/slate/reference/settings-focus.md#focus-mode) ## Focus area Where in the frame autofocus looks: the whole frame, a zone, or a spot. ```text Studio In the sidebar, choose Focus › Area. Or click the microphone and say “Zone focus area”, or ask “Which focus area is it using?” ``` ```text MCP Ask Claude: “Zone focus area.” → camera_set_focus_area {"value": "Zone"} Ask Claude: “Which focus area is it using?” → camera_get_focus_area {} ``` ```bash CLI npx darkgrade camera set-focus-area Zone npx darkgrade camera get-focus-area ``` ```typescript Slate await camera.setFocusArea('Zone') const focusArea = await camera.getFocusArea() // 'Zone' ``` **Values** `Wide` `Zone` `Center` `Spot M` `Tracking` and more. The [settings reference](https://darkgrade.com/docs/slate/reference/settings-focus.md#focus-area) lists all 57. Also called *AF area*, *AF method*, *AF-area mode*. Slate reference: [Focus area](https://darkgrade.com/docs/slate/reference/settings-focus.md#focus-area) ## Subject detection Whether autofocus finds and follows a subject, such as a face or an eye, on its own. ```text Studio In the sidebar, switch Focus › Eye tracking on or off. Or click the microphone and say “Turn on subject detection”, or ask “Is subject detection on?” ``` ```text MCP Ask Claude: “Turn on subject detection.” → camera_set_subject_detection {"value": "On"} Ask Claude: “Is subject detection on?” → camera_get_subject_detection {} ``` ```bash CLI npx darkgrade camera set-subject-detection On npx darkgrade camera get-subject-detection ``` ```typescript Slate await camera.setSubjectDetection('On') const subjectDetection = await camera.getSubjectDetection() // 'On' ``` **Values** `On` `Off`. Also called *subject recognition*, *eye tracking*, *eye AF*, *face detection*, *face and eye detection*. Slate reference: [Subject detection](https://darkgrade.com/docs/slate/reference/settings-focus.md#subject-detection) ## Detection subject What subject detection looks for: people, animals, vehicles. ```text Studio In the sidebar, choose Focus › Subject. It shows while Eye tracking is on. Or click the microphone and say “Detect animals”, or ask “What is it detecting?” ``` ```text MCP Ask Claude: “Detect animals.” → camera_set_detection_subject {"value": "Animals"} Ask Claude: “What is it detecting?” → camera_get_detection_subject {} ``` ```bash CLI npx darkgrade camera set-detection-subject Animals npx darkgrade camera get-detection-subject ``` ```typescript Slate await camera.setDetectionSubject('Animals') const detectionSubject = await camera.getDetectionSubject() // 'Animals' ``` **Values** `People` `Animals` `Birds` `Vehicles` and more. ### All values (9) `People` `Animals` `Birds` `Vehicles` `Auto` `Planes` `Animals and birds` `Insects` `Cars and trains` Also called *recognition target*, *subject to detect*, *tracking object*. Slate reference: [Detection subject](https://darkgrade.com/docs/slate/reference/settings-focus.md#detection-subject) ## Eye selection Which eye the camera focuses on when it detects a face. ```text Studio In the sidebar, choose Focus › Eye. It shows while Eye tracking is on. Or click the microphone and say “Focus on the left eye”, or ask “Which eye is it using?” ``` ```text MCP Ask Claude: “Focus on the left eye.” → camera_set_eye_selection {"value": "Left"} Ask Claude: “Which eye is it using?” → camera_get_eye_selection {} ``` ```bash CLI npx darkgrade camera set-eye-selection Left npx darkgrade camera get-eye-selection ``` ```typescript Slate await camera.setEyeSelection('Left') const eyeSelection = await camera.getEyeSelection() // 'Left' ``` **Values** `Auto` `Left` `Right` and more. ### All values (4) `Auto` `Left` `Right` `Off` Also called *eye select*, *eye detection*. Slate reference: [Eye selection](https://darkgrade.com/docs/slate/reference/settings-focus.md#eye-selection) ## Continuous AF Canon's Continuous AF: the camera keeps the lens roughly in focus before you press, then locks focus as usual. Only cameras that have it list it. ```text Studio Click the microphone and say “Turn on continuous AF”, or ask “Is continuous AF on?” ``` ```text MCP Ask Claude: “Turn on continuous AF.” → camera_set_continuous_autofocus {"value": "On"} Ask Claude: “Is continuous AF on?” → camera_get_continuous_autofocus {} ``` ```bash CLI npx darkgrade camera set-continuous-autofocus On npx darkgrade camera get-continuous-autofocus ``` ```typescript Slate await camera.setContinuousAutofocus('On') const continuousAutofocus = await camera.getContinuousAutofocus() // 'On' ``` **Values** `On` `Off`. Also called *continuous autofocus*, *Pre-AF*, *pre AF*. Slate reference: [Continuous AF](https://darkgrade.com/docs/slate/reference/settings-focus.md#continuous-af)