@zeainc/zea-cad

CAD Extension for Zea Engine.

Usage no npm install needed!

<script type="module">
  import zeaincZeaCad from 'https://cdn.skypack.dev/@zeainc/zea-cad';
</script>

README

Zea CAD

NPM Package Build Size NPM Downloads

Introduction

Zea CAD is a Zea Engine plug-in for loading and visualizing large CAD and BIM files in the browser. Zea Engine provides a collection of basic features for web based visualization, kinematics and interaction. Zea CAD adds the ability to load CAD and BIM data and visualize it in the browser.


Documentation

Full documentation with concepts, tutorials, live examples, API documentation and more; can be found at the zea cad docs site: https://docs.zea.live/zea-cad

These docs allow developers to get started with the Zea CAD by downloading free and open-source demo content and using Zea's publicly distributed client-side libraries.


Licensing

This plug-in is under a custom license, expand the section below to read it.

Click to read the license

ATTENTION: THIS END USER LICENSE AGREEMENT (“EULA” OR ‘AGREEMENT”) GOVERNS YOUR USE OF A COMPILED VERSION OF ZEA INC’S (“ZEA”/”WE”/”US”) PROPRIETARY SOFTWARE WHICH IS LICENSED TO YOU AND NOT SOLD AND MAY BE MADE AVAILABLE TO YOU. THE SOFTWARE IS PROPRIETARY TO ZEA, INC (“ZEA”) AND THE SOFTWARE MAY BE DISTRIBUTED WITH THIRD PARTY SOFTWARE WHICH IS SUBJECT TO ITS OWN LICENCE TERMS WHICH YOU MUST ADHERE TO. THIS AGREEMENT CONTAINS IMPORTANT LIMITATIONS ON REPRESENTATIONS, WARRANTIES, CONDITIONS, REMEDIES AND LIABILITIES.
ZEA EULA

IF YOU DOWNLOAD, INSTALL, OR USE THE FREE, COMPILED VERSION OF OUR SOFTWARE EITHER FROM WWW.ZEA.LIVE (THE “WEBSITE”) OR A THIRD PARTY SITE OR SOURCE, YOU WILL BE ACCEPTING THIS AGREEMENT, AND YOU WILL HAVE ACCEPTED AND AGREED TO THE TERMS HEREIN. IF YOU ARE AN AGENT OR EMPLOYEE OF ANOTHER ENTITY YOU REPRESENT AND WARRANT THAT (I) THE INDIVIDUAL ACCEPTING THIS AGREEMENT IS DULY AUTHORIZED TO ACCEPT THIS AGREEMENT ON SUCH ENTITY’S BEHALF AND TO BIND SUCH ENTITY, AND (II) SUCH ENTITY HAS FULL POWER, CORPORATE OR OTHERWISE, TO ENTER INTO AND COMPLY WITH THE TERMS OF THIS AGREEMENT. IF YOU DO NOT ACCEPT THIS AGREEMENT PLEASE DO NOT DOWNLOAD, INSTALL, OR USE THE SOFTWARE. PLEASE NOTE THAT YOU MAY NOT ACCESS AND USE THE SOFTWARE FOR ANY BENCHMARKING OR COMPETITIVE PURPOSES INCLUDING, MONITORING THEIR AVAILABILITY OR PERFORMANCE.

1. Definitions. In this Agreement:

  1. "Confidential Information" means any business, marketing, technical, scientific or other information disclosed by either party to the other or embodied in the Software and/or Demo Content which, at the time of disclosure is designated as confidential (or like designation), is disclosed in circumstances of confidence, or would be understood by someone exercising reasonable business judgment to be confidential;

  2. "Customer" or "You" both the individual or individuals obtaining or installing the Software and any entity on whose behalf such individual or individuals are acting. "You" includes any entity that by majority voting interest controls, is controlled by, or is under common control with You;

  3. "Software" means the Zea compiled JavaScript, binary or bytecode software program (excluding Third Party Software) that is made available to You after agreeing to the terms of this Agreement. Also referred to as a Software Development Kit (SDK) on our website.

  4. "Third Party Software" means any software embedded in or delivered with the Software which is owned or licensed to ZEA by a third party;

