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 🙏

© 2024 – Pkg Stats / Ryan Hefner

paf-viewer

v0.0.6

Published

Open Source 3D Viewer from PeopleArtFactory.com

Downloads

16

Readme

PAF 3D VIEWER

Open Source 3D Viewer developed just using TypeScript & Three.js (WebGL). You can download yours virtual galleries from PeopleArtFactory.com and host it in any web server, whenever you want and just for free.

🔗 Learn More

Usage

  1. Create your virtual galleries in PeopleArtFactory.com and, when these will be ready to be published, download a zip file of each one, with all resources and a data.json file.

  2. Install the 'paf-viewer' package in your terminal:

npm install --save paf-viewer
  1. Import the package, needed types and the CSS file in your project:
import "./node_modules/paf-viewer/dist/style.css";
import { GalleryScene } from "paf-viewer";
//Typescript
import type { GalleryData } from "paf-viewer";
  1. Update each resource URL with the new location of in your server:
import galleryDataFile from "/YOUR ROUTE TO data.json";
if (galleryDataFile) {
  galleryDataFile.allResources.map((resource) => {
    resource.url = "/YOUR ROUTE TO FILES/" + resource.fileName;
  });
}
//Typescript
import galleryDataFile from "/YOUR ROUTE TO data.json";
const galleryData = galleryDataFile as unknown as GalleryData;
if (galleryData) {
  galleryData.allResources.map((resource) => {
    resource.url = "/YOUR ROUTE/" + resource.fileName;
  });
}
  1. Create a new instance of the GalleryScene:
const settings = { VIEWER_HIGHT: 190, HIGH_PERFORMANCE: true }; // (optional);
GalleryScene.instance.load(galleryDataFile, settings);

Setting Options (default values):


    VIEWER_HIGHT: 175,
    POINTER_SLOW_SPEED_RANGE: 50,
    POINTER_SLOW_SPEED_CORRECTION_FACTOR: 0.5,
    POINTER_FAST_SPEED_CORRECTION_FACTOR: 10,
    POINTER_ROTATION_RANGE: 30,
    POINTER_ROTATION_CORRECTION_FACTOR: 100,
    KEYS_ARROWS_SPEED: 10,
    WHEEL_RANGE: 90,
    WHEEL_CORRECTION_FACTOR: 15,

    THETA_FACTOR: 20,
    TRANSLATION_SPEED: 30,
    FAST_TRANSLATION_SPEED: 60,
    FAST_TRANSLATION_RANGE: 500,
    ZOOM_SPEED: 1.5,
    PHI_SPEED: 0.8,
    THETA_SPEED: 0.4,
    COLLISION_DISTANCE:50,
    CONTENT_DISTANCE: 250,
   
    INITIAL_POSITION: [number, number, number];
    START_MODAL: "none" | "navigation-info" | "brochure";
    HIGH_PERFORMANCE: true; // Switch off all Spot Lights and Shadows.

Authors

License

MIT

Acknowledgements

Proud to be with the best people on Earth.