summaryrefslogtreecommitdiffstats
path: root/o3d/samples
diff options
context:
space:
mode:
authorgman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-21 21:34:48 +0000
committergman@google.com <gman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-21 21:34:48 +0000
commit8f743cc8a87fc6314d3e9ae024ae39ab881023c0 (patch)
tree6adb6b01e19ad6ff266bd09b92be8cfda5d9ae14 /o3d/samples
parente6676af22ae37bd1716389b2ef3396d5f4b72a8e (diff)
downloadchromium_src-8f743cc8a87fc6314d3e9ae024ae39ab881023c0.zip
chromium_src-8f743cc8a87fc6314d3e9ae024ae39ab881023c0.tar.gz
chromium_src-8f743cc8a87fc6314d3e9ae024ae39ab881023c0.tar.bz2
docs fixes for simple.js
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24018 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'o3d/samples')
-rw-r--r--o3d/samples/o3djs/simple.js17
1 files changed, 12 insertions, 5 deletions
diff --git a/o3d/samples/o3djs/simple.js b/o3d/samples/o3djs/simple.js
index 526fd5a..c7a0e54 100644
--- a/o3d/samples/o3djs/simple.js
+++ b/o3d/samples/o3djs/simple.js
@@ -173,7 +173,7 @@ o3djs.simple.SimpleInfo = function(clientObject) {
/**
* The ViewInfo created by this SimpleInfo.
- * @type {!o3d.ViewInfo}
+ * @type {!o3djs.rendergraph.ViewInfo}
*/
this.viewInfo = o3djs.rendergraph.createBasicView(
this.pack,
@@ -509,7 +509,7 @@ o3djs.simple.SimpleInfo.prototype.createSphere = function(radius,
* @param {!function(o3djs.simple.SimpleScene, *): void} callback a callback to
* call when the scene is loaded. The first argument will be null if the
* scene failed to load and last object will be an exception.
- * @return {!o3djs.io.loadInfo}
+ * @return {!o3djs.io.LoadInfo}
*/
o3djs.simple.SimpleInfo.prototype.loadScene = function(url, callback) {
var pack = this.client.createPack();
@@ -567,6 +567,7 @@ o3djs.simple.SimpleObject = function() {
};
/**
+ * Initializes a SimpleObject.
* @param {!o3djs.simple.SimpleInfo} simpleInfo The SimpleInfo to manage this
* object.
* @param {!o3d.Transform} transform Transform that orients this object.
@@ -605,7 +606,13 @@ o3djs.simple.SimpleObject.prototype.init = function(simpleInfo, transform) {
this.pickCallback_ = null;
};
+/**
+ * Registers on an on picked callback.
+ * @param {!function(!o3djs.simple.SimpleObject): void} onPickedCallback A
+ * function called when this object is picked.
+ */
o3djs.simple.SimpleObject.prototype.onPicked = function(onPickedCallback) {
+ throw 'not implemented';
};
/**
@@ -625,7 +632,7 @@ o3djs.simple.SimpleObject.prototype.onUpdate = function(elapsedTime) {
* Sets a function to be called every frame for this object.
* @param {function(number): void} onUpdateCallback A function that is passed
* the elapsed time in seconds. Pass in null to clear the callback function.
- * @return {?function(number): void} The previous callback function.
+ * @return {(function(number): void|null)} The previous callback function.
*/
o3djs.simple.SimpleObject.prototype.setOnUpdate = function(onUpdateCallback) {
if (onUpdateCallback) {
@@ -642,7 +649,7 @@ o3djs.simple.SimpleObject.prototype.setOnUpdate = function(onUpdateCallback) {
* A SimpleShape manages a transform with 1 shape that holds 1 primitive
* and 1 unique material.
* @constructor
- * @extends o3djs.simple.SimpleObject
+ * @extends {o3djs.simple.SimpleObject}
* @param {!o3djs.simple.SimpleInfo} simpleInfo The SimpleInfo to manage this
* shape.
* @param {!o3d.Transform} transform Transform with 1 shape that holds 1
@@ -743,7 +750,7 @@ o3djs.simple.SimpleShape.prototype.loadTexture = function(url) {
/**
* An object to simply manage a scene.
* @constructor
- * @extends o3djs.simple.SimpleObject
+ * @extends {o3djs.simple.SimpleObject}
* @param {!o3djs.simple.SimpleInfo} simpleInfo The SimpleInfo to manage this
* scene.
* @param {string} url Url scene was loaded from.