Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Import Sections for Addons #25467

Merged
merged 13 commits into from
Feb 9, 2023
11 changes: 11 additions & 0 deletions docs/examples/en/animations/CCDIKSolver.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,17 @@ <h1>[name]</h1>

<iframe id="scene" src="scenes/ccdiksolver-browser.html"></iframe>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { CCDIKSolver } from 'three/addons/animation/CCDIKSolver.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/animations/MMDAnimationHelper.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@ <h1>[name]</h1>
It uses [page:CCDIKSolver] and [page:MMDPhysics] inside.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { MMDAnimationHelper } from 'three/addons/animation/MMDAnimationHelper.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/animations/MMDPhysics.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,17 @@ <h1>[name]</h1>
[name] calculates Physics for model loaded by [page:MMDLoader] with [link:https://github.com/kripken/ammo.js/ ammo.js] (Bullet-based JavaScript Physics engine).
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { MMDPhysics } from 'three/addons/animation/MMDPhysics.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
10 changes: 10 additions & 0 deletions docs/examples/en/controls/ArcballControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,19 @@ <h1>[name]</h1>

To use this, as with all files in the /examples directory, you will have to
include the file separately in your HTML.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { ArcballControls } from 'three/addons/controls/ArcballControls.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
13 changes: 12 additions & 1 deletion docs/examples/en/controls/DragControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,20 @@
<h1>[name]</h1>

<p class="desc">
This class can be used to provide a drag'n'drop interaction.
This class can be used to provide a drag'n'drop interaction.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { DragControls } from 'three/addons/controls/DragControls.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/controls/FirstPersonControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@ <h1>[name]</h1>
This class is an alternative implementation of [page:FlyControls].
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { FirstPersonControls } from 'three/addons/controls/FirstPersonControls.js';
</code>

<h2>Examples</h2>

<p>[example:webgl_geometry_terrain webgl / geometry / terrain ]</p>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/controls/FlyControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,17 @@ <h1>[name]</h1>
3D space without any limitations (e.g. focus on a specific target).
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { FlyControls } from 'three/addons/controls/FlyControls.js';
</code>

<h2>Examples</h2>

<p>[example:misc_controls_fly misc / controls / fly ]</p>
Expand Down
16 changes: 13 additions & 3 deletions docs/examples/en/controls/OrbitControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,23 @@
<h1>[name]</h1>

<p class="desc">
Orbit controls allow the camera to orbit around a target.<br>
Orbit controls allow the camera to orbit around a target.<br>

To use this, as with all files in the /examples directory, you will have to
include the file separately in your HTML.
To use this, as with all files in the /examples directory, you will have to
include the file separately in your HTML.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { OrbitControls } from 'three/addons/controls/OrbitControls.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
15 changes: 13 additions & 2 deletions docs/examples/en/controls/PointerLockControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,21 @@
<h1>[name]</h1>

<p class="desc">
The implementation of this class is based on the [link:https://developer.mozilla.org/en-US/docs/Web/API/Pointer_Lock_API Pointer Lock API].
[name] is a perfect choice for first person 3D games.
The implementation of this class is based on the [link:https://developer.mozilla.org/en-US/docs/Web/API/Pointer_Lock_API Pointer Lock API].
[name] is a perfect choice for first person 3D games.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { PointerLockControls } from 'three/addons/controls/PointerLockControls.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/controls/TrackballControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,17 @@ <h1>[name]</h1>
</p>
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { TrackballControls } from 'three/addons/controls/TrackballControls.js';
</code>

<h2>Examples</h2>

<p>[example:misc_controls_trackball misc / controls / trackball ]</p>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/controls/TransformControls.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,17 @@ <h1>[name]</h1>
[name] expects that its attached 3D object is part of the scene graph.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { TransformControls } from 'three/addons/controls/TransformControls.js';
</code>

<h2>Examples</h2>

<p>[example:misc_controls_transform misc / controls / transform ]</p>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/ColladaExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@ <h1>[name]</h1>
This exporter only supports exporting geometry, materials, textures, and scene hierarchy.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { ColladaExporter } from 'three/addons/exporters/ColladaExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/DRACOExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,17 @@ <h1>[name]</h1>
using [link:https://github.com/AnalyticalGraphicsInc/gltf-pipeline glTF-Pipeline].
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { DRACOExporter } from 'three/addons/exporters/DRACOExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/EXRExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,17 @@ <h1>[name]</h1>
and DI.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { EXRExporter } from 'three/addons/exporters/EXRExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/GLTFExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,17 @@ <h1>[name]</h1>
textures, skins, skeletons, morph targets, animations, lights, and/or cameras.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { GLTFExporter } from 'three/addons/exporters/GLTFExporter.js';
</code>

<h2>Extensions</h2>

<p>
Expand Down
16 changes: 13 additions & 3 deletions docs/examples/en/exporters/OBJExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,22 @@
<h1>[name]</h1>

<p class="desc">
An exporter for the [link:https://en.wikipedia.org/wiki/Wavefront_.obj_file OBJ] file format.
An exporter for the [link:https://en.wikipedia.org/wiki/Wavefront_.obj_file OBJ] file format.
<br/><br/>
[name] is not able to export material data into MTL files so only geometry data are supported.
</p>
<p class="desc">
[name] is not able to export material data into MTL files so only geometry data are supported.

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { OBJExporter } from 'three/addons/exporters/OBJExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/PLYExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,17 @@ <h1>[name]</h1>
uv coordinates. No textures or texture references are saved.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { PLYExporter } from 'three/addons/exporters/PLYExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
11 changes: 11 additions & 0 deletions docs/examples/en/exporters/STLExporter.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@ <h1>[name]</h1>
STL files contain no scale information or indexes, and the units are arbitrary.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { STLExporter } from 'three/addons/exporters/STLExporter.js';
</code>

<h2>Code Example</h2>

<code>
Expand Down
17 changes: 15 additions & 2 deletions docs/examples/en/geometries/ConvexGeometry.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,21 @@

<h1>[name]</h1>

<p class="desc">[name] can be used to generate a convex hull for a given array of 3D points.
The average time complexity for this task is considered to be O(nlog(n)).</p>
<p class="desc">
[name] can be used to generate a convex hull for a given array of 3D points.
The average time complexity for this task is considered to be O(nlog(n)).
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { ConvexGeometry } from 'three/addons/geometries/ConvexGeometry.js';
</code>

<h2>Code Example</h2>

Expand Down
16 changes: 15 additions & 1 deletion docs/examples/en/geometries/DecalGeometry.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,21 @@

<h1>[name]</h1>

<p class="desc">[name] can be used to create a decal mesh that serves different kinds of purposes e.g. adding unique details to models, performing dynamic visual environmental changes or covering seams.</p>
<p class="desc">
[name] can be used to create a decal mesh that serves different kinds of purposes e.g. adding unique details
to models, performing dynamic visual environmental changes or covering seams.
</p>

<h2>Import</h2>

<p>
[name] is an add-on, and must be imported explicitly.
See [link:#manual/introduction/Installation Installation / Addons].
</p>

<code>
import { DecalGeometry } from 'three/addons/geometries/DecalGeometry.js';
</code>

<h2>Code Example</h2>

Expand Down
Loading