npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

videojs-vr-retinad

v1.0.0

Published

Video JS Plugin to allow integration with the Retinad Platform

Readme

videojs-vr-retinad

Use the player as you would use videojs-vr. This work aims to be used with a Retinad account to collect data. It is Brightcove Video Cloud compatible.

How to use

To use the plugin, subscribe to Retinad directly from our website. Copy the App ID and Account Key received by email.

How To Embed into a Page

Initialising the player and Retinad plugin

(function(){
    // Initialise Player
    var player = videojs( '#video-container', {
        techOrder: ['html5']
    });

    // Intialise Retinad Plugin with AppID and AccountKey
    player.retinad({
        "appId": "APP_ID_HERE",
        "accountKey": "ACCOUNT_KEY_HERE"
    });
})();

If using Brightcove Video Cloud, add crossOrigin="anonymous" in the options of the video tag. For example:

<video
id="video-container"
data-video-id="VIDEO_ID_HERE"
data-account="ACCOUNT_HERE"
data-player="default"
data-embed="default"
data-application-id
class="video-js"
crossOrigin="anonymous"
controls></video>

How to contribute

Fork this repository and post a pull request when everything is ready! Don't forget to minify src/js/videojs.retinad.js into dist/.

Build

npm install

Run

npm run serve

Example

Enter the App ID and Account Key in index.html. Build and run as explained previously.

Data format used by Retinad plugin

Time (Frame number)

The time corresponds to the current playback time of the 360° video. Frames are represented in tenths of seconds. For instance, for a playback time of 1.3 seconds, the frame number will be 13. Hundredths of seconds will be rounded to the nearest tenth of a second. A playback time of 1.25 will have a frame value of 13, while a playback time of 1.21 will have a frame value of 12.

Camera orientation (UV coordinate)

The orientation of the camera needs to be transposed to a UV format (Mercator Projection). Imagine that your video is in the format of an unwrapped sphere like this world map:

The lower left corner is U = 0 and V = 0. The Upper right corner is U = 1 and V = 1. The front is U = 0.5 and V = 0.5. U is the horizontal component and V the vertical component.

If you need help to convert your camera orientation to our coordinate system, don't hesitate to contact us.

Context (Video Name)

A context usually corresponds to a video. Its name will usually be the source of the video file.

TODO

The event handling still needs to be implemented for:

  • ~~Pause/Play (send these events to the server and stop the sampling function from collecting data, restart it at Play)~~
  • ~~Stop (or when we quit the page to send the remaining data to the server)~~
  • Change of display mode (Magic Window, Tap and Scroll, VR)

Credits

This work is sponsored by Retinad.