Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@luma.gl/shadertools

Package Overview
Dependencies
Maintainers
8
Versions
249
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@luma.gl/shadertools - npm Package Compare versions

Comparing version 8.0.0-alpha.3 to 8.0.0-alpha.5

8

dist/es5/modules/index.js

@@ -56,12 +56,12 @@ "use strict";

});
Object.defineProperty(exports, "gouraudlighting", {
Object.defineProperty(exports, "gouraudLighting", {
enumerable: true,
get: function get() {
return _phongLighting.gouraudlighting;
return _phongLighting.gouraudLighting;
}
});
Object.defineProperty(exports, "phonglighting", {
Object.defineProperty(exports, "phongLighting", {
enumerable: true,
get: function get() {
return _phongLighting.phonglighting;
return _phongLighting.phongLighting;
}

@@ -68,0 +68,0 @@ });

@@ -8,3 +8,3 @@ "use strict";

});
exports.phonglighting = exports.gouraudlighting = void 0;
exports.phongLighting = exports.gouraudLighting = void 0;

@@ -15,3 +15,3 @@ var _lights = _interopRequireDefault(require("../lights/lights"));

var gouraudlighting = {
var gouraudLighting = {
name: 'gouraud-lighting',

@@ -25,4 +25,4 @@ dependencies: [_lights["default"]],

};
exports.gouraudlighting = gouraudlighting;
var phonglighting = {
exports.gouraudLighting = gouraudLighting;
var phongLighting = {
name: 'phong-lighting',

@@ -36,14 +36,22 @@ dependencies: [_lights["default"]],

};
exports.phonglighting = phonglighting;
exports.phongLighting = phongLighting;
var INITIAL_MODULE_OPTIONS = {};
function getMaterialUniforms(material) {
var materialUniforms = {};
materialUniforms.lighting_uAmbient = material.ambient;
materialUniforms.lighting_uDiffuse = material.diffuse;
materialUniforms.lighting_uShininess = material.shininess;
materialUniforms.lighting_uSpecularColor = material.specularColor.map(function (x) {
return x / 255;
});
return materialUniforms;
var _material$ambient = material.ambient,
ambient = _material$ambient === void 0 ? 0.35 : _material$ambient,
_material$diffuse = material.diffuse,
diffuse = _material$diffuse === void 0 ? 0.6 : _material$diffuse,
_material$shininess = material.shininess,
shininess = _material$shininess === void 0 ? 32 : _material$shininess,
_material$specularCol = material.specularColor,
specularColor = _material$specularCol === void 0 ? [30, 30, 30] : _material$specularCol;
return {
lighting_uAmbient: ambient,
lighting_uDiffuse: diffuse,
lighting_uShininess: shininess,
lighting_uSpecularColor: specularColor.map(function (x) {
return x / 255;
})
};
}

@@ -50,0 +58,0 @@

@@ -9,5 +9,5 @@ export { default as fp32 } from './fp32/fp32';

export { default as diffuse } from './diffuse/diffuse';
export { gouraudlighting, phonglighting } from './phong-lighting/phong-lighting';
export { gouraudLighting, phongLighting } from './phong-lighting/phong-lighting';
export { default as pbr } from './pbr/pbr';
export { default as _transform } from './transform/transform';
//# sourceMappingURL=index.js.map
import lights from '../lights/lights';
import lightingShader from './phong-lighting.glsl';
const gouraudlighting = {
const gouraudLighting = {
name: 'gouraud-lighting',

@@ -12,3 +12,3 @@ dependencies: [lights],

};
const phonglighting = {
const phongLighting = {
name: 'phong-lighting',

@@ -25,8 +25,14 @@ dependencies: [lights],

function getMaterialUniforms(material) {
const materialUniforms = {};
materialUniforms.lighting_uAmbient = material.ambient;
materialUniforms.lighting_uDiffuse = material.diffuse;
materialUniforms.lighting_uShininess = material.shininess;
materialUniforms.lighting_uSpecularColor = material.specularColor.map(x => x / 255);
return materialUniforms;
const {
ambient = 0.35,
diffuse = 0.6,
shininess = 32,
specularColor = [30, 30, 30]
} = material;
return {
lighting_uAmbient: ambient,
lighting_uDiffuse: diffuse,
lighting_uShininess: shininess,
lighting_uSpecularColor: specularColor.map(x => x / 255)
};
}

@@ -52,3 +58,3 @@

export { gouraudlighting, phonglighting };
export { gouraudLighting, phongLighting };
//# sourceMappingURL=phong-lighting.js.map

@@ -9,5 +9,5 @@ export { default as fp32 } from './fp32/fp32';

export { default as diffuse } from './diffuse/diffuse';
export { gouraudlighting, phonglighting } from './phong-lighting/phong-lighting';
export { gouraudLighting, phongLighting } from './phong-lighting/phong-lighting';
export { default as pbr } from './pbr/pbr';
export { default as _transform } from './transform/transform';
//# sourceMappingURL=index.js.map
import lights from '../lights/lights';
import lightingShader from './phong-lighting.glsl';
var gouraudlighting = {
var gouraudLighting = {
name: 'gouraud-lighting',

@@ -12,3 +12,3 @@ dependencies: [lights],

};
var phonglighting = {
var phongLighting = {
name: 'phong-lighting',

@@ -25,10 +25,18 @@ dependencies: [lights],

function getMaterialUniforms(material) {
var materialUniforms = {};
materialUniforms.lighting_uAmbient = material.ambient;
materialUniforms.lighting_uDiffuse = material.diffuse;
materialUniforms.lighting_uShininess = material.shininess;
materialUniforms.lighting_uSpecularColor = material.specularColor.map(function (x) {
return x / 255;
});
return materialUniforms;
var _material$ambient = material.ambient,
ambient = _material$ambient === void 0 ? 0.35 : _material$ambient,
_material$diffuse = material.diffuse,
diffuse = _material$diffuse === void 0 ? 0.6 : _material$diffuse,
_material$shininess = material.shininess,
shininess = _material$shininess === void 0 ? 32 : _material$shininess,
_material$specularCol = material.specularColor,
specularColor = _material$specularCol === void 0 ? [30, 30, 30] : _material$specularCol;
return {
lighting_uAmbient: ambient,
lighting_uDiffuse: diffuse,
lighting_uShininess: shininess,
lighting_uSpecularColor: specularColor.map(function (x) {
return x / 255;
})
};
}

@@ -54,3 +62,3 @@

export { gouraudlighting, phonglighting };
export { gouraudLighting, phongLighting };
//# sourceMappingURL=phong-lighting.js.map
{
"name": "@luma.gl/shadertools",
"version": "8.0.0-alpha.3",
"version": "8.0.0-alpha.5",
"description": "Shader module system for luma.gl",

@@ -42,3 +42,3 @@ "license": "MIT",

},
"gitHead": "d5d70464aa3a9a1709830070fa70100b71009432"
"gitHead": "07f5ea0576cd58ec3ff355c1ac493059c863dd51"
}

@@ -9,3 +9,3 @@ export {default as fp32} from './fp32/fp32';

export {default as diffuse} from './diffuse/diffuse';
export {gouraudlighting, phonglighting} from './phong-lighting/phong-lighting';
export {gouraudLighting, phongLighting} from './phong-lighting/phong-lighting';
export {default as pbr} from './pbr/pbr';

@@ -12,0 +12,0 @@

import lights from '../lights/lights';
import lightingShader from './phong-lighting.glsl';
const gouraudlighting = {
const gouraudLighting = {
name: 'gouraud-lighting',

@@ -14,3 +14,3 @@ dependencies: [lights],

const phonglighting = {
const phongLighting = {
name: 'phong-lighting',

@@ -28,8 +28,10 @@ dependencies: [lights],

function getMaterialUniforms(material) {
const materialUniforms = {};
materialUniforms.lighting_uAmbient = material.ambient;
materialUniforms.lighting_uDiffuse = material.diffuse;
materialUniforms.lighting_uShininess = material.shininess;
materialUniforms.lighting_uSpecularColor = material.specularColor.map(x => x / 255);
return materialUniforms;
const {ambient = 0.35, diffuse = 0.6, shininess = 32, specularColor = [30, 30, 30]} = material;
return {
lighting_uAmbient: ambient,
lighting_uDiffuse: diffuse,
lighting_uShininess: shininess,
lighting_uSpecularColor: specularColor.map(x => x / 255)
};
}

@@ -51,2 +53,2 @@

export {gouraudlighting, phonglighting};
export {gouraudLighting, phongLighting};

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc