geom-export-obj
Advanced tools
Comparing version
# Changelog | ||
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. | ||
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines. | ||
## [1.1.1](https://github.com/dmnsgn/geom-export-obj/compare/v1.1.0...v1.1.1) (2024-07-07) | ||
# [1.1.0](https://github.com/dmnsgn/geom-export-obj/compare/v1.0.3...v1.1.0) (2021-10-02) | ||
@@ -6,0 +10,0 @@ |
@@ -17,3 +17,3 @@ /** | ||
offsets = { positions: 0, normals: 0, uvs: 0 }, | ||
defaultName | ||
defaultName, | ||
) { | ||
@@ -58,3 +58,3 @@ // object name | ||
.filter((a) => a ?? true) | ||
.join("/") | ||
.join("/"), | ||
); | ||
@@ -99,3 +99,3 @@ output += `f ${face.join(" ")}\n`; | ||
}, | ||
{ output: header, offsets } | ||
{ output: header, offsets }, | ||
); | ||
@@ -107,1 +107,3 @@ } | ||
export default geomExportObj; | ||
export * from "./types.js"; |
{ | ||
"name": "geom-export-obj", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Convert one (or more) simplicial complex geometry (positions/cells/normals/uvs) into an OBJ string.", | ||
@@ -15,3 +15,6 @@ "keywords": [ | ||
"bugs": "https://github.com/dmnsgn/geom-export-obj/issues", | ||
"repository": "dmnsgn/geom-export-obj", | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/dmnsgn/geom-export-obj.git" | ||
}, | ||
"funding": [ | ||
@@ -31,17 +34,23 @@ { | ||
"type": "module", | ||
"exports": "./index.js", | ||
"exports": { | ||
".": { | ||
"types": "./types/index.d.ts", | ||
"default": "./index.js" | ||
} | ||
}, | ||
"main": "index.js", | ||
"types": "types/index.d.ts", | ||
"devDependencies": { | ||
"cameras": "^3.0.1", | ||
"core-js": "^3.11.1", | ||
"es-module-shims": "^0.10.4", | ||
"gl-matrix": "^3.3.0", | ||
"primitive-geometry": "^2.0.0", | ||
"cameras": "^3.1.1", | ||
"core-js": "^3.37.1", | ||
"es-module-shims": "^1.10.0", | ||
"gl-matrix": "^3.4.3", | ||
"primitive-geometry": "^2.10.1", | ||
"regl": "^2.1.0" | ||
}, | ||
"engines": { | ||
"node": ">=15.0.0", | ||
"npm": ">=7.0.0" | ||
"node": ">=22.0.0", | ||
"npm": ">=10.5.1", | ||
"snowdev": ">=2.2.x" | ||
} | ||
} |
@@ -5,4 +5,4 @@ # geom-export-obj | ||
[](https://www.npmjs.com/package/geom-export-obj) | ||
[](https://www.npmjs.com/package/geom-export-obj) | ||
[](https://github.com/dmnsgn/geom-export-obj/blob/main/package.json) | ||
[](https://bundlephobia.com/package/geom-export-obj) | ||
[](https://github.com/dmnsgn/geom-export-obj/blob/main/package.json) | ||
[](https://github.com/microsoft/TypeScript) | ||
@@ -50,12 +50,12 @@ [](https://conventionalcommits.org) | ||
<dl> | ||
<dt><a href="#SimplicialComplex">SimplicialComplex</a> : <code>Object</code></dt> | ||
<dt><a href="#SimplicialComplex">SimplicialComplex</a> : <code>object</code></dt> | ||
<dd><p>Geometry definition. All optional.</p> | ||
</dd> | ||
<dt><a href="#GeomExportObjOffsets">GeomExportObjOffsets</a> : <code>Object</code></dt> | ||
<dt><a href="#GeomExportObjOffsets">GeomExportObjOffsets</a> : <code>object</code></dt> | ||
<dd><p>Offsets to for cells. Useful if appending to another obj string. Used internally.</p> | ||
</dd> | ||
<dt><a href="#GeomExportObjOptions">GeomExportObjOptions</a> : <code>Object</code></dt> | ||
<dt><a href="#GeomExportObjOptions">GeomExportObjOptions</a> : <code>object</code></dt> | ||
<dd><p>Options for exporter.</p> | ||
</dd> | ||
<dt><a href="#GeomExportObjReturnValue">GeomExportObjReturnValue</a> : <code>Object</code></dt> | ||
<dt><a href="#GeomExportObjReturnValue">GeomExportObjReturnValue</a> : <code>object</code></dt> | ||
<dd></dd> | ||
@@ -70,3 +70,3 @@ </dl> | ||
- [geomExportObj(geometries, [options])](#exp_module_geomExportObj--geomExportObj) ⇒ [<code>GeomExportObjReturnValue</code>](#GeomExportObjReturnValue) ⏏ | ||
- [~parse(geometry, [offsets], [defaultName])](#module_geomExportObj--geomExportObj..parse) ⇒ <code>string</code> | ||
- [.parse(geometry, [offsets], [defaultName])](#module_geomExportObj--geomExportObj.parse) ⇒ <code>string</code> | ||
@@ -86,9 +86,9 @@ <a name="exp_module_geomExportObj--geomExportObj"></a> | ||
<a name="module_geomExportObj--geomExportObj..parse"></a> | ||
<a name="module_geomExportObj--geomExportObj.parse"></a> | ||
#### geomExportObj~parse(geometry, [offsets], [defaultName]) ⇒ <code>string</code> | ||
#### geomExportObj.parse(geometry, [offsets], [defaultName]) ⇒ <code>string</code> | ||
Parse a simplicial complex and return an obj string | ||
**Kind**: inner method of [<code>geomExportObj</code>](#exp_module_geomExportObj--geomExportObj) | ||
**Kind**: static method of [<code>geomExportObj</code>](#exp_module_geomExportObj--geomExportObj) | ||
**See**: http://paulbourke.net/dataformats/obj/ | ||
@@ -104,7 +104,7 @@ | ||
## SimplicialComplex : <code>Object</code> | ||
## SimplicialComplex : <code>object</code> | ||
Geometry definition. All optional. | ||
**Kind**: global typedef | ||
**Kind**: global typedef | ||
**Properties** | ||
@@ -123,7 +123,7 @@ | ||
## GeomExportObjOffsets : <code>Object</code> | ||
## GeomExportObjOffsets : <code>object</code> | ||
Offsets to for cells. Useful if appending to another obj string. Used internally. | ||
**Kind**: global typedef | ||
**Kind**: global typedef | ||
**Properties** | ||
@@ -139,7 +139,7 @@ | ||
## GeomExportObjOptions : <code>Object</code> | ||
## GeomExportObjOptions : <code>object</code> | ||
Options for exporter. | ||
**Kind**: global typedef | ||
**Kind**: global typedef | ||
**Properties** | ||
@@ -155,5 +155,5 @@ | ||
## GeomExportObjReturnValue : <code>Object</code> | ||
## GeomExportObjReturnValue : <code>object</code> | ||
**Kind**: global typedef | ||
**Kind**: global typedef | ||
**Properties** | ||
@@ -160,0 +160,0 @@ |
/** | ||
* @typedef {Object} SimplicialComplex Geometry definition. All optional. | ||
* @typedef {object} SimplicialComplex Geometry definition. All optional. | ||
* @property {number[]} positions | ||
@@ -12,3 +12,3 @@ * @property {number[]} normals | ||
/** | ||
* @typedef {Object} GeomExportObjOffsets Offsets to for cells. Useful if appending to another obj string. Used internally. | ||
* @typedef {object} GeomExportObjOffsets Offsets to for cells. Useful if appending to another obj string. Used internally. | ||
* @property {number} positions | ||
@@ -20,3 +20,3 @@ * @property {number} normals | ||
/** | ||
* @typedef {Object} GeomExportObjOptions Options for exporter. | ||
* @typedef {object} GeomExportObjOptions Options for exporter. | ||
* @property {string} [header=# geom-export-obj\n] Header to be prepended to the file. | ||
@@ -28,3 +28,3 @@ * @property {string} [prefix=Mesh_] Prefix for object names. | ||
/** | ||
* @typedef {Object} GeomExportObjReturnValue | ||
* @typedef {object} GeomExportObjReturnValue | ||
* @property {string} output The obj as a string. | ||
@@ -31,0 +31,0 @@ * @property {GeomExportObjOffsets} offsets |
export default geomExportObj; | ||
export * from "./types.js"; | ||
/** | ||
@@ -3,0 +4,0 @@ * @module geomExportObj |
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
17825
1.89%191
1.06%0
-100%