2. Software License Terms:

  1. License Grant: Subject to the terms and conditions of this Agreement, Zea grants to You a non-exclusive, non-transferable internal non-commercial license, royalty free license to download and run the Software for evaluation purposes.

  2. Third Party Software: If a separate license agreement for an item of Third-Party Software is: delivered to You or referenced in any material that is included in the download or distribution package for the Software, then such Third-Party Software shall govern Your use of that item or version of such Third-Party Software. Your right to use any Third-Party Software, third-party data or other third-party content provided with the Software shall be limited to the use necessary to operate the Software as permitted by this Agreement. No other rights in the Software or Third-Party Software are granted to You. Notwithstanding the foregoing, in the case of Third-Party Software that is licensed pursuant to open source licenses that prohibit the imposition of any restrictions on use beyond those contained in such open source licenses, the restrictions on use contained in this Agreement shall not be applicable to such Third-Party Software.

  3. Software Restrictions: You shall not reverse engineer, disassemble, reverse translate, decompile or in any other manner decode the Software except to the extent that the foregoing restriction is expressly prohibited by applicable law notwithstanding a contractual obligation to the contrary. You shall not distribute, lease, rent, grant a security interest in, assign, or otherwise transfer the Software. You shall not modify or create any derivatives of the Software. You acknowledge that the Software contains Confidential Information and You shall not disclose such Confidential Information including any performance or benchmarking information about the Software without the written consent of Zea. You further agree not to disclose, transfer or otherwise provide to any third party any portion of the Software or Demo Content, except as explicitly permitted herein. Any third-party software, data or content (including the Third-Party Software) included with or as a part of the Software may be used only with the Software unless otherwise authorized in writing by Zea.

3. Showcase Content

Zea's demo content made available on the Website or through other channels is subject to the MIT license and accordingly, by accessing or using that content, including in combination with the Software, you are agreeing to use the content only on the terms set out in that license.

4. Technical Support

This Agreement does not grant You the right to any updates or enhancements of the Software or the right to receive any technical support in respect to the Software. Such updates may be licensed, and other technical support services, if available, may be purchased separately from Zea as part of a paid evaluation or standard license agreement.

5. Intellectual Property Rights

All right, title, and interest (including all intellectual property rights) in, to, and under the Software (including all copies thereof) shall remain with Zea and its licensors. Customer’s rights to the Software are strictly limited to those granted in this Agreement. Zea product names and logos are trademarks of Zea Inc. All other company and product names and logos provided as part of the Software are trademarks or registered trademarks of their respective owners in certain countries.

6. DISCLAIMER

USE OF THE SOFTWARE IS PROVIDED TO YOU ON AN "AS IS" AND "AS AVAILABLE" BASIS, WITHOUT ANY WARRANTIES OF ANY KIND, WHETHER EXPRESS OR IMPLIED. WE DO NOT WARRANT THAT THE CONTENT OR USER CONTENT IS ACCURATE, RELIABLE OR CORRECT; THAT OUR SERVICES OR WEBSITE WILL BE AVAILABLE AT ANY PARTICULAR TIME OR LOCATION; THAT YOUR ACCESS TO OUR SERVICES OR WEBSITE WILL BE UNINTERRUPTED; THAT ANY DEFECTS OR ERRORS WILL BE CORRECTED; THAT OUR SERVICES OR WEBSITE IS FREE OF VIRUSES OR OTHER HARMFUL COMPONENTS; OR THAT THE CONTENT IS TIMELY, SECURE OR ERROR-FREE.

TO THE EXTENT LEGALLY PERMITTED WE EXPRESSLY DISCLAIM ALL WARRANTIES, REPRESENTATIONS AND CONDITIONS, EXPRESS OR IMPLIED, INCLUDING THOSE OF QUALITY, MERCHANTABILITY, MERCHANTABLE QUALITY, NON-INFRINGEMENT, DURABILITY, FITNESS FOR A PARTICULAR PURPOSE AND THOSE ARISING BY STATUTE. WE ARE NOT LIABLE FOR ANY LOSS, WHETHER OF MONEY (INCLUDING PROFIT), GOODWILL, OR REPUTATION, OR ANY SPECIAL, INDIRECT, OR CONSEQUENTIAL DAMAGES ARISING OUT OF YOUR USE OF THE ZEA SERVICES, EVEN IF YOU ADVISE US OR WE COULD REASONABLY FORESEE THE POSSIBILITY OF ANY SUCH DAMAGE OCCURRING. SOME JURISDICTIONS DO NOT ALLOW THE DISCLAIMER OF WARRANTIES OR EXCLUSION OF DAMAGES, SO SUCH DISCLAIMERS AND EXCLUSIONS MAY NOT APPLY TO YOU.

7. Limitation of Liability

NOTWITHSTANDING ANYTHING CONTAINED IN THE PREVIOUS PARAGRAPH, IF WE ARE FOUND TO BE LIABLE, OUR LIABILITY TO YOU OR ANY THIRD PARTY (WHETHER IN CONTRACT, TORT, NEGLIGENCE, STRICT LIABILITY IN TORT, BY STATUTE OR OTHERWISE) IS LIMITED TO $100 CDN. UNDER NO CIRCUMSTANCES SHALL ZEA BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL, EXEMPLARY OR OTHER DAMAGES WHATSOEVER.

8. Indemnity

You will indemnify and hold harmless Zea and its affiliates and our and their respective officers, directors, agents and employees (each an “Indemnified Party”), from any claim made by any third party, together with any amounts payable to the third party whether in settlement or as may otherwise be awarded, and reasonable legal costs incurred by any of the Indemnified Parties, arising from or relating to your use of our Services or Website, any alleged violation by you of the applicable terms, and any alleged violation by you of any applicable law or regulation. We reserve the right, at our own expense, to assume the exclusive defense and control of any matter subject to indemnification by you, but doing so will not excuse your indemnity obligations.

