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

gl-mesh3d

Package Overview
Dependencies
Maintainers
6
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gl-mesh3d - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

10

example/color.js

@@ -5,4 +5,4 @@ var createCamera = require('3d-view-controls')

var perspective = require('gl-mat4/perspective')
var createAxes = require('gl-axes')
var createSpikes = require('gl-spikes')
var createAxes = require('gl-axes3d')
var createSpikes = require('gl-spikes3d')
var createSelect = require('gl-select-static')

@@ -21,3 +21,3 @@ var getBounds = require('bound-points')

eye: [0,0,50],
center: [-0.5*(bounds[0][0]+bounds[1][0]),
center: [-0.5*(bounds[0][0]+bounds[1][0]),
-0.5*(bounds[0][1]+bounds[1][1]),

@@ -34,3 +34,3 @@ -0.5*(bounds[0][2]+bounds[1][2])],

var axes = createAxes(gl, { bounds: bounds })
var spikes = createSpikes(gl, {
var spikes = createSpikes(gl, {
bounds: bounds

@@ -85,2 +85,2 @@ })

}
render()
render()

@@ -5,4 +5,4 @@ var createCamera = require('3d-view-controls')

var perspective = require('gl-mat4/perspective')
var createAxes = require('gl-axes')
var createSpikes = require('gl-spikes')
var createAxes = require('gl-axes3d')
var createSpikes = require('gl-spikes3d')
var createSelect = require('gl-select-static')

@@ -21,3 +21,3 @@ var getBounds = require('bound-points')

eye: [0,0,50],
center: [-0.5*(bounds[0][0]+bounds[1][0]),
center: [-0.5*(bounds[0][0]+bounds[1][0]),
-0.5*(bounds[0][1]+bounds[1][1]),

@@ -35,3 +35,3 @@ -0.5*(bounds[0][2]+bounds[1][2])],

var axes = createAxes(gl, { bounds: bounds })
var spikes = createSpikes(gl, {
var spikes = createSpikes(gl, {
bounds: bounds

@@ -86,2 +86,2 @@ })

}
render()
render()

@@ -5,4 +5,4 @@ var createCamera = require('3d-view-controls')

var perspective = require('gl-mat4/perspective')
var createAxes = require('gl-axes')
var createSpikes = require('gl-spikes')
var createAxes = require('gl-axes3d')
var createSpikes = require('gl-spikes3d')
var createSelect = require('gl-select-static')

@@ -22,3 +22,3 @@ var getBounds = require('bound-points')

eye: [0,0,50],
center: [-0.5*(bounds[0][0]+bounds[1][0]),
center: [-0.5*(bounds[0][0]+bounds[1][0]),
-0.5*(bounds[0][1]+bounds[1][1]),

@@ -35,3 +35,3 @@ -0.5*(bounds[0][2]+bounds[1][2])],

var axes = createAxes(gl, { bounds: bounds })
var spikes = createSpikes(gl, {
var spikes = createSpikes(gl, {
bounds: bounds

@@ -86,2 +86,2 @@ })

}
render()
render()

@@ -5,4 +5,4 @@ var createCamera = require('3d-view-controls')

var perspective = require('gl-mat4/perspective')
var createAxes = require('gl-axes')
var createSpikes = require('gl-spikes')
var createAxes = require('gl-axes3d')
var createSpikes = require('gl-spikes3d')
var createSelect = require('gl-select-static')

@@ -21,3 +21,3 @@ var getBounds = require('bound-points')

eye: [0,0,50],
center: [-0.5*(bounds[0][0]+bounds[1][0]),
center: [-0.5*(bounds[0][0]+bounds[1][0]),
-0.5*(bounds[0][1]+bounds[1][1]),

@@ -34,3 +34,3 @@ -0.5*(bounds[0][2]+bounds[1][2])],

var axes = createAxes(gl, { bounds: bounds })
var spikes = createSpikes(gl, {
var spikes = createSpikes(gl, {
bounds: bounds

@@ -85,2 +85,2 @@ })

}
render()
render()

@@ -5,4 +5,4 @@ var createCamera = require('3d-view-controls')

var perspective = require('gl-mat4/perspective')
var createAxes = require('gl-axes')
var createSpikes = require('gl-spikes')
var createAxes = require('gl-axes3d')
var createSpikes = require('gl-spikes3d')
var createSelect = require('gl-select-static')

@@ -22,3 +22,3 @@ var getBounds = require('bound-points')

eye: [0,0,50],
center: [-0.5*(bounds[0][0]+bounds[1][0]),
center: [-0.5*(bounds[0][0]+bounds[1][0]),
-0.5*(bounds[0][1]+bounds[1][1]),

@@ -35,3 +35,3 @@ -0.5*(bounds[0][2]+bounds[1][2])],

var axes = createAxes(gl, { bounds: bounds })
var spikes = createSpikes(gl, {
var spikes = createSpikes(gl, {
bounds: bounds

@@ -86,2 +86,2 @@ })

}
render()
render()

@@ -326,6 +326,11 @@ 'use strict'

if(vertexIntensity) {
for(var i=0; i<vertexIntensity.length; ++i) {
var f = vertexIntensity[i]
intensityLo = Math.min(intensityLo, f)
intensityHi = Math.max(intensityHi, f)
if(params.vertexIntensityBounds) {
intensityLo = +params.vertexIntensityBounds[0]
intensityHi = +params.vertexIntensityBounds[1]
} else {
for(var i=0; i<vertexIntensity.length; ++i) {
var f = vertexIntensity[i]
intensityLo = Math.min(intensityLo, f)
intensityHi = Math.max(intensityHi, f)
}
}

@@ -830,3 +835,3 @@ } else if(cellIntensity) {

function createMeshShader(gl) {
var shader = createShader(gl, meshShader)
var shader = createShader(gl, meshShader.vertex, meshShader.fragment)
shader.attributes.position.location = 0

@@ -840,3 +845,3 @@ shader.attributes.color.location = 2

function createWireShader(gl) {
var shader = createShader(gl, wireShader)
var shader = createShader(gl, wireShader.vertex, wireShader.fragment)
shader.attributes.position.location = 0

@@ -849,3 +854,3 @@ shader.attributes.color.location = 2

function createPointShader(gl) {
var shader = createShader(gl, pointShader)
var shader = createShader(gl, pointShader.vertex, pointShader.fragment)
shader.attributes.position.location = 0

@@ -859,3 +864,3 @@ shader.attributes.color.location = 2

function createPickShader(gl) {
var shader = createShader(gl, pickShader)
var shader = createShader(gl, pickShader.vertex, pickShader.fragment)
shader.attributes.position.location = 0

@@ -867,3 +872,3 @@ shader.attributes.id.location = 1

function createPointPickShader(gl) {
var shader = createShader(gl, pointPickShader)
var shader = createShader(gl, pointPickShader.vertex, pointPickShader.fragment)
shader.attributes.position.location = 0

@@ -876,3 +881,3 @@ shader.attributes.id.location = 1

function createContourShader(gl) {
var shader = createShader(gl, contourShader)
var shader = createShader(gl, contourShader.vertex, contourShader.fragment)
shader.attributes.position.location = 0

@@ -882,4 +887,7 @@ return shader

function createSimplicialMesh(params) {
var gl = params.gl
function createSimplicialMesh(gl, params) {
if (arguments.length === 1) {
params = gl;
gl = params.gl;
}

@@ -886,0 +894,0 @@ var triShader = createMeshShader(gl)

{
"name": "gl-mesh3d",
"version": "1.2.0",
"version": "1.3.0",
"description": "3D mesh drawing",

@@ -14,3 +14,3 @@ "main": "mesh.js",

"gl-mat4": "^1.0.0",
"gl-shader": "^4.0.5",
"gl-shader": "4.2.0",
"gl-texture2d": "^2.0.8",

@@ -26,3 +26,11 @@ "gl-vao": "^1.1.3",

},
"devDependencies": {},
"devDependencies": {
"3d-view-controls": "^2.1.1",
"bound-points": "^1.0.0",
"bunny": "^1.0.1",
"canvas-fit": "^1.5.0",
"gl-axes3d": "^1.2.5",
"gl-select-static": "^2.0.2",
"gl-spikes3d": "^1.0.5"
},
"scripts": {

@@ -29,0 +37,0 @@ "test": "echo \"Error: no test specified\" && exit 1"

@@ -48,2 +48,4 @@ gl-mesh3d

+ `vertexIntensity`
+ `colormap`
+ `vertexIntensityBounds` intensity range for the colormap
+ `cellIntensity`

@@ -104,2 +106,2 @@ + `cellColors` A list of per cell color attributes

# Credits
(c) 2013-2015 Mikola Lysenko. MIT License
(c) 2013-2015 Mikola Lysenko. MIT License
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