> For the complete documentation index, see [llms.txt](https://docs.dbnetsoft.com/dbnetsoft/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native.md).

# ScreensPro Native

ScreensPro's native HTML rendering engine, with the best parts of the XAML rendering, on NDI, SDI and displays.

ScreensPro Native is ScreensPro's native HTML rendering engine. It takes over some of the best parts of the XAML rendering of the older ScreensPro Server - its layers, transitions, data bindings, elements and the way clients control layouts - and brings them to layouts made in HTML.

ScreensPro clients (ScreensPro Client, ScreensPort, integrations) connect to it as they do to ScreensPro Server, and load, show and control layouts. The layouts go out on **NDI**, **SDI** (Blackmagic DeckLink), a **window on a display** (HDMI / DisplayPort) and a **sound device**.

HTML is its native layout format. Existing **XAML layouts** of ScreensPro Server keep working as they are.

{% hint style="info" %}
ScreensPro Native speaks the same protocol as ScreensPro Server on the same TCP port (6610). Existing clients and integrations keep working without changes: point them at the computer running ScreensPro Native.
{% endhint %}

## What's in this chapter

* [Setting up outputs](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/outputs.md) - video format, NDI, SDI, a window on a monitor, local audio, transparency and keying
* [HTML layouts](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/html-layouts.md) - how an HTML layout is built so ScreensPro clients can control it
* [Transitions](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/transitions.md) - how layouts come in, go out and replace each other: the channel's transition, the layouts' own In and Out, toggle and what stays
* [Custom elements](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/custom-elements.md) - clocks, stopwatches, lists, video, NDI, masks, flags and slideshows with their attributes, properties and methods
* [Data sources](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/data-sources.md) - files, HTTP and ports the layouts bind to
* [Layout designer](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/designer.md) - making and editing the HTML layouts: scenes, classes and variables, data, components, animations, publishing
* [Rundown](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/rundown.md) - inserts (a layout with its data) to draw, take on air and clear during a show, without a client
* [Tutorial: RACE RESULT finishers](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/race-result-finishers.md) - a finisher list and a latest-finisher line with live data from RACE RESULT 14

## Installation

Run `Setup_ScreensProNative.exe`. The setup installs the application with everything it needs. A new installation starts with the sample project: its layouts, background layout, NDI output, data sources and [rundown](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/rundown.md), to try everything at once and to start from. Updates come the same way: the application checks once a day (switch "Check daily" in the footer), shows "Install update" when there is a new version and starts again after the update.

## The control window

ScreensPro Native opens its control window when it starts. You can also open it from any other computer on the network, in a web browser at:

```
http://<computer>:8091/
```

If port 8091 is taken by another program, ScreensPro Native takes the next free port, keeps it and says so in a notification.

Closing the window keeps the layouts on air. The tray icon brings the window back or quits the application.

The window shows:

* **Program (PGM) and preview (PVW)** side by side: what is on air, and the layouts that are loaded but not shown yet.
* **Clients**: the ScreensPro clients connected right now.
* **Layers**: what is loaded in the background, main and foreground layer, with **Take** / **Out** buttons and **Inspect**.
* **Clear on air**: takes the layouts of the main layer off air (background, foreground and preview stay, as with ScreensPro Server).
* **Outputs**: NDI, SDI, window and local audio outputs (see [Setting up outputs](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/outputs.md)).
* **Settings**: network, layout folder, transitions, start layouts, video format.
* **Log**: the channel's ScreensPro log (clients, layouts, warnings), which "Save" downloads as a text file.
* **Data sources** in the header (see [Data sources](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/data-sources.md)).
* **Rundown** and **Designer** in the header: the [rundown](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/rundown.md) of inserts to put on air, and the [layout designer](https://docs.dbnetsoft.com/dbnetsoft/screenspro/screenspro-native/designer.md).

## Settings

| Setting                                | Meaning                                                                                                                                                                                                  |
| -------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Listen on                              | The network interface clients connect to. `0.0.0.0` = all, `127.0.0.1` = only this computer                                                                                                              |
| TCP port                               | The port ScreensPro clients connect to (default 6610, as ScreensPro Server)                                                                                                                              |
| Layout folder                          | The folder with the layouts, like ScreensPro Server's working directory. Empty = "ScreensPro Layouts" next to the configuration                                                                          |
| Transition mode                        | How a shown layout treats the layouts already on air in the main layer: **client** (as the client asks), **single** (one layout at a time, the new one replaces the others), **multiple** (added on top) |
| Transition                             | How layouts of the main layer come and go: none (their own animations), fade, fade in/out, fade and grow, move down / up / left / right, arrow. With a duration (empty = the effect's own)               |
| Layouts shown on start                 | One file per line for the background, main and foreground layer. Background and foreground layouts stay when layouts are taken or cleared                                                                |
| Preview                                | Frame rate of the preview. Lower or Off saves computing power                                                                                                                                            |
| Snapshots for clients                  | Width of the on-air and preview pictures the clients ask for                                                                                                                                             |
| Reload layouts when their files change | A changed layout loads again right away, even on air. It keeps its data and what the clients set on it                                                                                                   |
| Log every packet                       | Every packet from the clients in the ScreensPro log, for troubleshooting                                                                                                                                 |

## Layers

Like ScreensPro Server, a channel has three layers:

* **Background** layouts are below the main layer (`IsBackgroundLayout` of the load packets).
* **Main** layer: the layouts the clients show and take.
* **Foreground** layouts are above it (`IsForegroundLayout`), e.g. a logo or a clock.

Showing or clearing layouts in the main layer leaves background and foreground layouts on air.

## Inspecting a layout

**Inspect** next to a loaded layout shows it as it is right now, refreshed every second: its data context (and when it arrived), the last value clients set on each element property, the methods they called and its elements - named, bound and lists - with their text and whether they are visible. For a list it shows the items, the page and rows, and why it is empty (no data context yet, the bound path is not in it, no `<template>`). This is the first place to look when a layout doesn't show what you expect.

## Where files are

| What              | Where                                                           |
| ----------------- | --------------------------------------------------------------- |
| Configuration     | `%LOCALAPPDATA%\dbnetsoft\ScreensProNative\config.json`         |
| Logs              | `%LOCALAPPDATA%\dbnetsoft\ScreensProNative\logs\`               |
| Layouts (default) | `%LOCALAPPDATA%\dbnetsoft\ScreensProNative\ScreensPro Layouts\` |

## Command line

```
ScreensProNative.exe [--port=8091] [--bind=0.0.0.0] [--hidden] [--console] [--verbose]
                     [--config=<file>] [--instance=<name>] [--no-gpu | --gpu]
```

| Option       | Meaning                                                                                                            |
| ------------ | ------------------------------------------------------------------------------------------------------------------ |
| `--port`     | Port of the control window in the network (default 8091)                                                           |
| `--bind`     | Network interface of the control window                                                                            |
| `--hidden`   | Start in the tray without opening the window (e.g. autostart)                                                      |
| `--console`  | Show the log in a console window                                                                                   |
| `--verbose`  | Debug logging, including the messages of the layouts                                                               |
| `--config`   | Another configuration file                                                                                         |
| `--instance` | Run an independent copy next to the normal one, with its own configuration and logs (letters, digits, `-` and `_`) |
| `--no-gpu`   | Render without the graphics card, for computers where it causes problems                                           |
| `--gpu`      | Render with the graphics card even where ScreensPro Native finds none (a virtual machine)                          |

On a computer without a graphics card, such as a virtual machine without GPU partitioning, ScreensPro Native renders in software by itself. Without a graphics card, movement that covers the whole picture all the time costs frames, so layouts are then asked to reduce motion: a layout can hold such movement still with `@media (prefers-reduced-motion: reduce) { ... }` in its CSS. The background of the sample project does.

Starting ScreensPro Native again while it runs brings up the window of the running instance.

## Not there yet

ScreensPro Server has these, ScreensPro Native not yet:

* the text protocol on port 6611
* the Globals view
* `CarouselElement` and `ScrollingPanelElement` in XAML layouts are drawn without their motion
