Use this skill when the user wants a live camera image captured and sent back.
scripts/capture_webcam.py.tmp/ inside the workspace.MEDIA:./relative/path.png or MEDIA:./relative/path.jpg so the image is sent back.Direct camera capture is the default because it works across macOS, Windows, and Linux and does not require pre-configuring screen recording, accessibility, or automation permissions.
The OS may still show a normal one-time camera permission prompt for the terminal or Python process. That is expected and lighter than the old screenshot-based setup.
Note: Replace with the actual path where this skill is installed (e.g., ~/.agents/skills/photo-capture or ~/.openclaw/workspace/skills/photo-capture).
List available cameras:
python3 <skill-dir>/scripts/capture_webcam.py --list-devices
Capture from the default camera on any supported OS:
python3 <skill-dir>/scripts/capture_webcam.py --output ./tmp/webcam.jpg
Capture from a specific device:
python3 <skill-dir>/scripts/capture_webcam.py \
--device "0" \
--output ./tmp/webcam.jpg
Higher resolution capture:
python3 <skill-dir>/scripts/capture_webcam.py \
--width 1920 \
--height 1080 \
--output ./tmp/webcam-1080p.jpg
macOS: Uses ffmpeg with avfoundation. Auto-selects camera index 0 by default.Windows: Uses ffmpeg with dshow. Auto-selects the first detected video device.Linux: Uses ffmpeg with v4l2. Auto-selects /dev/video0-style devices.ffmpeg must be available in PATH.--list-devices and then pass --device explicitly.Keep the old app-window screenshot path only as a fallback for macOS environments where direct webcam capture fails.
Photo Booth fallback:
bash <skill-dir>/scripts/capture_via_app.sh \
--app "Photo Booth" \
--layout large \
--capture window \
--output ./tmp/photobooth-window-large.png
Use that fallback only if the direct ffmpeg path fails or the user explicitly wants the Photo Booth or FaceTime UI visible in the image.
When updating or debugging this skill:
--list-devices on the target OS.tmp/.共 1 个版本