alc

aframe-lsd-component

Color changing component, matching the camera rotation with the hsl color system

Showing:

Popularity

Downloads/wk

2

GitHub Stars

3

Maintenance

Last Commit

2yrs ago

Contributors

0

Package

Dependencies

0

Size (min+gzip)

0.9KB

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

aframe-lsd-component

Hue Saturation Lightness meets aframe ! Look around and see how the color is changing, according to the direction You're looking at.

Description

The component changes an entity materials color, while moving the camera ( or any oher object ) Simply put it in a entity : <a-sky lsd-component>

The color changes according to the Hue Saturation Lighness system, while the horizontal rotation correspond to the hue angle, and the vertical rotation correspond to the saturation value.

Installation

CDN script to include:

<script src="https://cdn.rawgit.com/gftruj/aframe-lsd-component/c1782554/dist/lsd-component.js"></script>

npm

npm install aframe-lsd-component

Attributes

PropertyDefaultDescription
baseHueAngle0The Hue angle when initialized
baseSaturation50The saturation value, when the camera rotation.z is 0
lightness50The 'l' from the hsl color system, it's constant.
saturationOffsetMin30The minimal saturation value when looking down.
saturationOffsetMax120The maximum saturation value when looking up.
activeCamera'a-camera'This selector takes the object to which the component should be corresponding
performancetrueChange the color either on tick (false), or on component change(true)

Example:

https://aframe-lsd.glitch.me/

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100