|
@@ -16,27 +16,33 @@
|
|
|
|
|
|
<h2>Constructor</h2>
|
|
<h2>Constructor</h2>
|
|
|
|
|
|
- <h3>[name]()</h3>
|
|
|
|
|
|
+ <h3>[name]( [page:LoadingManager manager] )</h3>
|
|
|
|
+ <div>
|
|
|
|
+ [page:LoadingManager manager] — The [page:LoadingManager loadingManager] for the loader to use. Default is [page:LoadingManager THREE.DefaultLoadingManager].
|
|
|
|
+ </div>
|
|
<div>
|
|
<div>
|
|
Creates a new [name].
|
|
Creates a new [name].
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
+ <h2>Methods</h2>
|
|
|
|
|
|
- <h2>Properties</h2>
|
|
|
|
-
|
|
|
|
- <h3>[property:boolean withCredentials]</h3>
|
|
|
|
|
|
+ <h3>[method:null load]( [page:String url], [page:Function onLoad], [page:Function onProgress], [page:Function onError] )</h3>
|
|
<div>
|
|
<div>
|
|
- If true, the ajax request will use cookies.
|
|
|
|
|
|
+ [page:String url] — required.<br />
|
|
|
|
+ [page:Function onLoad] — Will be called when load completes. The argument will be the loaded text response.<br />
|
|
|
|
+ [page:Function onProgress] — Will be called while load progresses. The argument will be the XmlHttpRequest instance, that contain .[page:Integer total] and .[page:Integer loaded] bytes.<br />
|
|
|
|
+ [page:Function onError] — Will be called when load errors.<br />
|
|
|
|
+ </div>
|
|
|
|
+ <div>
|
|
|
|
+ Begin loading from url and pass the <em>JSON</em> to onLoad.
|
|
</div>
|
|
</div>
|
|
|
|
|
|
-
|
|
|
|
- <h2>Methods</h2>
|
|
|
|
-
|
|
|
|
- <h3>[method:null load]( [page:String url], [page:Function callback], [page:String texturePath] )</h3>
|
|
|
|
|
|
+ <h3>[method:null setTexturePath]( [page:String texturePath] )</h3>
|
|
|
|
+ <div>
|
|
|
|
+ [page:String texturePath] — Base path for textures.
|
|
|
|
+ </div>
|
|
<div>
|
|
<div>
|
|
- [page:String url] — required<br />
|
|
|
|
- [page:Function callback] — required. Will be called when load completes. The arguments will be the loaded [page:Object3D] and the loaded [page:Array materials].<br />
|
|
|
|
- [page:String texturePath] — optional. If not specified, textures will be assumed to be in the same folder as the Javascript model file.
|
|
|
|
|
|
+ Set the base path for textures.
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<h3>[method:Object3D parse]( [page:Object json], [page:String texturePath] )</h3>
|
|
<h3>[method:Object3D parse]( [page:Object json], [page:String texturePath] )</h3>
|
|
@@ -45,10 +51,9 @@
|
|
[page:String texturePath] — Base path for textures.
|
|
[page:String texturePath] — Base path for textures.
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div>
|
|
- Parse a <em>JSON</em> structure and return an [page:Object] containing the parsed .[page:Geometry] and .[page:Array materials].
|
|
|
|
|
|
+ Parse a <em>JSON</em> structure and return an [page:object] containing the parsed [page:Geometry geometry] and [page:Array materials].
|
|
</div>
|
|
</div>
|
|
|
|
|
|
-
|
|
|
|
<h2>Example</h2>
|
|
<h2>Example</h2>
|
|
|
|
|
|
<code>
|
|
<code>
|