> ## Documentation Index
> Fetch the complete documentation index at: https://ogh.riturajbasak.tech/llms.txt
> Use this file to discover all available pages before exploring further.

# Using the Preview Screen to Control Your Live Stream

> Learn how to use Ogh's Preview screen to select sources, start a session, monitor duration and bitrate, switch sources while live, and stop your broadcast.

The Preview screen is your broadcast command center in Ogh. From here you select your video and audio sources, start a session, monitor live stats, and end the broadcast — all without leaving the screen. On a fresh install, Ogh opens Settings instead and keeps Preview locked until you add at least one destination.

## The Preview Screen

When you open Preview, you see a full-screen surface showing your active source — either your camera feed or a representation of your screen share. Centered over the surface is the Ogh mark. While idle the Settings action is also visible there. During a session a badge appears indicating whether you are live, preparing, or in a video-hidden state.

Below the surface are two rows of controls in portrait layout (or one compact row in landscape): source and audio controls on the left, and the primary action button on the right. A status overlay in the corner shows elapsed duration and current bitrate once a session is underway.

## Source and Session Controls

| Control                 | When available                                       | What it does                                                                                                          |
| ----------------------- | ---------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| Screen                  | Always                                               | Captures the full device screen                                                                                       |
| Camera / Flip Camera    | Always                                               | Captures the back or front camera; the label changes to **Flip Camera** when both front and back cameras are detected |
| Microphone              | Before going live                                    | Captures audio from the device microphone                                                                             |
| System Audio            | Before going live                                    | Captures audio from apps playing on the device (Android 10+)                                                          |
| Go Live                 | When stopped and at least one destination is enabled | Starts the broadcast                                                                                                  |
| Hide Video / Show Video | While live                                           | Replaces the video feed with a still image, then restores it                                                          |
| Stop                    | While live                                           | Ends the broadcast and releases session resources                                                                     |

## Session State

Tapping **Go Live** moves your session through a defined sequence of states. The diagram below shows the full lifecycle:

```
IDLE → (tap Go Live) → PREPARING → STREAMING ↔ PAUSED → STOPPED
                            |              |
                            +─── ERROR ────+
```

* **IDLE** — no active session; controls are fully available.
* **PREPARING** — permissions, provider endpoints, and capture sources are being set up. The **Go Live** button immediately becomes a disabled **Preparing…** action so you cannot trigger a double-start.
* **STREAMING** — at least one destination has confirmed a connection.
* **PAUSED** — video is hidden with a still image; audio and RTMP connections stay live.
* **STOPPED** — the broadcast has ended and session resources have been released.
* **ERROR** — the current attempt failed; correct the issue and try again.

<Note>
  Settings is hidden from the moment you tap **Go Live** until the session fully stops. Configure your destinations, encoding quality, and stream metadata before starting. Source switching and audio toggles are the only changes you can make while live.
</Note>

## Switching Sources While Live

You can switch between Screen and Camera, or flip between front and back cameras, at any point during a live session. Ogh uses the same video pipeline for all source transitions — your RTMP connections are not restarted and your audio is not interrupted. If you switch to Screen and Ogh does not already have screen-capture permission for the current session, it asks for that permission before completing the switch. Rapid source changes are serialized so only one transition happens at a time.

## Live Status Overlay

While a session is active, a compact overlay shows two values:

* **Duration** — how long the current session has been running.
* **Bitrate** — the current outgoing video bitrate in real time.

These update continuously so you can spot upload issues without leaving the screen.

<Tip>
  In portrait layout, source and audio controls appear in two rows. Rotate to landscape and they condense into one row, giving more vertical space to the preview surface.
</Tip>
