Skip to content

Commit

Permalink
Increased version number
Browse files Browse the repository at this point in the history
  • Loading branch information
Elius94 committed Jan 24, 2023
1 parent 1472b3d commit a609f7b
Show file tree
Hide file tree
Showing 4 changed files with 76 additions and 71 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

![lensflare](https://user-images.githubusercontent.com/14907987/212742055-8db7599e-2e93-4303-b979-9762f803483d.gif)

[![NPM](https://img.shields.io/npm/v/photo-sphere-viewer-lensflare-plugin.svg)](https://www.npmjs.com/package/photo-sphere-viewer-lensflare-plugin) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

## Installation

### NPM
Expand Down
29 changes: 29 additions & 0 deletions example/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

<!-- Plugins -->
<script src="http://localhost:3000/index.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@photo-sphere-viewer/autorotate-plugin/index.min.js"></script>

<!-- the viewer container must have a defined size -->
<div id="viewer" style="width: 100vw; height: 100vh;"></div>
Expand All @@ -29,6 +30,10 @@
defaultYaw: 20.75,
defaultPitch: 0.17,
plugins: [
[PhotoSphereViewer.AutorotatePlugin, {
autostartDelay: 1000,
autorotateSpeed: '2rpm',
}],
[PhotoSphereViewerLensflarePlugin, {
lensflares: [
{
Expand All @@ -44,4 +49,28 @@
}]
]
});

const autorotatePlugin = viewer.getPlugin(PhotoSphereViewer.AutorotatePlugin);

const points = [
{
position: { yaw: '20.6deg', pitch: '21.2deg' },
pause: 0,
},
{
position: { yaw: '185deg', pitch: '2deg' },
pause: 0,
},
{
position: { yaw: '165deg', pitch: '-90deg' },
pause: 0,
},
];

function randomPoints() {
autorotatePlugin.setKeypoints(points);
}

viewer.addEventListener('ready', randomPoints, { once: true });

</script>
108 changes: 41 additions & 67 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "photo-sphere-viewer-lensflare-plugin",
"version": "1.0.2",
"version": "1.0.3",
"description": "Plugin to add lens flares on a 360° pano built with photo-sphere-viewer",
"main": "dist/index.js",
"module": "dist/index.module.js",
Expand Down Expand Up @@ -37,11 +37,11 @@
"three": "^0.148.0"
},
"devDependencies": {
"@types/three": "^0.148.0",
"rollup": "^3.10.0",
"@types/three": "^0.148.1",
"rollup": "^3.10.1",
"rollup-plugin-generate-package-json": "^3.2.0",
"rollup-plugin-postcss": "^4.0.2",
"rollup-plugin-string": "^3.0.0",
"rollup-plugin-ts": "^3.1.1"
"rollup-plugin-ts": "^3.2.0"
}
}

0 comments on commit a609f7b

Please sign in to comment.