Displaying 1 to 20 from 21 results

THREE.MeshLine - Mesh replacement for THREE.Line

  •    Javascript

First, create the list of vertices that will define the line. MeshLine accepts THREE.Geometry (looking up the .vertices in it) and Array/Float32Array. THREE.BufferGeometry coming soon, and may be others like Array of THREE.Vector3. Once you have that, you can create a new MeshLine, and call .setGeometry() passing the vertices.

term-size - Reliably get the terminal window size

  •    Javascript

Confirmed working on macOS, Linux, and Windows.Returns an Object with columns and rows properties.




split-lines - Split lines into an array of lines

  •    Javascript

String to split.Preserve the line separator at the end of every line, except the last line, which will never contain one.

svg-path-parser - A parser for SVG's path syntax

  •    Javascript

An SVG path parser, originally built from the PEG.js grammar specified here, published as an NPM module.Grammar originally written by Gavin Kistner.

extrude-polyline - triangulates a 2D polyline into a stroke

  •    Javascript

Extrudes a 2D polyline with a given line thickness and the desired join/cap types. Tries to maintain visual consistency with HTML5 2D context stroking.The returned mesh is a simplicial complex.


three-line-2d - lines expanded in a vertex shader

  •    Javascript

A utility for 2D line drawing in ThreeJS, by expanding a polyline in a vertex shader for variable thickness, anti-aliasing, gradients, line dashes, and other GPU effects.Works in ThreeJS r69-r75, and possibly newer versions.

extract-stack - Extract the actual stack of an error

  •    Javascript

It gracefully handles cases where the stack is undefined or empty and returns an empty string.Returns the actual stack part of the error stack.

parse-header-stream - parse http or smtp headers from a stream

  •    Javascript

Return a writable stream that parses incoming lines for http/email style headers. When the headers are fully read, cb(err, headers) fires with the header fields or an error.

screen-projected-lines - draw wireframes using triangles in screen-projected coordinates

  •    Javascript

This module triangulates edges from a simplicial complex and returns arrays you can use as attributes in a vertex shader.This module does not currently support miter joins, but that would be nice to have.

window-size - Reliable way to to get the height and width of the terminal/console in a node

  •    Javascript

Reliable way to get the height and width of terminal/console, since it's not calculated or updated the same way on all platforms, environments and node.js versions. The main export is either an object with width and height properties, or undefined if unable to get width and height.

slice-lines - Fast algorithm for extracting a subset of lines from a string

  •    Javascript

Very efficient module for extracting a subset of lines from a string. Similar to str.slice(beginIndex, endIndex) except that the indexes are lines instead of bytes.

multili - Function to remove indentation in multi-lines template literals (string) based on the shortest indented line

  •    Javascript

Function to remove indentation in multi-lines template literals (string) based on the shortest indented line. You can also pass an array of lines instead of a string; in this case, the return value will also be an array.

linedesigns - Digitizing an elementary school craft for easy prototyping.

  •    Go

linedesigns is the digitization of an arts craft I was taught in my elementary school days. It's meant to help prototype new designs quickly since doing these designs by hand can take hours. linedesigns commands generally follow the pattern of taking in a series of coordinates that process/connect to one another in a counter-clockwise fashion.

tty-screen - Terminal screen detection - cross platform, major ruby interpreters

  •    Ruby

Terminal screen size detection which works on Linux, OS X and Windows/Cygwin platforms and supports MRI, JRuby and Rubinius interpreters. TTY::Screen provides independent terminal screen size detection component for TTY toolkit.

num-lines - Count the number of lines in a string

  •    Javascript

Count the number of lines in a string. Cross platform. Accounts for \n and \r\n line separators.