From d5bf9cdbcd1da585e14c0d1748f5388f97446716 Mon Sep 17 00:00:00 2001 From: NissimHadar Date: Tue, 6 Feb 2018 16:16:25 -0800 Subject: [PATCH] Updated JSDoc comments. --- interface/src/scripting/WindowScriptingInterface.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/interface/src/scripting/WindowScriptingInterface.h b/interface/src/scripting/WindowScriptingInterface.h index b38d27aac5..cc81f0a082 100644 --- a/interface/src/scripting/WindowScriptingInterface.h +++ b/interface/src/scripting/WindowScriptingInterface.h @@ -334,6 +334,8 @@ public slots: * @param {number} aspectRatio=0 - The width/height ratio of the snapshot required. If the value is 0 the * full resolution is used (window dimensions in desktop mode; HMD display dimensions in HMD mode), otherwise one of the * dimensions is adjusted in order to match the aspect ratio. + * @param {string} filename=QString() - If this value is not null then the image will be saved to this filename, with an appended ",jpg". + * otherwise, the image will be saved as 'hifi-snap-by--YYYY-MM-DD_HH-MM-SS' * @example Using the snapshot function and signals. * function onStillSnapshotTaken(path, notify) { * print("Still snapshot taken: " + path); @@ -355,13 +357,17 @@ public slots: * var notify = true; * var animated = true; * var aspect = 1920 / 1080; - * Window.takeSnapshot(notify, animated, aspect); + * var filename = QString(); + * Window.takeSnapshot(notify, animated, aspect, filename); */ void takeSnapshot(bool notify = true, bool includeAnimated = false, float aspectRatio = 0.0f, const QString& filename = QString()); /**jsdoc * Takes a still snapshot of the current view from the secondary camera that can be set up through the {@link Render} API. * @function Window.takeSecondaryCameraSnapshot + * @param {string} filename=QString() - If this value is not null then the image will be saved to this filename, with an appended ",jpg" + * + * var filename = QString(); */ void takeSecondaryCameraSnapshot(const QString& filename = QString());