Giter Club home page Giter Club logo

puppetcam's Introduction

Puppetcam

Create screencast of a website

Examples

Record given length video from website

docker run -v "${PWD}/data:/home/node/Downloads" apicore/puppetcam https://tobiasahlin.com/spinkit/ -l 10000

The output will be a 10 second long full HD video saved as ./data/video.webm.

Record video from website using webside-side triggering

docker run -v "${PWD}/data:/home/node/Downloads" apicore/puppetcam https://site-triggered.example/ -t -l 10000

The recording is started when the window.triggerRenderer variable on the website becomes true and it is stopped when the same variable becomes false again. This option can be used to control the recording from the website itself. In this case the --length parameter is only used to set a sensible timeout. The output will be a full HD video saved as ./data/video.webm.

Command line arguments

export.js <url>

Record a video from a given url

Positionals:
  url  URL to record the video from                                     [string]

Options:
      --help           Show help                                       [boolean]
      --version        Show version number                             [boolean]
  -o, --output         Output path    [string] [default: ~/Downloads/video.webm]
  -l, --length         Video length in milliseconds     [number] [default: 5000]
  -w, --width          Video width                      [number] [default: 1920]
  -h, --height         Video height                     [number] [default: 1080]
  -t, --trigger        Use trigger from website       [boolean] [default: false]
  -s, --start-timeout  Start trigger timeout          [number] [default: 120000]
  -e, --end-timeout    End trigger timeout              [number] [default: 5000]

Running without Docker

Dependencies

  1. xvfb
  2. chrome browser
  3. nodejs
  4. npm modules listed in package.json
  5. up-to-date git submodules

Preparation

npm install
npm run install-extension

Usage

Use the same way as the dockerized version. A few examples:

node export.js https://tobiasahlin.com/spinkit/ -l 10000 # Outputs ~/Downloads/video.webm
node export.js https://tobiasahlin.com/spinkit/ -o spinkit.webm # Outputs ./spinkit.webm

Credits

puppetcam's People

Stargazers

 avatar  avatar

Watchers

 avatar

puppetcam's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.