Get started with WebViewer Video - Video Collaboration SDK
Collaborate and review videos frame by frame. WebViewer video allows users to annotate video frames, comment on frames, collaborate and review videos.
Annotations will be tied to specific frames and will only be rendered, when the video is seeked to the specific frames. This guide will show you how to get started with a free trial.
The source code for this project is available in our Git repo.
Prerequisites
Prior to starting, you should have already installed Node and npm.
Get your Apryse trial key.
License Key
Apryse collects some data regarding your usage of the SDK for product improvement.
The data that Apryse collects include:
The names and number of API calls
The number of pages in a document
The version of the SDK
The language of the SDK
For clarity, no other data is collected by the SDK and Apryse has no access to the contents of your documents.
If you wish to continue without data collection, contact us and we will email you a no-tracking trial key for you to get started.
Initial setup
Clone the repo to a specific directory and then navigate to it:
Below is a sample setup of the video package with webviewer.
initializeVideoViewer is called to give WebViewer the ability to handle the loading of video files. Afterwards, a video can be loaded with loadVideo. Lastly settings to customize the behavior of the controls can be passed in when calling initializeVideoViewer.
1import WebViewer from '@pdftron/webviewer';
2import { initializeVideoViewer, renderControlsToDOM } from '@pdftron/webviewer-video';
Importing and exporting annotations works the exact same way as it does on WebViewer, with the video annotations having additional the properties start-time and end-time.
Server configuration
Make sure your server has byte-range requests enabled to allow video streaming.