Skip to content

Commit

Permalink
Add Sky docs (#1006)
Browse files Browse the repository at this point in the history
  • Loading branch information
Methuselah96 authored May 31, 2024
1 parent 2616067 commit 3585c8e
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions types/three/examples/jsm/objects/Sky.d.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,24 @@
import { BoxGeometry, Mesh, ShaderMaterial } from "three";

/**
* {@link Sky} creates a ready to go sky environment for your scenes.
*
* @example
* const sky = new Sky();
* sky.scale.setScalar( 450000 );
*
* const phi = MathUtils.degToRad( 90 );
* const theta = MathUtils.degToRad( 180 );
* const sunPosition = new Vector3().setFromSphericalCoords( 1, phi, theta );
*
* sky.material.uniforms.sunPosition.value = sunPosition;
*
* scene.add( sky );
*/
export class Sky extends Mesh {
/**
* Create a new {@link Sky} instance.
*/
constructor();

geometry: BoxGeometry;
Expand Down

0 comments on commit 3585c8e

Please sign in to comment.