Buckets:
| import { cameraViewMatrix } from './Camera.js'; | |
| import { transformedNormalView } from './Normal.js'; | |
| import { positionViewDirection } from './Position.js'; | |
| import { materialRefractionRatio } from './MaterialProperties.js'; | |
| /** | |
| * The reflect vector in view space. | |
| * | |
| * @tsl | |
| * @type {Node<vec3>} | |
| */ | |
| export const reflectView = /*@__PURE__*/ positionViewDirection.negate().reflect( transformedNormalView ); | |
| /** | |
| * The refract vector in view space. | |
| * | |
| * @tsl | |
| * @type {Node<vec3>} | |
| */ | |
| export const refractView = /*@__PURE__*/ positionViewDirection.negate().refract( transformedNormalView, materialRefractionRatio ); | |
| /** | |
| * Used for sampling cube maps when using cube reflection mapping. | |
| * | |
| * @tsl | |
| * @type {Node<vec3>} | |
| */ | |
| export const reflectVector = /*@__PURE__*/ reflectView.transformDirection( cameraViewMatrix ).toVar( 'reflectVector' ); | |
| /** | |
| * Used for sampling cube maps when using cube refraction mapping. | |
| * | |
| * @tsl | |
| * @type {Node<vec3>} | |
| */ | |
| export const refractVector = /*@__PURE__*/ refractView.transformDirection( cameraViewMatrix ).toVar( 'reflectVector' ); | |
Xet Storage Details
- Size:
- 1.08 kB
- Xet hash:
- b11fff9a746ab3881da0ed1ef6032fece4df306e74fd8dd9b0298a088e1c2698
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.