
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
@gmetrixr/screenshot-glb
Advanced tools
A command line utility for taking screenshots of a glTF 2.0 binary file using Google's <model-viewer> component.
Easily take screenshots and create thumbnail images for glTF 2.0 Binary (GLB) files.
Use npm to install this tool:
npm install ---save @gmetrixr/screenshot-glb
To start taking screenshots of GLB files
$ screenshot-glb
Options:
--help Show help [boolean]
--version Show version number [boolean]
-i, --input Input glTF 2.0 binary (GLB) filepath [required]
-o, --output Output PNG screenshot filepath [required]
-t, --timeout Timeout length
-w, --width Output image width
-h, --height Output image height
-c, --color Change the background color of the rendered image
-@, --model_viewer_version
Pass the version of Model Viewer which should be used .eg 1.9
-m, --model_viewer_attributes
Pass <model-viewer> attributes as a URL search param string
-q, --image_quality
Change the image quality of the rendered JPG default 0.92
The module relies on using puppeteer to spawn a headless instance of Chrome to render Google's web component with the GLB model loaded.
For Shopify Employees
dev upyarn linkchmod 755 dist/cli.js to allow for executionscreenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE>Outside Development
yarn installyarn linkscreenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE>// Simply render a GLB to a JPG
$ screenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE>
// Change the width and height of the render
$ screenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE> --width 600 --height 1200
// Change the exposure and environment-image
$ screenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE> -m "environment-image=neutral&exposure=0.92"
// Use a specific version of Model Viewer to create the screenshot
$ screenshot-glb -i <PATH_TO_MODEL> -o <PATH_TO_OUTPUT_IMAGE> -@ 1.9
You may need to install the following packages in order for the headless Chrome instance to work on headless Linux VM machines:
gconf-service
libasound2
libatk1.0-0
libatk-bridge2.0-0
libc6
libcairo2
libcups2
libdbus-1-3
libexpat1
libfontconfig1
libgcc1
libgconf-2-4
libgdk-pixbuf2.0-0
libglib2.0-0
libgtk-3-0
libnspr4
libpango-1.0-0
libpangocairo-1.0-0
libstdc++6
libx11-6
libx11-xcb1
libxcb1
libxcomposite1
libxcursor1
libxdamage1
libxext6
libxfixes3
libxi6
libxrandr2
libxrender1
libxss1
libxtst6
ca-certificates
fonts-liberation
libappindicator1
libnss3
lsb-release
xdg-utils
wget
FAQs
A command line utility for taking screenshots of a glTF 2.0 binary file using Google's <model-viewer> component.
We found that @gmetrixr/screenshot-glb demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.