nice-room-70150
09/22/2025, 10:53 PMtall-airline-16756
09/22/2025, 10:53 PMtall-airline-16756
09/22/2025, 10:54 PMImageCapture use case. You can use the takePicture method along with ImageCapture.OnImageSavedCallback to handle the captured image.
• iOS: The RPScreenRecorder offers a sample buffer callback that lets you receive video frames during screen sharing.
• Unity: You can use ScreenCapture.CaptureScreenshotIntoRenderTexture to capture the screen content into a render texture for further use.
• Node-based SDKs: The CaptureVideoFrameRequest in the FFI interface indicates video frame capture capabilities.
If you’re working on a particular platform, please feel free to share, and I’d be happy to guide you through the specific steps to implement screenshot functionality. I’m here to make this as smooth as possible for you!
Sources: sample-app-compose/src/main/java/io/livekit/android/composesample/CallActiv... | Sources/LiveKit/Track/Capturers/MacOSScreenCapturer.swift | Runtime/Scripts/CameraVideoSource.cs | packages/livekit-rtc/src/proto/ffi_pb.ts | livekit-plugins/livekit-plugins-google/livekit/plugins/google/beta/realtime...nice-room-70150
09/22/2025, 11:00 PMtall-airline-16756
09/22/2025, 11:01 PMnice-room-70150
09/22/2025, 11:03 PMtall-airline-16756
09/22/2025, 11:04 PMon_user_turn_completed callback.
3. Combine and Send: Finally, in the before_llm_cb callback, you can add both the screenshot and the transcription into the chat context before the LLM processes the input. Here’s an example:
async def before_llm_cb(assistant: VoicePipelineAgent, chat_ctx: llm.ChatContext):
transcript = "Hello, I need help with this." # From STT
latest_image = await get_latest_image(room) # Capture latest frame
if latest_image:
chat_ctx.add_message(
role="user",
content=[
transcript,
ImageContent(image=latest_image) # Can be URL, base64, or VideoFrame
]
)
Just a quick tip: make sure your LLM supports multimodal input so it can handle both text and images smoothly. If you have any questions or want to dive deeper into the implementation, I’m here to help!
Sources: Vision Agent Quickstart | LiveKit Docs | livekit-agents/livekit/agents/voice/agent_activity.py | Vision | LiveKit Docsnice-room-70150
09/23/2025, 12:34 AMtall-airline-16756
09/23/2025, 12:35 AM