diff --git a/assignment-client/src/avatars/ScriptableAvatar.h b/assignment-client/src/avatars/ScriptableAvatar.h
index 6b78f666e1..3cf10cc129 100644
--- a/assignment-client/src/avatars/ScriptableAvatar.h
+++ b/assignment-client/src/avatars/ScriptableAvatar.h
@@ -28,7 +28,8 @@
*
* @comment IMPORTANT: This group of properties is copied from AvatarData.h; they should NOT be edited here.
* @property {Vec3} position
- * @property {number} scale - Returns the clamped scale of the avatar.
+ * @property {number} scale=1.0 - The scale of the avatar. When setting, the value is limited to between 0.005
+ * and 1000.0
. When getting, the value may temporarily be further limited by the domain's settings.
* @property {number} density Read-only.
* @property {Vec3} handPosition
* @property {number} bodyYaw - The rotation left or right about an axis running from the head to the feet of the avatar.
@@ -50,8 +51,9 @@
* @property {number} audioLoudness
* @property {number} audioAverageLoudness
* @property {string} displayName
- * @property {string} sessionDisplayName - Sanitized, defaulted version displayName that is defined by the AvatarMixer
- * rather than by Interface clients. The result is unique among all avatars present at the time.
+ * @property {string} sessionDisplayName - Sanitized, defaulted version of displayName
that is defined by the
+ * avatar mixer rather than by Interface clients. The result is unique among all avatars present on the domain at the
+ * time.
* @property {boolean} lookAtSnappingEnabled
* @property {string} skeletonModelURL
* @property {AttachmentData[]} attachmentData
@@ -102,24 +104,12 @@ public:
Q_INVOKABLE AnimationDetails getAnimationDetails();
/**jsdoc
- * ####### TODO: If this override changes the function use @override and do JSDoc here, otherwise @comment that uses base class's JSDoc.
- * Get the names of all the joints in the current avatar.
- * @function Avatar.getJointNames
- * @returns {string[]} The joint names.
- * @example
Warning: Potentially a very expensive call. Do not use if possible.
* @function Avatar.getAvatarEntityData - * @returns {object} + * @returns {AvatarEntityMap} */ Q_INVOKABLE AvatarEntityMap getAvatarEntityData() const override; /**jsdoc - * ####### TODO: If this override changes the function use @override and do JSDoc here, otherwise @comment that uses base class's JSDoc. + * Set the avatar entities from binary data. + *Warning: Potentially an expensive call. Do not use if possible.
* @function Avatar.setAvatarEntityData - * @param {object} avatarEntityData + * @param {AvatarEntityMap} avatarEntityData */ Q_INVOKABLE void setAvatarEntityData(const AvatarEntityMap& avatarEntityData) override; /**jsdoc - * ####### TODO: If this override changes the function use @override and do JSDoc here, otherwise @comment that uses base class's JSDoc. - * @function Avatar.updateAvatarEntity - * @param {Uuid} entityID - * @param {string} entityData + * @comment Uses the base class's JSDoc. */ Q_INVOKABLE void updateAvatarEntity(const QUuid& entityID, const QByteArray& entityData) override; public slots: /**jsdoc * @function Avatar.update + * @param {number} deltaTime */ void update(float deltatime); /**jsdoc - * @function Avatar.setJointMappingsFromNetworkReply - */ + * @function Avatar.setJointMappingsFromNetworkReply + */ void setJointMappingsFromNetworkReply(); private: diff --git a/libraries/avatars/src/AvatarData.h b/libraries/avatars/src/AvatarData.h index 7a4d235565..0a5509f46c 100755 --- a/libraries/avatars/src/AvatarData.h +++ b/libraries/avatars/src/AvatarData.h @@ -61,6 +61,10 @@ using AvatarSharedPointer = std::shared_ptr0.005
+ * and 1000.0
. When getting, the value may temporarily be further limited by the domain's settings.
* @property {number} density Read-only.
* @property {Vec3} handPosition
* @property {number} bodyYaw - The rotation left or right about an axis running from the head to the feet of the avatar.
@@ -436,8 +441,9 @@ class AvatarData : public QObject, public SpatiallyNestable {
* @property {number} audioLoudness
* @property {number} audioAverageLoudness
* @property {string} displayName
- * @property {string} sessionDisplayName - Sanitized, defaulted version displayName that is defined by the AvatarMixer
- * rather than by Interface clients. The result is unique among all avatars present at the time.
+ * @property {string} sessionDisplayName - Sanitized, defaulted version of displayName
that is defined by the
+ * avatar mixer rather than by Interface clients. The result is unique among all avatars present on the domain at the
+ * time.
* @property {boolean} lookAtSnappingEnabled
* @property {string} skeletonModelURL
* @property {AttachmentData[]} attachmentData
@@ -601,18 +607,18 @@ public:
virtual bool getHasAudioEnabledFaceMovement() const { return false; }
/**jsdoc
- * Returns the minimum scale allowed for this avatar in the current domain.
+ * Get the minimum scale allowed for this avatar in the current domain.
* This value can change as the user changes avatars or when changing domains.
* @function Avatar.getDomainMinScale
- * @returns {number} minimum scale allowed for this avatar in the current domain.
+ * @returns {number} The minimum scale allowed for this avatar in the current domain.
*/
Q_INVOKABLE float getDomainMinScale() const;
/**jsdoc
- * Returns the maximum scale allowed for this avatar in the current domain.
+ * Get the maximum scale allowed for this avatar in the current domain.
* This value can change as the user changes avatars or when changing domains.
* @function Avatar.getDomainMaxScale
- * @returns {number} maximum scale allowed for this avatar in the current domain.
+ * @returns {number} The maximum scale allowed for this avatar in the current domain.
*/
Q_INVOKABLE float getDomainMaxScale() const;
@@ -625,18 +631,18 @@ public:
virtual bool canMeasureEyeHeight() const { return false; }
/**jsdoc
- * Provides read only access to the current eye height of the avatar.
+ * Get the current eye height of the avatar.
* This height is only an estimate and might be incorrect for avatars that are missing standard joints.
* @function Avatar.getEyeHeight
- * @returns {number} Eye height of avatar in meters.
+ * @returns {number} The eye height of the avatar.
*/
Q_INVOKABLE virtual float getEyeHeight() const { return _targetScale * getUnscaledEyeHeight(); }
/**jsdoc
- * Provides read only access to the current height of the avatar.
+ * Get the current height of the avatar.
* This height is only an estimate and might be incorrect for avatars that are missing standard joints.
* @function Avatar.getHeight
- * @returns {number} Height of avatar in meters.
+ * @returns {number} The height of the avatar.
*/
Q_INVOKABLE virtual float getHeight() const;
@@ -739,7 +745,7 @@ public:
/**jsdoc
* Get the rotation of a joint relative to its parent. For information on the joint hierarchy used, see
- * Avatar Standards.
+ * Avatar Standards.
* @function Avatar.getJointRotation
* @param {number} index - The index of the joint.
* @returns {Quat} The rotation of the joint relative to its parent.
@@ -748,7 +754,7 @@ public:
/**jsdoc
* Get the translation of a joint relative to its parent. For information on the joint hierarchy used, see
- * Avatar Standards.
+ * Avatar Standards.
* @function Avatar.getJointTranslation
* @param {number} index - The index of the joint.
* @returns {Vec3} The translation of the joint relative to its parent.
@@ -855,7 +861,7 @@ public:
/**jsdoc
* Get the rotation of a joint relative to its parent. For information on the joint hierarchy used, see
- * Avatar Standards.
+ * Avatar Standards.
* @function Avatar.getJointRotation
* @param {string} name - The name of the joint.
* @returns {Quat} The rotation of the joint relative to its parent.
@@ -868,7 +874,7 @@ public:
/**jsdoc
* Get the translation of a joint relative to its parent. For information on the joint hierarchy used, see
- * Avatar Standards.
+ * Avatar Standards.
* @function Avatar.getJointTranslation
* @param {number} name - The name of the joint.
* @returns {Vec3} The translation of the joint relative to its parent.
@@ -883,7 +889,7 @@ public:
* Get the rotations of all joints in the current avatar. Each joint's rotation is relative to its parent joint.
* @function Avatar.getJointRotations
* @returns {Quat[]} The rotations of all joints relative to each's parent. The values are in the same order as the array
- * returned by {@link MyAvatar.getJointNames} or {@link Avatar.getJointNames}.
+ * returned by {@link MyAvatar.getJointNames}, or {@link Avatar.getJointNames} if using the Avatar
API.
* @example Avatar
API.
* @example Avatar
API.
* @function Avatar.getJointIndex
* @param {string} name - The name of the joint.
- * @returns {number} The index of the joint.
+ * @returns {number} The index of the joint if valid, otherwise -1
.
* @example