https://github.com/naugtur/aframe-point-component
implements a-point based on THREE.js point object
https://github.com/naugtur/aframe-point-component
aframe point vr
Last synced: 3 months ago
JSON representation
implements a-point based on THREE.js point object
- Host: GitHub
- URL: https://github.com/naugtur/aframe-point-component
- Owner: naugtur
- License: mit
- Created: 2017-01-27T17:17:39.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-04-05T18:39:22.000Z (over 8 years ago)
- Last Synced: 2025-05-19T18:16:41.056Z (5 months ago)
- Topics: aframe, point, vr
- Language: JavaScript
- Homepage: http://naugtur.pl/aframe-point-component/
- Size: 787 KB
- Stars: 11
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
## aframe-point-component
A point component for [A-Frame](https://aframe.io). Creates a [THREE.Points
object](https://threejs.org/docs/#Reference/Objects/Points). Points remain a
point no matter the distance.
[VIEW DEMO](http://naugtur.pl/aframe-point-component/)
### API
| Property | Description | Default Value |
|-------------|---------------------------------------------------|---------------|
| size | size of rendered point (length of rectangle edge) | 1 |
| color | color definition, like in CSS | #888 |
| perspective | boolean - should it scale with distance or not | false |#### Custom Methods
`setPoints(array of arrays3)` - replace single point geometry with multiple points in one a-point instance
example
```js
element.components.point.setPoints([
[0,0,0]
[0,0,1]
[0,0,2]
...
])
```### Installation
npm install aframe-point
#### Browser
Install and use by directly including the [browser files](dist):
```html
My A-Frame Scene
OR
```
#### npm
Install via npm:
```bash
npm install aframe-point
```Then require and use.
```js
require('aframe');
require('aframe-point');
```