Research
Security News
Threat Actor Exposes Playbook for Exploiting npm to Build Blockchain-Powered Botnets
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
This library implements constructive solid geometry operations for narrowband level sets. It is part of the rle family of modules for processing level sets.
Via npm:
npm install rle-csg
Here is an example showing how to use the library:
var core = require("rle-core");
var csg = require("rle-csg");
var cylinder = core.sampleSolid([-20, -20, -20], [20, 20, 20], function(x) {
return Math.max(Math.abs(x[2]) - 15, Math.sqrt(x[0]*x[0] + x[1]*x[1]) - 5.5);
});
var box = core.sampleSolid([-10, -10, -10], [10, 10, 10], function(x) {
return Math.max(Math.abs(x[0]), Math.abs(x[1]), Math.abs(x[2])) - 7.0;
});
var sphere = core.sampleSolid([-10,-10,-10], [10,10,10], function(x) {
return Math.sqrt(x[0]*x[0]+x[1]*x[1]+x[2]*x[2]) - 8.0;
});
var shape = csg.subtract(csg.unite(box, cylinder), sphere);
Which gives you a shape that looks like this:
If you want to see the result in 3D/WebGL, click here for an interactive demo
To import the library, just do:
var csg = require("rle-csg");
Or you can also just use the methods exposed by rle-all. There are 4 functions exposed by this library:
csg.unite(a, b)
Computes the set-theoretic union of solids a and b
csg.intersect(a, b)
Intersects solids a and b
csg.subtract(a, b)
Subtracts the solid a from b
csg.complement(a)
Returns the complement of a
(c) 2013 Mikola Lysenko. BSD License
FAQs
Constructive solid geometry library for narrow band level sets
The npm package rle-csg receives a total of 3 weekly downloads. As such, rle-csg popularity was classified as not popular.
We found that rle-csg demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
Security News
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
Security News
Research
A malicious npm package disguised as a WhatsApp client is exploiting authentication flows with a remote kill switch to exfiltrate data and destroy files.