Tube in a path, made with CSG subtraction of cylinders

The link:

Thanks to @hofk for the based work! :wink:

5 Likes

Hi @hofk , I need Your help:

When I tryed to run

to serve as base for this page, after installing r129 in my computer, the console showed the message:
Uncaught TypeError: dice.quaternion.setFromBasis is not a function
Then I used :

Is there a possibility to use Quaternion in the first link, because accessing Your page it works without the console error.

Note that the import ( import * as THREE from β€œ../jsm/three.module.129.Quaternion.js”; ) is a supplemented version of r129. You can and may extend three.js with your own functionalities.

Go to the source:
https://hofk.de/main/discourse.threejs/2021/jsm/three.module.129.Quaternion.js

Search for setFromBasis and you will find the method I added to the quaternions.

If you do not want to change three.js, do it as in the example FlightRouteQuaternion

THREE.Quaternion.prototype.setFromBasis = function( e1, e2, e3 ) { ...

at the beginning.

Enjoy :slightly_smiling_face:

Hi @hofk …

Thank you very much for the explanations, I will follow your instructions. :wink:

Hi @hofk …
The example of Flight Route Quaternion worked fine in r175. :wink:

1 Like

made with CSG subtraction of cylinders

Yet another option of how to build a hollow cylinder. Merging of geometries :slight_smile:

Demo: https://codepen.io/prisoner849/full/zxxjdNe

2 Likes