diff --git a/README.md b/README.md index dc80f9fc..843a42a8 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,15 @@ ## Bit By Bit Developers monorepo +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform -This git repo contains multiple bitbybit packages and contains code for 3D algorithms of Bit By Bit Developers platform which are open-sourced under MIT license. This library was previously UI dependant and was heaviy intertwined with BabylonJS game engine. It is now decoupled from our editors to ensure protection of our corporate identity and cloud services. BabylonJS layer is now also separated into special package @bitbybit-dev/babylonjs - this will cause the breaking change in v0.18.0. If you are using the version prior to v0.18.0 and depend on the @bitbybit-dev/core package, please consider updating to use @bitbybit-dev/babylonjs NPM package. @bitbybit-dev/core is now game engine independent layer. +This git repo contains multiple bitbybit packages and contains code for 3D algorithms of Bit By Bit Developers platform which are open-sourced under MIT license. + +This library was previously UI dependant and was heaviy intertwined with BabylonJS game engine. It is now decoupled from our editors to ensure protection of our corporate identity and cloud services. BabylonJS layer is now also separated into special package @bitbybit-dev/babylonjs - this will cause the breaking change in v0.18.0. If you are using the version prior to v0.18.0 and depend on the @bitbybit-dev/core package, please consider updating to use @bitbybit-dev/babylonjs NPM package. @bitbybit-dev/core is now game engine independent layer. -Visit https://bitbybit.dev to use our full cloud platform. ## Github https://github.com/bitbybit-dev/bitbybit diff --git a/packages/dev/babylonjs/README.md b/packages/dev/babylonjs/README.md index a10aba43..78ad027a 100644 --- a/packages/dev/babylonjs/README.md +++ b/packages/dev/babylonjs/README.md @@ -1,11 +1,13 @@ ## Bit By Bit Developers library for BABYLONJS game engine +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms of Bit By Bit Developers platform through BABYLONJS game engine. Code is open-sourced under MIT license. This library was previously intertwined in core package and is now separated. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit ## NPM diff --git a/packages/dev/babylonjs/lib/api/bitbybit/babylon/gaussian-splatting.ts b/packages/dev/babylonjs/lib/api/bitbybit/babylon/gaussian-splatting.ts index e90d8dda..cfffd23a 100644 --- a/packages/dev/babylonjs/lib/api/bitbybit/babylon/gaussian-splatting.ts +++ b/packages/dev/babylonjs/lib/api/bitbybit/babylon/gaussian-splatting.ts @@ -16,7 +16,7 @@ export class BabylonGaussianSplatting { * @disposableOutput true */ async create(inputs: Inputs.BabylonGaussianSplatting.CreateGaussianSplattingMeshDto): Promise { - if (inputs.url !== undefined) { + if (inputs.url) { const gs = BABYLON.SceneLoader.ImportMeshAsync(null, inputs.url, undefined, this.context.scene, undefined, ".ply").then((result) => { const gaussianSplattingMesh = result.meshes[0] as BABYLON.GaussianSplattingMesh; gaussianSplattingMesh.name = `gaussian-splatting-${Math.random()}`; diff --git a/packages/dev/base/README.md b/packages/dev/base/README.md index 8ba0ae6d..d8e8630f 100644 --- a/packages/dev/base/README.md +++ b/packages/dev/base/README.md @@ -1,11 +1,15 @@ ## Bit By Bit Developers Base Algorithms for CAD library +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This package contains base algorithms for our CAD platform. It has various helper functions for math, text, lists, vectors, matrix operations. It also contains some base types used accross bitbybit.dev platform on higher levels. This layer should be kept as lightweight as possible and ideally not contain any third-party dependencies as they just add to the weight and complexity. -This package is already used or will be used in these packages: +This package is already used or will be used in these packages: [@bitbybit-dev/babylonjs](https://www.npmjs.com/package/@bitbybit-dev/babylonjs) [@bitbybit-dev/threejs](https://www.npmjs.com/package/@bitbybit-dev/threejs) diff --git a/packages/dev/core/README.md b/packages/dev/core/README.md index 0f250f64..f920b456 100644 --- a/packages/dev/core/README.md +++ b/packages/dev/core/README.md @@ -1,5 +1,9 @@ ## Bit By Bit Developers core library +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform ## IMPORTANT @@ -7,8 +11,6 @@ If you used this npm package prior to v0.18.0, please use @bitbybit-dev/babylonj This project contains core 3D algorithms of Bit By Bit Developers platform which are open-sourced under MIT license. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit ## NPM diff --git a/packages/dev/jscad-worker/README.md b/packages/dev/jscad-worker/README.md index c6d0cac9..d638634d 100644 --- a/packages/dev/jscad-worker/README.md +++ b/packages/dev/jscad-worker/README.md @@ -1,11 +1,13 @@ ## Bit By Bit Developers JSCAD based CAD library in webworker +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms based on OPENJSCAD 3D CAD kernel via webworker. You can find JSCAD project on https://github.com/jscad. Bit By Bit Developers platform integrates this kernel into it's platform via this library. Currently we try to expose JSCAD library 1:1 in terms of functionality through our structured API, but as time goes we will have more unique algorithms in this package, which will be tuned specifically to our users. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit/tree/master/packages/dev/jscad-worker ## NPM diff --git a/packages/dev/jscad/README.md b/packages/dev/jscad/README.md index fd078f2f..41aeebbb 100644 --- a/packages/dev/jscad/README.md +++ b/packages/dev/jscad/README.md @@ -1,11 +1,13 @@ ## Bit By Bit Developers JSCAD based CAD library +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms based on OPENJSCAD 3D CAD kernel, which you can find on https://github.com/jscad. Bit By Bit Developers platform integrates this kernel into it's platform via this library. Currently we try to expose JSCAD library 1:1 in terms of functionality through our structured API, but as time goes we will have more unique algorithms in this package, which will be tuned specifically to our users. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit/tree/master/packages/dev/jscad ## NPM diff --git a/packages/dev/manifold-worker/README.md b/packages/dev/manifold-worker/README.md index bff7c600..50d6e364 100644 --- a/packages/dev/manifold-worker/README.md +++ b/packages/dev/manifold-worker/README.md @@ -1,13 +1,15 @@ ## Bit By Bit Developers Manifold based CAD library in webworker +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms based on manifold-3d 3D CAD kernel via webworker. Manifold project is developed by Emmett Lalish and Chun Kit LAM, you can find it on https://github.com/elalish/manifold. Bit By Bit Developers platform integrates this kernel into it's platform via this library. Currently we try to expose Manifold library 1:1 in terms of functionality through our structured API, but as time goes we will have more unique algorithms in this package, which will be tuned specifically to our users. This package should be used in browser based applications. If you want to use our manifold library in Node apps, consider checking @bitbybit-dev/manifold npm package, which this library wraps through webworker. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit/tree/master/packages/dev/manifold-worker ## NPM diff --git a/packages/dev/manifold/README.md b/packages/dev/manifold/README.md index 3e1967a2..d08a6b22 100644 --- a/packages/dev/manifold/README.md +++ b/packages/dev/manifold/README.md @@ -1,13 +1,15 @@ ## Bit By Bit Developers Manifold based CAD library +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms based on manifold-3d 3D CAD kernel, developed by Emmett Lalish and Chun Kit LAM, which you can find on https://github.com/elalish/manifold. Bit By Bit Developers platform integrates this kernel into it's platform via this library. Currently we try to expose Manifold library 1:1 in terms of functionality through our structured API, but as time goes we will have more unique algorithms in this package, which will be tuned specifically to our users. This package should work in Node and browser based applications. If you want to use this package in your browser based applications we highly suggest to use @bitbybit-dev/manifold-webworker npm package, which wraps this lib into promisified non-blocking API. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit/tree/master/packages/dev/manifold ## NPM diff --git a/packages/dev/occt-worker/README.md b/packages/dev/occt-worker/README.md index c438a655..25f320ad 100644 --- a/packages/dev/occt-worker/README.md +++ b/packages/dev/occt-worker/README.md @@ -1,11 +1,13 @@ # Bit By Bit Developers CAD algorithms exposing OCCT code via webworker +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes core OCCT 3D algorithms of Bit By Bit Developers platform via webworker. This code is open-sourced under MIT license. This package is independent of rendering frameworks such as BabylonJS or ThreeJS. You can build your own rendering pipeline in WebGL or WebGPU. While webworkers have their implementation in Node environment, this code is meant to be used in the browser environment. For Node environment check bitbybit-occt library. -Visit https://bitbybit.dev to use our full cloud platform. - # Github https://github.com/bitbybit-dev # NPM diff --git a/packages/dev/occt-worker/lib/api/occt/operations.ts b/packages/dev/occt-worker/lib/api/occt/operations.ts index 2c0f4e21..f9d700a3 100644 --- a/packages/dev/occt-worker/lib/api/occt/operations.ts +++ b/packages/dev/occt-worker/lib/api/occt/operations.ts @@ -81,7 +81,7 @@ export class OCCTOperations { } /** - * Extrudes the face along direction + * Extrudes the shape along direction - wire will produce shell, face will produce solid * @param inputs Shape to extrude and direction parameter with tolerance * @returns Resulting extruded shape * @group extrusions diff --git a/packages/dev/occt/README.md b/packages/dev/occt/README.md index c3771d0d..8336f5fe 100644 --- a/packages/dev/occt/README.md +++ b/packages/dev/occt/README.md @@ -1,11 +1,13 @@ # Bit By Bit Developers CAD algorithms using OpenCascade Technology kernel +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project contains core OCCT 3D algorithms of Bit By Bit Developers platform which are open-sourced under MIT license. This package is independent of rendering frameworks such as BabylonJS or ThreeJS. You can build your own rendering pipeline in WebGL or WebGPU. This code potentially can also be used alongside other OCCT libraries. This library can also run in NodeJS environments. -Visit https://bitbybit.dev to use our full cloud platform. - # Github https://github.com/bitbybit-dev # NPM diff --git a/packages/dev/threejs/README.md b/packages/dev/threejs/README.md index cdee7558..9dbd1218 100644 --- a/packages/dev/threejs/README.md +++ b/packages/dev/threejs/README.md @@ -1,11 +1,13 @@ ## Bit By Bit Developers CAD library for THREEJS game engine +Best way to support us - [Silver or Gold plan subscription](https://bitbybit.dev/auth/pick-plan) +Check out [3D Bits app for Shopify](https://apps.shopify.com/3d-bits-1) +Visit https://bitbybit.dev to use our full cloud platform. + Picture showing bitbybit.dev platform This project exposes 3D algorithms of Bit By Bit Developers platform through THREEJS game engine. Code is open-sourced under MIT license. -Visit https://bitbybit.dev to use our full cloud platform. - ## Github https://github.com/bitbybit-dev/bitbybit/tree/master/packages/dev/threejs ## NPM diff --git a/packages/dev/threejs/lib/api/bitbybit/draw.ts b/packages/dev/threejs/lib/api/bitbybit/draw.ts index 64735a07..9df4d30e 100644 --- a/packages/dev/threejs/lib/api/bitbybit/draw.ts +++ b/packages/dev/threejs/lib/api/bitbybit/draw.ts @@ -88,6 +88,28 @@ export class Draw extends DrawCore { return result; } + /** + * Creates draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes + * @param inputs option definition + * @returns options + * @group options + * @shortname simple + */ + optionsSimple(inputs: Inputs.Draw.DrawBasicGeometryOptions): Inputs.Draw.DrawBasicGeometryOptions { + return inputs; + } + + /** + * Creates draw options for occt shape geometry like edges, wires, faces, shells, solids and compounds + * @param inputs option definition + * @returns options + * @group options + * @shortname occt shape + */ + optionsOcctShape(inputs: Inputs.Draw.DrawOcctShapeOptions): Inputs.Draw.DrawOcctShapeOptions { + return inputs; + } + private handleJscadMesh(inputs: Inputs.Draw.DrawAny): Promise { return this.handleAsync(inputs, this.defaultPolylineOptions, (options) => { return this.drawHelper.drawSolidOrPolygonMesh({