texture-generator

Procedural Equirectangular Textures

Stars

This texture renders a sky with stars. Because this version works on a line-per-line basis, the distribution and shape of stars near the poles are not that good. The generated texture is intended for color maps. Click on a snapshot to open it online.

Code example

Code template of parameters with their default values.

import * as PET from "pet/patterns/stars.js";
:
model.material.map = PET.texture( );
PET.material( model.material );

Parameters

The parameters of the texture generator are:

Hue variation is noticeable when the color of stars is not pure white.

API

All texture modules share the same API.

Online generator

online/stars.html

Source

src/patterns/stars.js

Back