---
title: Render a screenshot on the server
summary: Ask the server for an image of a model version from the viewpoint of the 3D viewer, which the camera gives in the metres the API works in.
order: 10
since: 3.0
languages: [javascript]
terms: [viewpoint, version]
see-also: [how-to/rendering/configure-the-render-backend, how-to/rendering/export-a-vector-drawing, reference/viewer3d]
---

# Render a screenshot on the server

For a thumbnail, a report image or a snapshot to attach to an issue, rendered from the same geometry the viewers show, on the server, without a browser. The server renders on a GPU or, where the instance is set up for it, on a software device; the image is the same, only the time differs ([[page:how-to/rendering/configure-the-render-backend]]).

## Live demo

```demo
name: server-screenshot
title: Render the current viewpoint on the server
models: schependomlaan
height: 520
notes: |
  Set up a viewpoint in the viewer and press **Render this viewpoint on the server**. The image the server returns appears in the panel with the time it took, queue included. On a GPU instance that is a second or two; on a CPU instance, longer.
```

## Steps

1. **Take the camera's viewpoint**: `viewer.getCamera().getViewpoint()` gives its position and direction
   in the measurement frame and in metres, which is what the API takes.
2. **Ask for the image** with `client.render.render(versionUuid, size, viewpoints)`; it resolves to the URL of the image.

```example
name: server-render
code: javascript/jssdk/serversnapshot.js
run: none
notes: Takes the viewpoint of the viewer's camera (metres, in the measurement frame, as the API works) and asks the server for a 300 × 300 image from it.
```

The report and BCF operations return images rendered the same way.

## Over HTTP

[[openapi:Render]] answers the PNG itself. Give a `camera` (a `position` and a `target` or `direction`, optionally `up`, in metres in the model's coordinates, as BCF has them) or a `view`, one of the named angles such as `iso_front_right` or `top`, which frames the whole model; `size` defaults to 300 × 300. With neither camera, view nor size it answers the screenshot the check-in stored, and renders the default view when there is none.

```try-it
operation: Render
method: POST
path: /openapi/model/Render
```

[[openapi:AugmentBcf]] takes a BCF 2.1 file and a `version_uuid` and answers the file with a snapshot rendered for every viewpoint that has a perspective camera, for issues kept in your own system.

## Limits

On an instance that renders on the CPU an image takes ten to fifty times longer than on a GPU; plan for it when a report has many images.

## Check

The image shows the model from the same direction as the viewer, 300 by 300 pixels.