9. Third-Party Beneficiaries

You are hereby notified that there may be third-party beneficiaries to this Agreement. To the extent that this Agreement contains provisions that relate to (i) the use by You of certain components of the Software in which such third parties have an interest, or (ii) services provided by Affiliates, licensors, subcontractors, and/or distributors of Zea; such provisions are made expressly for the benefit of such third-party beneficiaries and are enforceable by such third-party beneficiaries in addition to being enforceable by Zea.

10. Feedback

Zea shall have a royalty-free, worldwide, transferable, sub licensable, irrevocable, perpetual, unrestricted license to use and/or incorporate into the Software or other Zea products or services any suggestions, enhancement requests, recommendations or other feedback provided by You relating to the operation of the Software, showcase content and/or Zea’s business more generally.

11. General Terms:

This Agreement is the entire agreement between You and Zea in respect to the Software and the Software shall be deemed to be licensed pursuant to the terms and conditions of this Agreement unless You have executed a written license agreement with Zea or a distributor of Zea, in which case the Software shall be deemed to have been licensed pursuant to the terms and conditions of such written license agreement. You may not assign this Agreement whether voluntarily, by operation of law, or otherwise without Zea’s prior written consent. The failure of a party to claim a breach of any term of this Agreement shall not constitute a waiver of such breach or the right of such party to enforce any subsequent breach of such term. If any provision of this Agreement is held to be unenforceable or illegal, such decision shall not affect the validity or enforceability of such provisions under other circumstances or the remaining provisions of this Agreement and such remaining provisions shall be reformed only to the extent necessary to make them enforceable under such circumstances. This Agreement shall be governed by the laws of the Province of Ontario. No choice of laws rules of any jurisdiction shall apply to this Agreement. You shall only be entitled to bring any action or proceeding arising out of or relating to this Agreement, the Software or any services provided in respect to the Software in a court in Toronto, Ontario Canada and You consent to the jurisdiction of such courts for any such action or proceeding.

We reserve the right at any time and from time to time to modify or discontinue, temporarily or permanently access to showcase content or our software (or any part thereof) with or without notice. If you wish to terminate your account with Zea, you may discontinue using our Software and delete any applications or software that you may have downloaded from us. We may amend this EULA at any time by posting revisions through a link on our website, with no additional notice to you. Your continued access to and use of our Software will constitute acceptance of our amended EULA. If you do not agree with our EULA, or any future amendments, your sole recourse is to cease use of our Services. If you have any questions regarding this EULA please contact licensing@zea.live.

YOU ACKNOWLEDGE THAT YOU HAVE READ THIS AGREEMENT, UNDERSTAND THEM AND AGREE TO ALL OF THE TERMS AND CONDITIONS HEREIN. Last Updated: September 1, 2020

(c) Copyright 2020 Zea Inc, all rights reserved.


For questions on licensing, please fill out the contact form on our website: zea.live



Add it to your project

The process to add Zea CAD to your projects is easy.

Using CDNs

For static websites or quick implementation you can always use CDNs like JsDelivr or Unpkg:

JsDelivr

<script crossorigin src="https://cdn.jsdelivr.net/npm/@zeainc/zea-cad/dist/index.umd.min.js"></script>

Unpkg

<script crossorigin src="https://unpkg.com/@zeainc/zea-cad/dist/index.umd.js"></script>

Use it

<script>
  const { CADAsset } = globalThis.zeaCad
</script>

Script tags instead of esm imports

Currently the engine and its plugins can only be imported using UMD script tags.

Why don't we use esm imports to load the engine and its plugins?

Yes we would like to do that eventually, but there are a few issues holding us back.

  1. Bundlers like webpack and rollup have a terrible time at understanding diamond shaped dependency trees. I will explain by example. Package B depends on package A and package C depends on both package A and B. If we import B and C, A should be imported. however, if in the package.json of B or C, the version dependency is even slightly different, even with valid version rules that should mean both B and C should be compatible with the same version of A, we find that the bundler will often try to load multiple different versions of A. e.g. A version 2.3.1, and A version 2.3.0. When A is our engine, this causes all sorts of obscure problems. For now, until we can guarantee that the bundler will load exactly one copy of our engine, we have to stick with script tags.

  2. Bundlers and WASM don't mix. We leverage WASM in our engine, and WASM requires a fetch of the WASM file which is included in our package. Currently the bundlers are unable to include the WASM file and so we have to fallback to fetching the WASM file from some predefined location, instead of the package location in your node_modules folder. Not ideal, but we hope this issue to be resolved soon as WASM imports are included in the spec.

We hope that these issues are resolved over time. If you have any suggestions on alternative methods to what we have presented, please feel free to reach out and let us know your thoughts.




Dependencies

This plug-in depends on ZeaEngine. So, if you're using CDNs, make sure to import it before CAD.

Links